ArduinoModbus
ArduinoModbus copied to clipboard
added methods to configure modbus server to existing data stuctures
With memory being tight on most micro controllers, I felt like I shouldn't have to allocate memory for Modbus to use, but instead point the server at existing data structures. If the structures are not of the same type, the user can cast it as such. I tried this PR before but had the incorrect local user account in my git config, and therefore could not sign the contributor agreement because it didn't match my Github account.
Memory usage change @ 7997cf998c6074be6fa9959333dc1a83e37b562b
Board | flash | % | RAM for global variables | % |
---|---|---|---|---|
arduino:avr:leonardo | 0 - 0 | 0.0 - 0.0 | 0 - 0 | 0.0 - 0.0 |
arduino:mbed:envie_m7 | 0 - 0 | 0.0 - 0.0 | 0 - 0 | 0.0 - 0.0 |
arduino:mbed:nano33ble | 0 - 0 | 0.0 - 0.0 | 0 - 0 | 0.0 - 0.0 |
arduino:megaavr:uno2018:mode=off | 0 - 0 | 0.0 - 0.0 | 0 - 0 | 0.0 - 0.0 |
arduino:samd:mkrwifi1010 | 0 - 0 | 0.0 - 0.0 | 0 - 0 | 0.0 - 0.0 |
Click for full report table
Board | examples/RTU/ModbusRTUClientKitchenSink flash |
% | examples/RTU/ModbusRTUClientKitchenSink RAM for global variables |
% | examples/RTU/ModbusRTUClientToggle flash |
% | examples/RTU/ModbusRTUClientToggle RAM for global variables |
% | examples/RTU/ModbusRTUServerKitchenSink flash |
% | examples/RTU/ModbusRTUServerKitchenSink RAM for global variables |
% | examples/RTU/ModbusRTUServerLED flash |
% | examples/RTU/ModbusRTUServerLED RAM for global variables |
% | examples/RTU/ModbusRTUTemperatureSensor flash |
% | examples/RTU/ModbusRTUTemperatureSensor RAM for global variables |
% | examples/TCP/EthernetModbusClientToggle flash |
% | examples/TCP/EthernetModbusClientToggle RAM for global variables |
% | examples/TCP/EthernetModbusServerLED flash |
% | examples/TCP/EthernetModbusServerLED RAM for global variables |
% | examples/TCP/WiFiModbusClientToggle flash |
% | examples/TCP/WiFiModbusClientToggle RAM for global variables |
% | examples/TCP/WiFiModbusServerLED flash |
% | examples/TCP/WiFiModbusServerLED RAM for global variables |
% |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
arduino:avr:leonardo | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | ||||||||
arduino:mbed:envie_m7 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | ||||||||||||||||
arduino:mbed:nano33ble | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | ||||||||||||||||
arduino:megaavr:uno2018:mode=off | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 |
arduino:samd:mkrwifi1010 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 | 0 | 0.0 |
Click for full report CSV
Board,examples/RTU/ModbusRTUClientKitchenSink<br>flash,%,examples/RTU/ModbusRTUClientKitchenSink<br>RAM for global variables,%,examples/RTU/ModbusRTUClientToggle<br>flash,%,examples/RTU/ModbusRTUClientToggle<br>RAM for global variables,%,examples/RTU/ModbusRTUServerKitchenSink<br>flash,%,examples/RTU/ModbusRTUServerKitchenSink<br>RAM for global variables,%,examples/RTU/ModbusRTUServerLED<br>flash,%,examples/RTU/ModbusRTUServerLED<br>RAM for global variables,%,examples/RTU/ModbusRTUTemperatureSensor<br>flash,%,examples/RTU/ModbusRTUTemperatureSensor<br>RAM for global variables,%,examples/TCP/EthernetModbusClientToggle<br>flash,%,examples/TCP/EthernetModbusClientToggle<br>RAM for global variables,%,examples/TCP/EthernetModbusServerLED<br>flash,%,examples/TCP/EthernetModbusServerLED<br>RAM for global variables,%,examples/TCP/WiFiModbusClientToggle<br>flash,%,examples/TCP/WiFiModbusClientToggle<br>RAM for global variables,%,examples/TCP/WiFiModbusServerLED<br>flash,%,examples/TCP/WiFiModbusServerLED<br>RAM for global variables,%
arduino:avr:leonardo,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0
arduino:mbed:envie_m7,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,,,,,,,,
arduino:mbed:nano33ble,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,,,,,,,,
arduino:megaavr:uno2018:mode=off,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0
arduino:samd:mkrwifi1010,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0