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.

MSP430FR5739 with EZ-430 RF2500 possible ?

Other Parts Discussed in Thread: MSP430FR5739, SIMPLICITI, CC2500, MSP-EXP430FR5739, MSP430F2013

Hello all , i want to use the feature of MSP430FR5739 to collaborate with RF2500 so that there is fast data writing and very low power comnsumption of controller itself which can have a lot of benefits. For this i want to ask some basic questions.

1. How to connect the Fraunch Pad and RF2500 ? like powering up both by same source such as a solar panel or SEH kit available from TI and how should both be programmed from same source. i.e USB emulator within RF2500 kit. I can configure ADC, clocks and all so i think programming wouldnt be a problem . But i am confused with the Hardware connection as i am pretty new at this. Because what i can come up is . 

 

RF2500's emulator will program MSP430FR5739--->MSP will sample-->MSP will send data to RF2500----> then it will send data wirelessly to RF2500 connected at PC.

So basically it is like i want to remove the MSP430 already connected to RF2500 target board kit and replace with FRAM.

Any help would be greatly appreciated like i dont know from where to begin. I know about MSP430FR5739 pretty good. But nothing about RF2500 and how to connect it.

Thnx

  • Hello Sarmad. I have the RF2500T working on the FR5739 using TI's CC2500 HAL and also SimpliciTI.

    See http://www.43oh.com/forum/viewtopic.php?f=8&t=1192#p7896 for the reconfigured libraries.

    See http://www.43oh.com/forum/viewtopic.php?f=8&t=1953&p=13963#p13963 for the SimpliciTI BSP for the MSP-EXP430FR5739

    You will need to program the F2274 to deselect the CC2500. I've set the F2274 to detect edges on the GDO pins then toggle the onboard leds. It frees up led indicators on the dev board this way.

  • Thakyou very much for guidance. I wanted to ask you are programming RF2500T through Onboard FR5739 emulator too ? with that 6 wire connector. And i havent checked the codes but it samples internal temperature of FR5739 ?

  • hey i get the message like 

    "MSP430: GEL: Encountered a problem loading file: C:\RF+5739\Debug\RF+5739.out Could not open file" isnt this the problem that i have made a project and SIMPLICITI in C folder while my original CCS is installed in G ? 

    1. All that i have done is i have followed that tutorial but, i have included in Boards your EX5739 folder , also in include options. 

    the CC2500_fr5739 i have put in main tree. and i havent changed any debug configuration. 

    Can you tell what could be the problem ? 

    Thankyou very much

  • Hello Sarmad, the CC2500_fr5739.zip is a completely separate program and libraries from the SimpliciTI project. The first libraries are a bare bones method of getting the RF2500 to work. You would have to roll your own communication functions.

    With the SimpliciTI project, if your includes and defines are set up properly there shouldn't be any issues. I would start with creating a new project, leaving out the '+' in the file name. That may cause some issues.

    That tutorial was designed around using the Launchpad and CC2500 radio. It's a similar process, but there will be differences in the way the clock/timer is initialized on the TX application. The RX application code that is posted should compile with no issues for the FR5739.

  • Hi ,

    I have compiled your CC2500_fr5739 program using IAR. and it has launched succesfully. Now i have some questions.

    I should observe charecters sent to hyperterminal after having programmed both RF2500t with MSP430FR5739. and the putting one with the dongle at PC side. And one with FR5739 for transmission.

    But when i press switches on FRboard. It doesnt show the expected outcome. which i am supposing is like. LED's should toggle at the same rate of me pressing switches. ? and can you explain how did you configure. txbuffer[ ] ?

    Thnx a million. your developed thing is really nicely written.

     

    Best Regards,

    sarmad

  • What program did you install to the RF2500t? Turn the cpu off for testing on the RF2500t. You could also set the F2274 to be off and waiting for edge detects on P2.6 & P2.7, the edge interrupts could then toggle the onboard leds as your radio indicators.

    Do you have female headers installed on all 18 pins of the RF2500t? It needs to be connected to the 18 pin header, RF3.

    The sample program sends no data to the UART. It simply toggles the LED on the receiving board. You will have to configure the UART and TX as a separate function. That would probably be done outside of the ISR, after it wakes from LPM3.

    char txBuffer[4]; is simply a buffer to hold the transfer data array. The array is commented and most of which comes from TI's cc2500 HAL.

  • i have connected it to 6 pin header near emulation. Wont it work there ? and i get msg that actual derivative is MSP430F2013 rather than chosen MSP430FR5739. This is because emulator is programming RF2500T. but it was toggling it some time before . when i connected one RF with battery and other with FRboard . But now it shows this msg about actual derivative.

  • No, it won't work there with this method. Those libraries as well as SimpliciTI are for directly using the SPI interface to the CC2500 radio.

    You are wanting to use the RF2500t as a wireless UART? For that, get http://software-dl.ti.com/msp430/msp430_public_sw/mcu/msp430/EKG-Based-Heart-Rate-Monitor/1_00_00_00/index_FDS.html it includes a wireless UART application to be installed on the RF2500t.

    I'm not sure if you can use the wireless UART and the usb back-channel UART at the same time.

  • still having some problems :)

    1. when i press SW1 of the board. Then only my code is going to the ISR of Port IV . no response from RF2500T board switches. Do i have to plug out the connector for RF_PWR ? or leave it like how is it? i think how it is connector on it shortens the two terminals maintaning Vcc at terminals of RW_PWR. but i want to double check it from you. and can you send me a snapshot of your hardware too ? and if i am correct i need to program both of the RF2500T from FRboard ? 

  • Here's a picture of the hardware. If you have the RF2500t mounted in this configuration and using the CC2500_FR5739 project, pressing SW1 should hit the P4 ISR and transmit the packet.

  • hello,

    but how to view those packets ? yes the program comes to interrupt when SW1 of FRboard is pressed. but no toggling of LED is observed. The other RF2500T is connected to battery pack for power. This board is connected to USB port of computer for power.I have programmed both of them with same program. What could be going wrong here ?

  • So, you're using the demo application that was in the cc2500_fr5739 for both devices? Did you reconfigure TI_CC_spi.c, TI_CC_msp430.h, and TI_CC_hardware_board.h to match the RF2500t hardware? The i/o is quite different.

    The LED will toggle on the receiving end, not the transmitter.

    To view the packets? Packet sniffer? Or add a __no_operation(); and place your breakpoint where you'd like to see that data.

  • Code is not entering the LED toggle part. So clearly receiver side is not configured properly. I tried programming the receiver side but couldnt . Can you tell a bit how to do it, like the main steps of it. I think that would be the only problem other than that everything looks fine to me.

  • The program will blindly transmit. It is not expecting an ACK from the receiver. The led will only toggle on the receiving end when it gets a packet. The transmitter should have no displayed activity.

    You will need to check out that whole SimpliciTI_CC2500 tutorial for better instructions. If you soldered the header at RF3 and installed the RF2500T as pictured above, all of this will work fine. Pick one of these following solutions.

    For wireless uart: (do this twice with same program)
    Solder 6 pin header at J4. Want to reprogram the RF2500t? Put the FR5739 board away for a few minutes. Use the ezUSB programmer for the RF2500t and install the wireless UART application (linked above) to use the RF2500t at J4. Then throw out all of that code you've gotten from the CC2500_FR5739 files as well as the code in that tutorial. None of that will help you on your way. You will need to then remove the TXD/RXD jumpers from J3. Write a program for the FR5739 to use the UART. The RF2500t will then transmit as a wireless UART. It won't know the difference of wired or wireless UART.

    OR

    For direct SPI CC2500 control:
    Solder 18 pin header at RF3. Reprogram the RF2500t by putting away the FR5739 and use the ezUSB. The program you will want for the RF2500t is the SimpliciTI_Toggle found in that same tutorial. Then you can decide to use SimpliciTI by following the instructions at the tutorial or you can use the CC2500_FR5739 application and libraries.

    Either way:
    I'm a dedicated CCS user so all of the instructions and code are for CCS. If you are using IAR, there will be some differences. You will need a different version of SimpliciTI and the code will need to be changed a bit for interrupts and variable declarations.

  • Hi there :) thanks alot for guidance . I took wireless uart application and programmed both RF2500t with it using ez430 stick. But i just copy pasted the code from that application, no addition done.
    Then i wrote this shown below routine for FRAM board and then programmed it. then i used it separately on COM11(FRAM board's serial port) the charecters were echoing, so the code is right. But when i put RF2500T on J3,
    and other RF2500T through ez430RF2500T connected to PC. I suppose now the charecters should echo on COM12(ez430's port). But it is not . Kindly tell where is the problem ?
    Thankyou very much for your support so far, i really am a beginner in wireless thing.
    
    
    #include "msp430fr5739.h"

    unsigned int i;
    unsigned char RXData = 0;
    unsigned char TXData = 0;
    unsigned char check = 0;
    void main(void)
    {
    WDTCTL = WDTPW + WDTHOLD; // stop watchdog


    CSCTL0_H = 0xA5;
    CSCTL1 |= DCOFSEL0 + DCOFSEL1; // Set max. DCO setting
    CSCTL2 = SELA_0 + SELS_3 + SELM_3; // set ACLK = XT1; MCLK = DCO
    CSCTL3 = DIVA_0 + DIVS_0 + DIVM_0; // set all dividers


    // Configure UART pins
    P2SEL1 |= BIT0 + BIT1;
    P2SEL0 &= ~(BIT0 + BIT1);
    UCA0CTL1 |= UCSWRST;
    UCA0CTL1 = UCSSEL_2; // Set SMCLK as UCLk
    UCA0BR0 = 52 ; // 9600 baud
    // 8000000/(9600*16) - INT(8000000/(9600*16))=0.083
    UCA0BR1 = 0;
    // UCBRFx = 1, UCBRSx = 0x49, UCOS16 = 1 (Refer User Guide)
    UCA0MCTLW = 0x4911 ;

    UCA0CTL1 &= ~UCSWRST; // release from reset
    UCA0IE |= UCRXIE; // Enable RX interrupt

    __bis_SR_register(LPM0_bits + GIE); // LPM3 + Enable interrupt
    }


    // Echo back RXed character, confirm TX buffer is ready first
    #pragma vector=USCI_A0_VECTOR
    __interrupt void USCI_A0_ISR(void)
    {
    switch(__even_in_range(UCA0IV,0x08))
    {
    case 0:break; // Vector 0 - no interrupt
    case 2: // Vector 2 - RXIFG
    while (!(UCA0IFG&UCTXIFG)); // USCI_A0 TX buffer ready?
    UCA0TXBUF = UCA0RXBUF; // TX -> RXed character
    break;
    case 4:break; // Vector 4 - TXIFG
    default: break;
    }
    }
  • Code looks like it should work fine.

    The RF2500t should be installed at J4 on the side of the FR5739 board. When you do that, you will need to remove the TXD and RXD jumpers from J3. That will allow the MSP430 to use the serial port through the RF2500t. With the jumpers in place, it still wants to use the ezFET UART.

    If there's time, I will test your program this evening. Installing siding on the house takes priority today.

    EDIT: removed DCOFSEL info, I was incorrect.

  • But if FRAM board is supplied Vcc through USB also and it also has application UART comm10 lets say on pc and the Ez430USB+RF2500t is also connected to another USB of the same computer and is on comm11 lets say. Wont it will be a problem then ? i think all the communication now should go through comm 11(wirelessly between connected USB RF2500t and J3 RF2500T.

    Another question is while programming FRAM board, connectors TX,RX on J4 , should they be thrown away or it doesnt matter if you put them off after compiling and before connecting RF2500t at J3.

  • actually i was pretty late on my project submission, i was hoping if you could give me some benchmark code for testing or something , if possible, because i have pretty much figured out the sensor part and i am still trying to get a proper way to log the data, but this RF part is totally new to me and i feel like i am getting nowhere with it. So lets see where does it takes me :)

  • Hi , i wrote this today, it samples internal temperature sensor of FRAM with timer and then transmits the data to UART, but i dont get the sent data on UART, it gives bogus values and in debugger i see right values been passed to UCA0TXBUF but no luck on hyperterminal, i have checked other serial port terminal too, so i guess there might be a problem with code, i will appreciate any help, i am sending you this because this is the data which i want to send through RF module too :) thnx :)

    #include "stdio.h"
    #include "string.h"

    #include "msp430fr5739.h"
    void sendstring(char * str);
    void configureUART(void);
    void TX_data(unsigned int value);
    volatile unsigned int IntDegC,IntDegF;
    void main(void)
    {
      WDTCTL = WDTPW+WDTHOLD;                   // Stop WDT
      P3DIR |= BIT7;                            // Set P1.0 to output direction
      P3OUT &= ~BIT7;                           // Clear P1.0
     
      //XT1 Setup   
     PJSEL0 |= BIT4 + BIT5;
     
      CSCTL0_H = 0xA5;
      CSCTL1 |= DCOFSEL0 + DCOFSEL1;             // Set max. DCO setting
      CSCTL2 = SELA_0 + SELS_3 + SELM_3;        // set ACLK = XT1; MCLK = DCO
      CSCTL3 = DIVA_0 + DIVS_5 + DIVM_5;        // set all dividers
     CSCTL4 |= XT1DRIVE_0;
     CSCTL4 &= ~XT1OFF;
     
     do
      {
        CSCTL5 &= ~XT1OFFG;
                                                // Clear XT1 fault flag
        SFRIFG1 &= ~OFIFG;
      }while (SFRIFG1&OFIFG);                   // Test oscillator fault flag
      // Configure ADC10
      configureUART();
      ADC10CTL0 |= ADC10ON + ADC10MSC;          // ADC10ON
      ADC10CTL1 |= ADC10SHS_1 + ADC10CONSEQ_2;  // rpt single ch; TA0.1 trig sample start
      ADC10CTL2 |= ADC10RES;                    // 10-bit conversion results
      ADC10MCTL0 |= ADC10INCH_10 + ADC10SREF_1;  // A10 ADC input select; Vref=1.5V

      // By default, REFMSTR=1 => REFCTL is used to configure the internal reference
      while(REFCTL0 & REFGENBUSY);              // If ref generator busy, WAIT                                          
      REFCTL0 |= REFVSEL_0+REFON;               // Select internal ref = 1.5V
                                                // Internal Reference ON   
      __delay_cycles(400);                      // ref delay  
      ADC10CTL0 |= ADC10ENC;                     // ADC10 Enable
      ADC10IE |= ADC10IE0;                       // Enable ADC conv complete interrupt
     
      // ADC conversion trigger signal - TimerA0.0 (32ms ON-period)
      TA0CCR0 = 1024-1;                          // PWM Period
      TA0CCR1 = 512-1;                           // TA0.1 ADC trigger
      TA0CCTL1 = OUTMOD_4;                       // TA0CCR0 toggle
      TA0CTL = TASSEL_1 + MC_1 + TACLR;          // ACLK, up mode

      __bis_SR_register(LPM0_bits + GIE);        // Enter LPM3 w/ interrupts

      __no_operation();
    }


    void configureUART(void)
    {
      // Configure UART pins
      P2SEL1 |= BIT0 + BIT1;
      P2SEL0 &= ~(BIT0 + BIT1);
      // Configure UART 0
      UCA0CTL1 |= UCSWRST;
      UCA0CTL1 = UCSSEL_1;                      // Set ACLK = 32768 as UCBRCLK
      UCA0BR0 = 3;                              // 9600 baud
      UCA0BR1 = 0;
      UCA0MCTLW |= 0x5300;                      // 32768/9600 - INT(32768/9600)=0.41
                                                // UCBRSx value = 0x53 (See UG)
      UCA0CTL1 &= ~UCSWRST;                     // release from reset
     sendstring("Temperature Logging\\n");
    }

     void sendstring(char * str)
     {
     int i = 0;
     for(i = 0; i < strlen(str); i++)
     {
     while (!(UCA0IFG&UCTXIFG));
     UCA0TXBUF = str[i];
     }
    }
    // Echo back RXed character, confirm TX buffer is ready first
    #pragma vector=USCI_A0_VECTOR
    __interrupt void USCI_A0_ISR(void)
    {
      switch(__even_in_range(UCA0IV,0x08))
      {
      case 0:break;                             // Vector 0 - no interrupt
      case 2:                                   // Vector 2 - RXIFG
        while (!(UCA0IFG&UCTXIFG));             // USCI_A0 TX buffer ready?
        UCA0TXBUF = UCA0RXBUF;                  // TX -> RXed character
        break;
      case 4:break;                             // Vector 4 - TXIFG
      default: break;  
      }
    }
    // ADC10 interrupt service routine
    #pragma vector=ADC10_VECTOR
    __interrupt void ADC10_ISR(void)
    {
      volatile unsigned int temp;
      switch(__even_in_range(ADC10IV,12))
      {
        case  0: break;                          // No interrupt
        case  2: break;                          // conversion result overflow
        case  4: break;                          // conversion time overflow
        case  6: break;                          // ADC10HI
        case  8: break;                          // ADC10LO
        case 10: break;                          // ADC10IN
        case 12:
         P3OUT ^= BIT7;
         temp = ADC10MEM0;
        IntDegF = ((temp - 630) * 761) / 1024;
        sendstring("\nCURRENT TEMP-->");
        // oC = ((A10/1024)*1500mV)-986mV)*1/3.55mV = A10*423/1024 - 278
        temp = ADC10MEM0;
        IntDegC = ((temp - 673) * 423) / 1024;
                 break;                          // Clear CPUOFF bit from 0(SR)                         
        default: break;
      }
     
    }

  • hi , i was finally able to send data through RF2500T through wireless UART, but the problem is that i send string of 8 characters but on hyperterminal it doesnt show exact 8 characters and then 8 characters, like i cant see the data size at which it is printing like

    22deg

    22

    22d

    22deg

    something like this .