rp-rs / rp2040-pac

A Rust PAC for the RP2040 Microcontroller
142 stars 28 forks source link

changed buad_divint bits value to u32 #71

Closed ArchUsr64 closed 1 year ago

ArchUsr64 commented 1 year ago

Allows for merging of https://github.com/rp-rs/rp-hal/pull/583

jannic commented 1 year ago

rp2040-pac is generated from the SVD file. Please don't change the generated files manually. If a change is needed, it should fix rp2040.svd - or svd2rust, if the bug was caused by the code generator.

However, in this case, I don't think this change is appropriate. The field BAUD_DIVINT is a 16 bit field, so u16 is the correct data type.

ArchUsr64 commented 1 year ago

rp2040-pac is generated from the SVD file. Please don't change the generated files manually. If a change is needed, it should fix rp2040.svd - or svd2rust, if the bug was caused by the code generator.

However, in this case, I don't think this change is appropriate. The field BAUD_DIVINT is a 16 bit field, so u16 is the correct data type.

I wasn't aware that the code was generated from SVDs, the relevant fix can be contained within the hal and doesn't require pac to be modified.