Other Parts Discussed in Thread: CC2650
Hello everyone!
I'm currently working on porting RIOT OS to the CC2650 sensortag. In the past few days I've been writing the drivers for the radio, starting with BLE. Unfortunately I appeared to have hit a wall when it comes to configuring the radio through the CMD_RADIO_SETUP command (ID: 0x0802).
After sending the radio operation command to the RF core, it gets stuck and the command status never change from ACTIVE (0x002). I'm rather puzzled because:
- My code checks that the RF Core works properly by submitting both a PING direct command and a CMD_NOP radio operation command, both of which are handled successfully. Moreover I'm able to start the RAT using CMD_START_RAT.
- I've compared the content of my command byte to byte with the implementation of Contiki OS and they are exactly the same, except for the pointer value. Here is my command, divided in bytes:
[ 02 08 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 29 00 1c 00 00 20 ]
Any idea about what I'm missing? You can find my code on GitHub. Here is a summary of what I'm doing:
- Unlock clock gate for the RFC power domain
- Turn on the RFC power domain
- Turn on all available clocks in PWMCLKEN
- Enable interrupts
- Test the RF core by sending a PING and NOP command
- Turn on RAT timer using the direct command
- Send the RADIO_SETUP command (it fails here).
Any suggestion regarding BLE setup would be greatly appreciated. Thank you!