This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Arduino example code for MaxBotix MB7389 HRXL-MaxSonar-WR weather resistant ultrasonic distance sensor: pulse width output. More info: www.makerguides.com */ | |
#define sensorPin 2 | |
long distance = 0; | |
long duration = 0; | |
void setup() { | |
pinMode(sensorPin, INPUT); | |
Serial.begin(9600); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
print_data(); | |
delay(1000); | |
}/* Arduino example code for MaxBotix MB7389 HRXL-MaxSonar-WR weather resistant ultrasonic distance sensor: analog voltage output. More info: www.makerguides.com */ | |
#define sensorPin A0 | |
int distance = 0; | |
void setup() { | |
Serial.begin(9600); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Arduino example code for MaxBotix MB1240 XL-MaxSonar-EZ4 ultrasonic distance sensor: pulse width output. More info: www.makerguides.com */ | |
#define sensorPin 2 | |
long distance = 0; | |
long duration = 0; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Arduino example code for MaxBotix MB1240 XL-MaxSonar-EZ4 ultrasonic distance sensor: analog voltage output. More info: www.makerguides.com */ | |
#define sensorPin A0 | |
int distance = 0; | |
void setup() { | |
Serial.begin(9600); | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
print_data(); | |
delay(1000); | |
}/* Arduino example code for MaxBotix MB7389 HRXL-MaxSonar-WR weather resistant ultrasonic distance sensor: analog voltage output. More info: www.makerguides.com */ | |
#define sensorPin A0 | |
int distance = 0; | |
void setup() { | |
Serial.begin(9600); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/************************************************************************************************* | |
* This Example sends hardcoded data to Ubidots using an ESP32-DevKitC. The code sends a distance | |
* value between an ultrasonic sensor and on the surface of the water detected by an MB7389 | |
* HRXL-MaxSonar-WRMT sensor. Then, the value will be managed in Ubidots to calculate the volume | |
* of free-flowing substances in the tank. | |
* | |
* This example is given AS IT IS without any warranty. | |
* | |
* Made by María Carlina Hernandez. | |
* Nov 28, 2018. |