umanovskis / baremetal-arm

An ebook about bare-metal programming for ARM
Other
626 stars 130 forks source link

Wrong bit offset for word length selection #2

Closed dublevskyi closed 5 years ago

dublevskyi commented 5 years ago

According to the PrimeCell UART (PL011) TRM word length bits are [6:5], so I'm pretty sure the offset should be 5 instead of 6

https://github.com/umanovskis/baremetal-arm/blob/dcee0f86222f58735acd478226b96d3c232fc7a4/src/06_uart/src/uart_pl011.h#L52-L55

umanovskis commented 5 years ago

You're right of course. Will fix shortly.

umanovskis commented 5 years ago

Commit 4ce7973889b fixes the offset.