views:

344

answers:

1

Hi, I found very annoying the fact that the SerialPort class in the .NET Framework doesn't allow to set the rts control to TOGGLE.

There is a property called RTSEnable that lets me control directly the status of the RTS signal, but in a Compact Framework app there is not much precision to make it work well.

Another solution can be to write a class that calls unmanaged APIs and set the rts control via the DCB structure, but I don't like it since I am using some external libraries that need to reference to a SerialPort instance.

Have you any other idea ?

Thanks !

+2  A: 

Have you tried the OpenNETCF serial classes? Not sure if that has the precise feature you need but IMO it's better overall.

Call me crazy but I swear the CF version does weird things with threads.

Quibblesome
Yes, I tried it but they contain too much classes for the simple feature I look for.And .. yes, it does weird things ..
egapotz