I’m inserting trace message into the DW code so that I can try to understand what it does.

I’d like to figure the simplest sequences to do the following:

  1. Power-up from off, or very, deep sleep;
  2. Power down, or enter very, deep sleep;
  3. Get ready to receive and respond to a ranging request;
  4. Issue a ranging request, and capture the result.
My cursory work through the code suggests that I’m being a bit naive about the complexity.

Earlier, I said that I didn’t think any particular pin configuration really mattered, and I have not changed my mind… yet anyway.

They specify two sets of SPI pins, but it looks like they may dedicate one complete set for their LCD. But why?  Perhaps it is super slow, and locks out the radio which perhaps has some crisis time?

They may have four LEDs connected directly to the DW chip.

#define GPIO_MSGP0_MASK 0x000000C0UL /* Mode Selection for GPIO0/RXOKLED */
#define GPIO_MSGP1_MASK 0x00000300UL /* Mode Selection for GPIO1/SFDLED */
#define GPIO_MSGP2_MASK 0x00000C00UL /* Mode Selection for GPIO2/RXLED */
#define GPIO_MSGP3_MASK 0x00003000UL /* Mode Selection for GPIO3/TXLED */

#define GPIO_MSGP4_MASK 0x0000C000UL /* Mode Selection for GPIO4/EXTPA */
#define GPIO_MSGP5_MASK 0x00030000UL /* Mode Selection for GPIO5/EXTTXE */
#define GPIO_MSGP6_MASK 0x000C0000UL /* Mode Selection for GPIO6/EXTRXE */
#define GPIO_MSGP7_MASK 0x00300000UL /* Mode Selection for SYNC/GPIO7 */
#define GPIO_MSGP8_MASK 0x00C00000UL /* Mode Selection for IRQ/GPIO8 */

I found this comment, which could be useful for debugging is some places to hang a scope:

//this can be seen on the scope when GPIO5 is configured as EXTTXE output and GPIO6 as EXTRXE output

Leave a Reply