Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: NaturalTinyShell_ice libmDot-12Sept mbed-rtos mbed
Fork of ICE by
src/ModbusMaster/ModbusMasterApi.h@83:0f76cfbb4eba, 2016-09-20 (annotated)
- Committer:
- davidjhoward
- Date:
- Tue Sep 20 16:21:17 2016 +0000
- Revision:
- 83:0f76cfbb4eba
- Child:
- 190:af7ab603c9fe
add API to access modbus registers
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| davidjhoward | 83:0f76cfbb4eba | 1 | #ifndef MODBUSMASTERAPI_H |
| davidjhoward | 83:0f76cfbb4eba | 2 | #define MODBUSMASTERAPI_H |
| davidjhoward | 83:0f76cfbb4eba | 3 | |
| davidjhoward | 83:0f76cfbb4eba | 4 | #include <string> |
| davidjhoward | 83:0f76cfbb4eba | 5 | #include "global.h" |
| davidjhoward | 83:0f76cfbb4eba | 6 | |
| davidjhoward | 83:0f76cfbb4eba | 7 | struct ModbusValue { |
| davidjhoward | 83:0f76cfbb4eba | 8 | float value; |
| davidjhoward | 83:0f76cfbb4eba | 9 | bool valid; |
| davidjhoward | 83:0f76cfbb4eba | 10 | }; |
| davidjhoward | 83:0f76cfbb4eba | 11 | |
| davidjhoward | 83:0f76cfbb4eba | 12 | bool ModbusMasterReadRegister( const std::string &io_tag, ModbusValue *value ); |
| davidjhoward | 83:0f76cfbb4eba | 13 | bool ModbusMasterWriteRegister( const std::string &io_tag, float value ); |
| davidjhoward | 83:0f76cfbb4eba | 14 | |
| davidjhoward | 83:0f76cfbb4eba | 15 | #endif |
| davidjhoward | 83:0f76cfbb4eba | 16 |
