From binary file to target device using Modbus TCP/IP
-
Hi!
I'm making some tests with Mango to monitor/control a remote device using Modbus TCP/IP source and it works great!Now I need to read some data from a binary file and to send them to my device. This should be triggered from the HTML5 dashboard. Is there a simple way to do it or best pratices which have to be followed?
Thanks a lot.
LarryMango Core version: 2.8.4
Mango API module version: 1.2.0
Mango Dashboards module version: 3.3.0
Platform and version: Raspbian Jessie (kernel version 4.4) on Raspberri Pi 3 Model B
Browser and version: Chrome 56 -
Hi Larry,
Can you say more about it?
From this little bit, there is an arbitrary binary file that you would like parsed into information to send out to specific modbus points? We solved a similar problem somewhat recently, but we wrote a module for that client that included handling for the file and providing a place to upload it. Without a module like that, there is not a clear way to do what I think you're asking in 2.8. I was inspired to add a Binary type to the Data File data source from this question, though. The data file module has an endpoint in 3.0 to POST a file to and import it immediately, and that sounds like what you're looking for. We're working hard to get 3.0 releases happening soon.
You may have other options, though, such as setting an alphanumeric point to some representation of the file and parsing it out of the alphanumeric point, but it doesn't seem so straightforward.