[B96B_F446VE] change serial type

Use only the index, not the UARTName any more.
In case of app with 2 serial (using DMA) + 1 serial (stdio), we have found a bug. The dma handler is overwritten by the last initialized serial object.
Therefore read and write functions did not work anymore.
We have reworked this file to save 1 handler per UART IP, and align it with MBED OS file.
Tests have been passed. Same status as before (OK except MBED_37, manual test for SERIAL_ASYNC also OK).
pull/1530/merge
adustm 2016-02-12 16:37:25 +01:00 committed by 0xc0170
parent 471fa67c7d
commit 028465a9b8
2 changed files with 594 additions and 249 deletions

View File

@ -66,8 +66,7 @@ struct dac_s {
};
struct serial_s {
UARTName uart;
int index; // Used by irq
int index;
uint32_t baudrate;
uint32_t databits;
uint32_t stopbits;