HRLV Maxsonar-EZ MB1013 sonar sensor UART example

Requirements

  • Hardware Requirements
    • 1 HRLV maxsonar-EZ MB1013 sonar sensor
    • 1 HCSR04 ultrasonic sensor
    • 4 Jumper wires
  • Software Requirements
    • EzloPi desktop application
    • Vera mobile application

Circuit connection in ESP32

  1. ESP32 Vout +5v
  2. UART RX for ESP32
  3. ESP32 GND
  4. HRLV maxsonar-EZ MB1013 sonar sensor GND
  5. HRLV maxsonar-EZ MB1013 sonar sensor Vin +5v
  6. HRLV maxsonar-EZ MB1013 sonar sensor RX
  7. HRLV maxsonar-EZ MB1013 sonar sensor TX

Adding HRLV maxsonar-EZ MB10123 sonar sensor from EzloPi desktop application

  1. Connect the ESP32 to the computer and open the EzloPi desktop application.
  2. Scan, select and open the serial port, connecting to the ESP32.

3. Click on the ‘Add Device’ button as shown below.

4. Select the “UART” option from the dropdown menu.

5. Configure the LED:

  1. Give it a name. (“Ultrasonic” as an example)
  2. Select HRLV maxsonar-EZ MB1013 sonar sensor from dropdown menu.
  3. Select GPIO pin for RX, GPIO 16 for example.
  4. Select GPIO pin for TX, GPIO 17 for example.
  5. Select 9600 baud rate from the dropdown menu as HRLV maxsonar-EZ MB1013 sonar sensor operates on this baud rate.
  6. Then click “OK”.

6. Device name, type, subtype and GPIOs are displayed in the screen; click on “set config” to burn the configurations to the ESP devices.

7. Finally, reset the device by clicking on “Reset”.

HRLV maxsonar-EZ MB10123 sonar sensor in Vera Mobile Application

  1. Login to the Vera app using username and password.

2. Identify the device with HRLV maxsonar-EZ MB10123 sonar sensor and click to connect to the device; wait while loading.

3. The HRLV maxsonar-EZ MB10123 sonar sensor connected will be shown in the ‘Devices’ panel.

4. If sonar finds an obstacle less than 500 cm, the icon turns green.

5. If no obstacle is detected, the icon turns gray.