Missing memory layout in svd #351

Closed
opened 2021-04-20 17:06:49 -05:00 by Szpadel · 1 comment
Szpadel commented 2021-04-20 17:06:49 -05:00 (Migrated from github.com)

I'm trying to implement USB driver in rust and I cannot find endpoint and buffer controll registers. It looks like there is nothing from base 0x5010000 to 0x5011000.
I confirmed that there should be controller structures in datasheet and are used in c implementation.

Am I missing something or there is some issue with svd?

I'm trying to implement USB driver in rust and I cannot find endpoint and buffer controll registers. It looks like there is nothing from base 0x5010000 to 0x5011000. I confirmed that there should be controller structures in datasheet and are used in c implementation. Am I missing something or there is some issue with svd?
lurch commented 2021-04-21 04:16:31 -05:00 (Migrated from github.com)

I just checked, and I guess you're asking about the USBCTRL_DPRAM stuff? https://github.com/raspberrypi/pico-sdk/blob/master/src/rp2040/hardware_regs/include/hardware/regs/addressmap.h#L65

The C SDK comprises some headers that are autogenerated (hardware_regs), and some that are manually-edited (hardware_structs) - the hardware_structs headers generally make use of things defined in the hardware_regs headers. The SVD file is also autogenerated.

The USBCTRL_REGS stuff appears in the autogenerated hardware_regs headers and the SVD file, but the USBCTRL_DPRAM stuff only appears in the hand-edited headers (and therefore not the SVD).

I know nothing about the USB controller in the RP2040, so pinging @liamfraser for advice on what can / should be added to the SVD file.

I just checked, and I guess you're asking about the `USBCTRL_DPRAM` stuff? https://github.com/raspberrypi/pico-sdk/blob/master/src/rp2040/hardware_regs/include/hardware/regs/addressmap.h#L65 The C SDK comprises some headers that are autogenerated ([hardware_regs](https://github.com/raspberrypi/pico-sdk/tree/master/src/rp2040/hardware_regs)), and some that are manually-edited ([hardware_structs](https://github.com/raspberrypi/pico-sdk/tree/master/src/rp2040/hardware_structs)) - the `hardware_structs` headers generally make use of things defined in the `hardware_regs` headers. The SVD file is also autogenerated. The `USBCTRL_REGS` stuff appears in the autogenerated hardware_regs [headers](https://github.com/raspberrypi/pico-sdk/blob/master/src/rp2040/hardware_regs/include/hardware/regs/usb.h) and the [SVD file](https://github.com/raspberrypi/pico-sdk/blob/master/src/rp2040/hardware_regs/rp2040.svd), but the `USBCTRL_DPRAM` stuff only appears in the hand-edited [headers](https://github.com/raspberrypi/pico-sdk/blob/master/src/rp2040/hardware_structs/include/hardware/structs/usb.h) (and therefore not the SVD). I know nothing about the USB controller in the RP2040, so pinging @liamfraser for advice on what can / should be added to the SVD file.
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gh-raspberrypi/pico-sdk#351
No description provided.