Commit 555b0e1
committed
Allow Serial::new instead of Serial::usartX
This requires changing I2C to a more generic implementation,
where the specific UART peripheral implementation get's dispatch
upon it's Instance trait.
The specific UART is longer hard coded into, but instead is referenced
via pointer (trait).
This also allows to reduce the usart macro implementation, so that
the code is easier to follow.
But this leads to code duplication, as code for the Write and Read
trait of embedded-hal can no longer be shared between Serial and Tx |
Rx.
Also, the underlying UART peripheral of Tx and Rx after split has to be
tracked at runtime, instead of being decoded at compile time (via macro).
In addition to all of this the Idle interrupt event was also added.1 parent 4084456 commit 555b0e1
File tree
7 files changed
+472
-309
lines changed- examples
- src
- testsuite/tests
7 files changed
+472
-309
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
22 | 26 | | |
23 | 27 | | |
24 | 28 | | |
| |||
70 | 74 | | |
71 | 75 | | |
72 | 76 | | |
| 77 | + | |
73 | 78 | | |
74 | 79 | | |
75 | 80 | | |
| |||
325 | 330 | | |
326 | 331 | | |
327 | 332 | | |
| 333 | + | |
328 | 334 | | |
329 | 335 | | |
330 | 336 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
32 | | - | |
| 32 | + | |
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
| 67 | + | |
| 68 | + | |
74 | 69 | | |
75 | 70 | | |
76 | 71 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
275 | 275 | | |
276 | 276 | | |
277 | 277 | | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
278 | 281 | | |
279 | 282 | | |
280 | 283 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
203 | 203 | | |
204 | 204 | | |
205 | 205 | | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
0 commit comments