ESP32LR42 User Manual v1.02 Table of Contents Overview..............................3 Control Protocols............................3 WiFi................................3 Configuration.............................3 USB Configuration Commands.........................4 ST Status. Return the system status.......................4 RB ReBoot............................4 IP Sets the modules IP address......................5 SB Sets the SuBnet mask........................5 GW Sets the GateWay address......................5 PD Sets the Primary DNS........................5 SD Sets the Secondary DNS.........................5...
4. A built in webpage WiFi The ESP32LR42 connects via WiFi to your network. Therefore it must be located in a position where it gets a good WiFi signal. The module should not be enclosed in a metal box/cabinet as this will shield the WiFi signal.
Secondary DNS: 0.0.0.0 SSID: ******** Password: ******** ASCII TCP Port: 17123 RSSI: -66 MQTT Server: 192.168.0.115 MQTT Port: 1883 MQTT ID: ESP32LR42 Relay1 Topic: R1Topic Relay2 Topic: R2Topic Relay3 Topic: R3Topic Relay4 Topic: R4Topic Input1 Topic: Input1Topic Input2 Topic: Input2Topic When the IP address is set to 0.0.0.0 this means that the IP address is being provided by...
ESP32LR42 User Manual v1.02 Sets the modules IP address. Enter IP followed by the required IP address. Entering address 0.0.0.0 means the IP will be obtained from your networks DHCP server. The new IP address will take effect after the next re-boot.
User Manual v1.02 SS This sets the SSID. The SSID is the public name of your WIFI network Enter your WIFI’s SSID here. SS “Devantech” OK. Saved SSID: Devantech PW Sets your networks WIFI password. PW "K]~kCZUV*UGA6SG~" OK. Saved Password: K]~kCZUV*UGA6SG~ PA Sets the TCP/IP port number for the ASCII commands.
ESP32LR42 User Manual v1.02 MS Sets the MQTT broker address MS “192.168.0.121” OK. Saved MQTT Server: 192.168.0.121 MD Sets the MQTT ID for this module MS “UniqueModuleName” OK. Saved MQTT ID: UniqueModuleName MP Sets the MQTT broker’s port. Normally, this should be set to 1883.
ESP32LR42 User Manual v1.02 TCP/IP Commands. The ESP32LR42 has a built in TCP/IP command set which allows you to control the module remotely. All commands are sent using plain ASCII text. PuTTY is a good cross platform terminal program to use for testing.
ESP32LR42 User Manual v1.02 GR Get Relay. Will return the state of the relay. To get the status of relay 3: GR 3 GR 3 GR 9 fail < relay 9 does not exist. Get Input. Will return the status of an input.
ESP32LR42 User Manual v1.02 HTML Commands. There are a set of HTML commands that can be used to control the module. ?Rly3=1 This will turn on relay 3 ?Rly3=0 This will turn off relay 3 ?Rly3=2 This will toggle relay 3 to the opposite state.
ESP32LR42 User Manual v1.02 Webpage The built in webpage can be used as a remote app to monitor and control the relays. Your can access the page as a default with just the IP address or by specifying index.htm. The webpage contains the Javascript to send an HTML toggle command, as described in the previous section.
ESP32LR42 User Manual v1.02 Relay Outputs 1 of 4 identical circuits shown The relays are capable of switching up to 16 Amps at 24vdc or 230vac. A data sheet of the relay can be found here. Only the normally open (N/O) contact has the snubber circuitry.
ESP32LR42 User Manual v1.02 Digital Input 1 of 2 identical circuits shown Digital Inputs have a pull-up resistor to 3.3v and will operate with a simple contact closure to ground. Alternatively, they may be connected to 3.3v logic. The clamping diodes prevent operation at voltages higher than 3.3v, so don’t connect to 5v logic.
Need help?
Do you have a question about the ESP32LR42 and is the answer not in the manual?
Questions and answers