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.

Interfacing eZ430-RF2500 with external sensor using UART

Other Parts Discussed in Thread: CC2500, MSP430F2274

Hi all

I am also working on a similar problem , I want to interface MSP430 with a sensor to get data via UART . I am using ez430-RF2500 development kit .

a)       Can I use the board pins (1,6) as Rx and Tx for UART communication with my sensor ?? If so ,I guess I will be able to use USB powering of MSP any more ? am i right ?

            So I am guessing to power MSP using 2,5 of board pins (all these pins are given as additional development pins in user guide for ez430-rf2500 ) ??

 

b)         If so ,Should I use a JTAG to dump code on to my MSP of ez430-rf2500 ,If I plan to use the UART pins to external sensor interfacing ??

 

Can some body help me plzzz

 

sorry for inconvenience ...I am new to this board and nearing my deadlines .....

  • volatile_solid : I split this post into its own thread.  Although the thread  you attached to was associated with the UART, I believe it is a separate discussion.

    I think it is important to get a better idea of what you are attempting to do.

    First, are you planning to use the CC2500 radio on the board?

    Does your sensor actually support a UART interface, or something like a SPI interface?

     

    I will address your questions below, but it would be good to get the higher level questions above taken care of.

    volatile_solid said:

    I am also working on a similar problem , I want to interface MSP430 with a sensor to get data via UART . I am using ez430-RF2500 development kit .

    a)       Can I use the board pins (1,6) as Rx and Tx for UART communication with my sensor?? If so ,I guess I will be able to use USB powering of MSP any more ? am i right ?

                So I am guessing to power MSP using 2,5 of board pins (all these pins are given as additional development pins in user guide for ez430-rf2500 ) ??

    This is confusing.  I think there are several things trying to be conveyed here and we should separate them out.

    First, can you use the H1 connector pins 1 (RX) and 6 (TX) for UART communication to your sensor?  Yes, you can.  However, you will need to determine how you are going to make the hardware connections.

    Second, powering of the RF2500 radio target board.  This is the board that has the MSP430F2274 and CC2500 on it (ie. not the one with the USB type A connector).  If you are removing the RF2500 radio target board from the emulator stick (the USB connector one), then you will need to supply power to the board by connecting H1.pin2 to 3.3V and H1.pin5 to ground.

     

    volatile_solid said:

    b)         If so ,Should I use a JTAG to dump code on to my MSP of ez430-rf2500 ,If I plan to use the UART pins to external sensor interfacing ??

    Yes, you will need to use the USB emulator stick to program the MSP430F2274 on the RF2500 radio target board.

     

  • Thanks a lot Brandon ,

     

    Ya Actually sorry for not being clear about my questions .

     

    Yes, The sensor with which I am interfacing has UART pins (Rx,Tx ) . The problem is like this , I will be sending a specific byte sequence to sensor  in order to get a replyI  back  (again a byte seq)  from sensor .

    Ya,I will be using CC2500 for RF transmission of the same data that  brought into MSP from sensor using UART .

    So what I am planning to do is , connect the pins (1,6) correspondingly to sensor Rx and Tx and (2,5 ) to an external voltage supply .

    So now comes the problem of dumping code on to MSP . Can I connect once to computer using USB stick provided  and dump the code using CCE , and disconnect it ,and then  on I will be using (1,6) as Rx and Tx ,and MSP will be powered externally by (2,5 )

     

    will this work ?

    Actually ,  now I am encountering one more  basic problem , If I try to execute the example UART codes for MSP430F2274 i.e. especially the echoing ones uses the hyper terminal rite ? I configured it to 9600-8n1 and still I am not getting the echo on to hyperterminal . I am thinking the Rx interrput is the problem in the code. This is the code provided under code examples for F2274 . Am I missing some thing ? ( All this I am  doing using the  USB stick  and CCEv3  this has nothing to do with my sensor interfacing with my sensor )

     

    thanks in advance

  • volatile_solid said:

    Yes, The sensor with which I am interfacing has UART pins (Rx,Tx ) . The problem is like this , I will be sending a specific byte sequence to sensor  in order to get a replyI  back  (again a byte seq)  from sensor .

    Ya,I will be using CC2500 for RF transmission of the same data that  brought into MSP from sensor using UART .

    So what I am planning to do is , connect the pins (1,6) correspondingly to sensor Rx and Tx and (2,5 ) to an external voltage supply .

    So now comes the problem of dumping code on to MSP . Can I connect once to computer using USB stick provided  and dump the code using CCE , and disconnect it ,and then  on I will be using (1,6) as Rx and Tx ,and MSP will be powered externally by (2,5 )

     

    will this work ?

    Yes, this will work.  I suggest that you try to use a mating connector to the RF2500 radio target board so that you can easily disconnect from your application board and put the RF2500 radio target board on the USB emulator stick for reprogramming more easily.  If you connect directly to the pins of the connector by soldering wires, then you will have a harder time doing this.

     

    volatile_solid said:

    Actually ,  now I am encountering one more  basic problem , If I try to execute the example UART codes for MSP430F2274 i.e. especially the echoing ones uses the hyper terminal rite ? I configured it to 9600-8n1 and still I am not getting the echo on to hyperterminal . I am thinking the Rx interrput is the problem in the code. This is the code provided under code examples for F2274 . Am I missing some thing ? ( All this I am  doing using the  USB stick  and CCEv3  this has nothing to do with my sensor interfacing with my sensor )

    Which code example are you using?  I assume it is from the SLAC123 archive, but which file?  You should use the msp430x22x4_uscia0_uart_01_9600.c file.  You will see in the comments section at the beginning of the file that this particular example does not require a 32KHz crystal to be used on the XIN/XOUT pair, unlike the other examples.  This one is required because the eZ430-RF2500 radio target board does not have a 32KHz crystal on the XIN/XOUT pair as indicated by the eZ430-RF2500 schematics found in the eZ430RF2500 Development Tool User's Guide (SLAU227) found on either the MSP430F2275 Product Folder or the eZ430-RF2500 Product Folder.

    I have verified the aforementioned example file and it operates correctly on the eZ430-RF2500.

    For your development, I would encourage you to download the MSP430F2274 datasheet and MSP430x2xx Family User's Guide (SLAU144) for your reference as this will have important information regarding the use of peripherals, etc.  The code examples are a good resource, but they really provide a specific application of ideas found in the Family User's Guide.

  • Once again highly thankful for your patience .

    I made a connector to connect to target board for providing power .Thanks for the advice ..

     

    I am also able to run that code ,Earlier I chose a wrong example which was using 32Khz Xtal .

    My sensor uses  MODBUS communication protocol for UART ,I am guessing that wont be a problem to interface with MSP430 .Am I right ?

     

     

    This is really helpful .

     

     

    Regards,

    Rajendra

     

  • volatile_solid said:

    My sensor uses  MODBUS communication protocol for UART ,I am guessing that wont be a problem to interface with MSP430 .Am I right ?

    Did you happen to perform a Google search on MODBUS?  I eventually reached the following location with a port to the MSP430.

    http://freemodbus.berlios.de/index.php?idx=36

    Based on this, I would say, yes.

  • Ya I googled a bit of it .

    But main concern is all the details regarding MODBUS on the sensor we have ,i.e we know the  hex byte sequence to be sent to sensor from MSP to get the sensor reading for example .

    So  as  I know the sequence already ,Do I still have to implement MODBUS protocol sw on MSP or can I just pump in the byte sequence through  UART and get replies from sensor ?

     

    Thanks a ton

     

     

    Rajendra

     

     

  • I don't see anything standing in your way of accomplishing this if  you already know what to send to the sensor and the expected format of the response.

**Attention** This is a public forum