Azure / iot-edge-modbus

Modbus protocol module for use with the Azure IoT Edge
Other
90 stars 71 forks source link

Windows Container Modbus module on Windows 10 1809 LTS supports RTU? #86

Closed sandervandevelde closed 4 years ago

sandervandevelde commented 4 years ago

The documentation says that RTU is currently not available in a Windows environment.

Is this still true for Windows Containers on Windows 10 1809 LTS support for RTU?

According to this and that and this is seems windows containers could access COM ports in some way.

Is this also applicable to Moby on Windows?

If so, what will be the Container Create Options look like?

sandervandevelde commented 4 years ago

I found a solution while I migrated my project to .Net Core 3.1, as seen in the newest IoT Edge templates. (I'm not sure if this will work with the current Modbus module, though).

The Container Create Options I use are:

{
    "HostConfig": {
                    "Devices": 
                    [
                                    {  
                                        "CgroupPermissions":"",
                                                    "PathInContainer":"",
                                                    "PathOnHost":"class/86E0D1E0-8089-11D0-9CE4-08003E301F73"
                                    }
                                ],
                                "Isolation":"Process"
    }
}

This gives access to all serial ports on Windows 10 IoT Enterprise 1809 LTS.