2023-12-12 21:18:14 -07:00
|
|
|
# Setup
|
|
|
|
Connect ESP32 TX2 & RX2 to DI & RO of the Max485.
|
2023-12-12 20:56:11 -07:00
|
|
|
|
2023-12-12 21:18:14 -07:00
|
|
|
Connect ESP32 D23(or whatever read_line is set to) to RE/DE.
|
|
|
|
|
|
|
|
Power Max485 with ESP VIN/GND.
|
|
|
|
|
|
|
|
Replace {WIFI_SSID}, {WIFI_PKEY}, {MQTT_HOST}, and {MQTT_PORT} in the code(and SubTopic if you want).
|
|
|
|
|
|
|
|
Flash the code onto the ESP32, connect A&B of the smart cable connected to the controller(aka the black and red wires respectively) to the Max485.
|
|
|
|
|
|
|
|
Viewing the USB serial of the ESP32, send 0xAB-like hex sequences to update the configured state.
|
|
|
|
|
|
|
|
Known States:
|
|
|
|
- 0xC9 : paused
|
|
|
|
- 0xE1 : driver competition
|
|
|
|
- 0xD1 : auton competition
|
|
|
|
- 0x61 : driver skills
|
|
|
|
- 0x51 : auton skills
|
|
|
|
|
|
|
|
All of the protocol reversing has been done with 1 brain & 1 controller, so any unique fields are constant and will need to be updated.
|