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.

RX CC110L Energia Code Freeze

Other Parts Discussed in Thread: CC110L, ENERGIA, MSP-EXP430F5529LP

I have recently begun working with the MSP430 launchpads and have been using Energia to program it.  My previous tests have thus far proven successful, such as creating a bit counter and reading a analog input.  I am not attempting to work with the CC110L booster pack in combination with the MSP430 launchpad and Energia, and have been having difficulties working with it.  When I tried running the example codes offered by Energia, it caused the code to freeze and not work properly.  I have tried my own simple tests, and each time the code freezes.  One such example code is as follows:

#include <SPI.h>
#include <AIR430BoostFCC.h>
#define led P6_1

// Data to read from radio RX FIFO (60 bytes MAX.)
unsigned char rxData[6] = { '\0', '\0', '\0', '\0', '\0', '\0' };

void printRxData()
{
  Serial.print("RX (DATA, RSSI, LQI, CRCBIT): ");
  Serial.print("(");
  Serial.print((char*)rxData);
  Serial.print(", ");
  Serial.print(Radio.getRssi());
  Serial.print(", ");
  Serial.print(Radio.getLqi());
  Serial.print(", ");
  Serial.print(Radio.getCrcBit());
  Serial.println(")");
}

void setup()
{
  pinMode(led, OUTPUT);  
  digitalWrite(led, HIGH);
  Serial.begin(9600);
  Serial.println("program start");
  // put your setup code here, to run once:
  Radio.begin(0x01,CHANNEL_1, POWER_MAX);
}

void loop()
{
  // put your main code here, to run repeatedly:
  if (Radio.receiverOn(rxData, sizeof(rxData), 1000) > 0){
    digitalWrite(led, HIGH);
    printRxData();
    delay(1000);
  }
  else{
    digitalWrite(led, LOW);
    Serial.print("No Data recieved, ");
    Serial.println("please confirm transmission.");
    delay(1000);
  }
}


I have looked into various forum posts for questions similar to my own, and have thus far been unable to find a reason for my program freezing.  The example code above allows for the device to light up the LED on the breadboard, as well as print the message "program start" without trouble, but it always freezes when it reaches "Radio.begin(0x01,CHANNEL_1, POWER_MAX);" without any obvious explanation as to why.  The specifics of my program and parts used are as follows:

Energia 0101E0013

MSP-EXP430F5529LP  ( Initial Launchpad used )

MSP-EXP430G2  ( Specific chip is M430G2553 )

Anaren Air - CC110L booster pack - Anaren LR09A

If anyone can help me figure out what is causing this error, and how I can fix it so that I can use Energia and my CC110L booster pack, I'd greatly appreciate a response.

  • Hi

    I am not familiar with Energia so to be able to help you I would need to know what is happening on the lower levels of the code. What does the Radio.begin function do? I  guess that it somehow communicate with the radio over SPI? Is it hanging because it is read a register and the register does not return the expected value, is it waiting for a pin that is never set (a GDO pin for example) or is it polling the MISO pin (CHIP_RDYn) and is not getting the expected result?

    A logic analyzer plot of the SPI traffic together with details of the function will be useful.

    Siri

  • According to the official Energia Documentation regarding the AIR430Boost Radio Driver, the purpose of this line of code is to "Setup the SPI peripheral and I/O, GDO0 interrupt I/O, and initialize the radio session."  Although in the document it does not have the "Radio." before the begin function, the examples offered by Energia are written in such a manner.  I attempted to run the code as just the begin function, however I received errors when trying to do so.  I will attach the document I am referring to in this post.  Maybe I am just missing some little detail that someone else will notice.

    7343.Energia Documentation - AIR430Boost Radio Driver.pdf

  • Hi

    I am afraid that this document did not give me the details I need to be able to help you. If the problem is related to our Radio (CC110L) I would need to know what is going on between the MCU and the radio on the SPI interface to be able to figure out what is going on. If you are not able to measure on the SPI interface to see what is sent to the radio and what is returned it is hard to say what is going on. I would recommend that you try to contact Energia for support.

    BR

    Siri