SpinalHDL / SpinalDoc-RTD

The sources of the online SpinalHDL doc
https://spinalhdl.github.io/SpinalDoc-RTD/
Creative Commons Zero v1.0 Universal
25 stars 61 forks source link

Document mistake #268

Closed BrokenClient closed 1 month ago

BrokenClient commented 1 month ago

Hi, I am new to SpinalHDL.

I wonder if this is a mistake on https://spinalhdl.github.io/SpinalDoc-RTD/master/SpinalHDL/Examples/Intermediates%20ones/uart.html#implementation:~:text=%3DUartCtrlInitConfig(%0A%20%20%20%20%20%20baudrate%20%3D%20115200%2C-,dataLength%20%3D%208%2C,-parity%20%3D%20UartParityType.NONE%2C%0A%20%20%20%20%20%20stop

that dataLength should be 7.

Also, when I use 8 and build, I got the error

WIDTH MISMATCH (3 bits <- 4 bits) on (toplevel/uartCtrl/io_config_frame_dataLength : in UInt[3 bits]) := (U"1000" 4 bits) at 
    spinal.lib.com.uart.UartCtrl$.apply(UartCtrl.scala:181)
    uart.VexDLCUart.<init>(UartCtrl.scala:16)
    uart.build$.$anonfun$new$6(UartCtrl.scala:85)
Dolu1990 commented 1 month ago

Hi,

Yes right :D I just pushed a fix.