Modbus RS485 with esp32

Hello, I have a small project where I want to connect an RS485 sensor to an ESP32 microcontroller and read data from the sensor using the Blynk application. I have been searching for information on how to connect a Modbus sensor to the ESP32, but have not been able to find any helpful resources. Can anyone provide me with code or guidance on how to do this using the Max485 ?

The principal is the same as when you are using an ESP8266 based board such as the NodeMCU or Wemos D1 Mini, but obviously you’d use different pins.

A few fairly detailed topics about using these MAX458 boards and an ESP8266 based MCU with the Epever solar charge controllers here…

Pete.