![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
This is a RS485 class that uses the second UART and was tested on a Nucleo F030R8. A main demo program howto use the class is included. This class control the direction pin on the transceiver buffer automatically, and used transmit and receive interrupts. Ring buffers (256 bytes) are implemented on both transmission and reception. It assumes a ADM3485 'type' buffer where pins 2 ans 3 are connected and seen as direction. This test program could easily be adapted as base for other programs.
Diff: main.cpp
- Revision:
- 9:d49cdc77f867
- Parent:
- 6:70460dcbc43c
- Child:
- 11:ca1e0ca3a673
diff -r 595258a79939 -r d49cdc77f867 main.cpp --- a/main.cpp Tue Nov 11 20:29:49 2014 +0000 +++ b/main.cpp Tue Nov 11 20:59:43 2014 +0000 @@ -25,7 +25,7 @@ dlms.initialise (9600, // baudrate 8, // bits, 'n', // parity - 2); // stop_bits + 1); // stop_bits debugger.printf (">> Setup Done \r\n"); } /** ---------------------------------------------------------------------------