Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: UART9BIT.h
- Revision:
- 6:64f5dad70ee2
- Parent:
- 5:b97a733f6ed8
- Child:
- 7:af4ceb878eee
diff -r b97a733f6ed8 -r 64f5dad70ee2 UART9BIT.h
--- a/UART9BIT.h Tue Aug 20 11:20:26 2019 +0800
+++ b/UART9BIT.h Wed Aug 21 16:27:30 2019 +0800
@@ -29,11 +29,19 @@
UART9BIT(PinName tx, PinName rx, int baud,bool en9bit);
-
+void format(int bits = 9, Parity parity = UART9BIT::None, int stop_bits = 1);
+void GetUartName(void);
+int write(const uint16_t *buffer, int length, const event_callback_t &callback, int event = SERIAL_EVENT_TX_COMPLETE);
+int read(uint16_t *buffer, int length, const event_callback_t &callback, int event = SERIAL_EVENT_RX_COMPLETE, unsigned char char_match = SERIAL_RESERVED_CHAR_MATCH);
+
-
+protected:
bool Enable9Bit;
-
+ void start_read(void *buffer, int buffer_size, char buffer_width, const event_callback_t &callback, int event, unsigned char char_match);
+ void start_write(const void *buffer, int buffer_size, char buffer_width, const event_callback_t &callback, int event);
+
+ void interrupt_handler_asynch(void);
+ CThunk<UART9BIT> _thunk9_irq;
};
}