This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CC2640R2F: High speed packet mode TX not working

Part Number: CC2640R2F

Some background: I need the high speed 5Mbps radio mode for a project. I was supplied with an example smartrf_settings_predefined.c file from a TI applications engineer that should be compatible with the CC2640R2-LAUNCHXL board, and told to look at the rfPacketErrorRate example from the CC13XX SDK for an example of how to use the high speed API. 

So I imported the rfPacketErrorRate example from the SimpleLink CC2640R2 SDK into code composer studio, then modified it to allow the user to use the high speed API with the CC2640-LAUNCHXL board. This required me to modify the menu selection to allow HS mode to be used with this board, modify the tx and rx files to allow the board to call the HS mode commands, and re-implement the HS mode command structures in the smartrf_settings_predefined file followed by tying the pointers to the structures. I also had to import the rf_hs_cmd.h and rf_hs_mailbox.h files from the CC13XX SDK into the project, as those files don't exist in the CC2640R2 SDK. Finally I also modified the smartrf_settings_predefined file, importing the changes from the example file I was provided with. 

So theoretically the code should now run the radio in HS mode when selected, and at the very least the chip doesn't crash when I try it. However TX doesn't appear to work. I don't see any output when using an RF spectrum analyzer to verify whether the transmitter is working or not. Also tellingly, the command is set to wait 50ms between packets, but the callback is executed almost immediately (it'll "send" 10000 packets in one second, which should definitely be impossible with 50ms between packets). But the callback is at least getting called, so I know the HS mode commands should at least be getting sent to the M0 core. 

I was hoping someone could provide suggestions on places I can look to try and narrow down the root cause of the issue, or else if they have a likely answer I'd appreciate it. The project is attached as a zip archive below. 

  • Sorry, forgot to mention the included project uses the TI RTOS, so you'll need to import the CC2640R2 TI RTOS into your workspace before it will build and run. No modifications to the RTOS.
  • Hello,

    We are looking at the project that you have shared with us and will get back to you by Monday.

    Regards,

  • It's been a week since I saw any communication on this topic. I know things take time, so I'm just pinging the thread to make sure I don't fall off the radar completely. 

  • Hi,

    I tried to build the project that you shared with us and could not successfully build it. Which version of CCS and SDK are you using?

    The settings in the smartrf settings file look OK. When you execute CMD_HS_TX, what is the status of the command, does is complete without errors?

    Regards,

  • The project is building on my machine using CCS 8.1.0.00011, SDK is SimpleLink CC2640R2 v2.20.00.49. On Monday morning I'll try transferring the project between computers here and recreating any issues you might be stumbling into on your end. Again, I forgot to include the TI RTOS project for CC2640R2 in the files I have given you, so you'll have to add that to the workspace for things to work properly.
  • OK, thank you. Also, if are able to look at the status on Setup, FS and TX commands, we can narrow down on problem area.
  • SVS,

    I've ported the project over to another computer here, so I think I've figured out why it wasn't building for you. Let me know how to send you the updated project and build instructions directly so I don't have to post them here. I've also used the debugger to grab the data you're looking for. Line numbers are based on the new project (but the old project is almost exactly the same, so they should be nearly right there). I'm using the default frequency and number of packets for this test:

    The RF_open command gets executed on line 419 of tx.c, and returns 0x20001B80. This indicates that pushing the chip into high speed mode was successful, as the command gave me back a valid location for the RF handle. There is no callback, so nothing to check there. 

    The CmdFs command gets executed on line 659 of tx.c, and returns 2 (RF_EventLastCmdDone). This should indicate the command was successful, as far as I'm aware. There is no callback, so nothing to check there. 

    The initial TX command gets executed on line 689 of tx.c, and returns 2. Posting the command at least should be successful because I was given a valid command handle. When the callback is posted, the reported RF handle was 0x20001B80 (correct), the Command Handle was 2 (matches, so correct), and the event mask was 2 (RF_EventLastCmdDone). I was under the impression that this response indicated success. 

    The remaining TX commands get executed in the callback on line 792. The only difference between these calls and the initial call is that the command handle changes, which should not be a problem. 

    Nate

  • Hello Nate,

    I am able to compile the project now, will check and get back to you soon.

    Regards,

  • Hello Nate,

    There is a problem with TX queue setup in the code that you shared with us. Following is the snapshot of status on different commands.

    Can you please check for initialization of TX queue for HS command.

    Regards,

  • SVS,

    Got it. The problem was on line 195 of tx.c. The queue was getting initialized correctly but because of the ifndef at that line, the queue location and trigger types were not getting correctly assigned for HS mode. This is  because I missed removing the board from the HS mode the exclusion list at this location. The same problem was also in rx.c, on line 323. The boards are communicating in HS mode now. Thanks for all the help, this should get me going for awhile. 

    Nate