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.

CC2543 Transmit and Receive Example

Other Parts Discussed in Thread: CC2543

Hello Everyone, 

I have two custom made PCB with CC2543 on it. I tried to transmit from one to another but I was not successful, Can someone please provide me with the sample code for transmitting and receiving using CC2543. 

Thanks in advance 

Prashanth

  • Hello Prashanth, 

    Have you tried using SmartRF studio for communicating between your boards? This is a straight forward way to verify that the hardware is functional. Sample code for CC2543 is available on its product page under tools and software tab.

    http://www.ti.com/product/CC2543/toolssoftware

    Regards,
     

  • Hello SVS, 

    Thanks for the reply, I have only one CC debugger.  

    Is there any other way to try SmartRF with one CC debugger and connect two CC2543 boards ? 

    I modified the PER test code to operate in Master beacon mode (text marked in red is what i have changed in the code to operate in master mode) and flashed it to one board and connected the other to SmartRf in packet RX mode, but i did not receive any packets.  freq used : 2402 Mhz , modulation used : GFSK 250kbps 160khz


    // Wait for user to press S1 to enter menu.
    /* while(halButtonPushed() != HAL_BUTTON_1) {
    #if(POWER_SAVING)
    halSleepEnterPowerMode(CPU_HALT);
    #endif
    }*/

    #if(POWER_SAVING)
    // Interrupt disable on P0.1 (Button1).
    P0IEN &= ~BIT1;
    // Disable CPU Interrupt for Port 0 (IEN1.P0IE = 1).
    P0IE = 0;
    #endif

    // Query user for operating mode.
    // mode = queryMode();
    mode = MASTER ;

    if(mode == MASTER) {
    while(1) {
    // Start transmitting beacon packet every 10 ms.
    masterBeaconMode();
    do {
    // Start PER terst in transmit mode.
    runCondition = masterTxMode();
    } while(runCondition == ACK_COMMAND_RESTART);
    }
    }

    Regards, 

    Prashanth

  • Hello,

    Try to download the code you downloaded from web onto both devices as there is a difference between the pre-loaded code and the latest version on web.

    Also note that there might be a small bug in the argument given for the halRfSetFrequency() function where the incorrect frequency will be set. We will fix this in the next version.

  • Hello,

    According to the last post in this thread, the code for the CC2543(www.ti.com/.../toolssoftware needs to be updated as per the stated bug in the previous post. Please update the code and send me to projects@distronix.in

    We have tried with the software files provided in the TI site but failed to get the desired output.

  • You can download PER test SW from www.ti.com/.../cc2543-cc2544dk
  • To YiKai Chen,

    I don't have the development kit with me so a lot of lcd stuff is needed to be removed from the code segments given. Moreover when I removed the LCD functionalities and tried to implement the core BLE broadcast the debug window was stuck at  the interrupt section. I have attached the screenshot of the debug process where I am stuck right now.

    Kindly help me to get through it. 

  • What CC2543 EVB do you use?
  • I am currently using the module given in the website :

    www.ti.com/.../TIDC-MINI-BLUETOOTH-LOW-ENERGY-BROADCASTER
  • Hello Aninda,

    Use the software developed for the Mini Bluetooth® Low Energy Broadcaster board instead:

    CC2543 mini-BLE Broadcaster

  • Hello Eirik,

    The errors I got were from the same sode segments given by you. Need some alternatives for it. You can see the pictures attached for more reference.

    Thank you

    Aninda Ghosh

  • Hello Aninda,
    What are you trying to achieve? To simply send ble advertisements?
    DO you have en exact copy of the TIDC-MINI-BLUETOOTH-LOW-ENERGY-BROADCASTER board?
  • Dear Eirik,

    Yes what I am trying to achieve is to simply transmit BLE advertisements. And yes I have the Exact copy of the board.

    Regards, 

    Aninda

  • Hello Aninda,
    Then simply use the suggested software (NOT the PER test). and choose the cc2543_weather_station project configuration for the correct board project board configuration. Look at the GenericBroadcaster project.