Update: Recently, Microsoft introduced the new V2 version of their IoT Edge. This blog is referencing the former but still supported V1.
I do a lot of IoT research using the Advantech Wise 4012E IO module. It’s biggest advantages are that it runs on 5 Volts, using a MicroUSB connection (instead of a bulky 12V or 24V adapter) and it comes with knobs, switches and LEDs to simulate real sensors. So it’s a very compact but yet complete IoT device.
Until a few days ago I made use of the Rest protocol to contact that module but this has some disadvantages.
First, Rest is a great protocol in the IT world but it is not used that much in the OT world. Luckily, the IO module also supports the Modbus protocol. So I tried to switch to that protocol.
Second, Rest is very slow compared to other protocols like Modbus. Using Rest, I’m lucky when I can pull 2 or 3 requests a second out of the module.
In the previous blogs, we have seen multiple modules, both provided by Microsoft or created on the fly. And Microsoft provides a genuine Modbus module for the IoT Edge SDK. There is only one drawback, it’s on Github but it’s not available as NuGet package. You have to make/build it yourself!
And for some unknown reason, I did not get it working the way I liked it. I encountered too many exceptions.
Update: There is also a Version 2 of this module. In this blog, I refer to V1.
So, in the end, I just ignored the module and build my own Modbus module.
Continue reading “Introduction to the IoT Edge SDK V1, part 6: Modbus for Wise modules”