Erich Styger’s Modbus RTU Venture Connects Microcontrollers to Electrical Car Charging Containers


    Embedded developer Erich Styger’s newest mission provides a take a look at controlling an electrical automobile (EV) charging station from a Raspberry Pi Pico W or comparable microcontroller board — utilizing the Modbus Distant Terminal Unit (RTU) protocol to observe the system and cost a automobile solely when solar energy is accessible.

    “I’ve spent a while right this moment on a little bit aspect mission […] about making an Electrical Car (EV) wallbox charger accessible over Modbus RTU,” Styger writes by means of introduction. “It isn’t completed but, and I plan to publish extra articles on it, however I can share that I’m capable of entry and management the Heidelberg EV charger with a Raspberry Pi Pico W (Twin Core [Arm] Cortex M0+), NXP K22FN512 (Cortex M4F) and LPC845 (Single Core Cortex M0+).”

    The mission, impressed by rising vitality costs and a want to change from a hybrid to a completely electrical automobile within the coming months, facilities across the 11kW Heidelberg Power Management wallbox — chosen, partly no less than, for the producer’s provision of a Modbus RTU interface from which the system will be queried and managed.

    “What I actually wished is to combine the charger into my residence vitality administration system (HEMS with House Assistant),” Styger explains. “For this the Modbus (RS-485) interface is essential: with this, I can regulate and management charging based mostly on the vitality coming from the PV (photovoltaic) system, optimizing photo voltaic vitality utilization. Ideally, no grid electrical energy is used for charging the automobile, as a result of the system follows the photo voltaic manufacturing.”

    Styger has wired the Modbus on the cost controller to one in every of quite a few microcontroller boards he has out there, together with the low-cost Raspberry Pi Pico W — although notes the firmware doesn’t but make the most of the board’s built-in Wi-Fi connectivity. The microcontroller communicates with the charger utilizing the Modbus RTU protocol, offering entry to system standing together with occasions reminiscent of automobile connection and management over its settings — key to the ultimate objective of with the ability to cost a automobile purely when solar energy is accessible.

    “Thus far I’ve a command line interface working, working on an NXP LPC845, NXP K22FN512, and a Raspberry Pi Pico W,” Styger concludes of the work in progress. “The Pico W will give me a WiFi interface. Moreover I plan to design a devoted PCB, having a small OLED and a few buttons as a person interface. The total integration into House Assistant is pending too.”

    The total write-up is accessible on Styger’s web site; the supply code has been rolled into the McuOnEclipseLibrary mission, out there on GitHub beneath a permissive open supply license.


    Please enter your comment!
    Please enter your name here