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.

How to get the data from the serial port ?

Other Parts Discussed in Thread: RF430FRL152H, TRF7970A

Hi All,

I am using TRF7970AEVM and RF430RFL152HEVM. I want to get to data (actually the voltages on the sensors) transferred from the sensors on the RF430RFL152HEVM. And I am trying to get the them from the serial port of PC. Does anyone know how to do that? 

Actually, I am using Serial Port Utility to talk with TRF7970AEVM. I want to know what are the commands to send to get the data (voltage)?

Thanks!

  • Please refer to this E2E thread: http://e2e.ti.com/support/wireless_connectivity/nfc_rfid/f/667/p/427665/1755155#1755155

    I have attached to that thread a document called: Sampling Command Sequences.txt which describes which commands can be sent over the serial port to read the conversion result.

    I also would like to mention that the RF430FRL152H ROM stores the conversion result straight from the SD14 ADC.  It does not convert it to voltages.  The reciever needs to convert it to a voltage later through a formula.

  • Hi Alex,

    Thanks for your help. I tried the methods in the document you attached. I almost understand how to solve the problem. But a new problem occurred to me. When I tried to write the commands to block 0, it responded [0112]. From the ISO15693 Host Commands, it means the block is locked??!! Do you have any ideas to deal with the problem?

    Thanks

    Jing

  • You have to reprogram the RF430FRL152H with one of the example projects provided.  This will clear the lock blocks.

    The example projects can be found on http://www.ti.com/product/rf430frl152h  

    Direct link: http://www.ti.com/lit/zip/slac691

  • Thanks Alex,

    I have reprogrammed the RF439FRL152HEVM and I can get some sensor from TRF7970A_EVM_GUI by sending it some commands. However, I can only get the data that by sending two or three commands to TRF7970A_EVM_GUI. So I want to use other software to send these commands  and receive the response from it automatically. But I tried using Serial Port Utility and python to do that and it never works no matter by sending the codes like "18022009" or "010B000304180220090000". Do you have any idea what's going on of it?

    Thanks again

    Jing Xu

  • First the TRF7970AEVM firmware only accepts full packet data such as: "010B000304180220090000" but not "18022009".

     For help on the ISO15693 host commands, please reference this document:

    http://www.ti.com/lit/an/sloa141/sloa141.pdf

    I suspect that your initial connection is not successful.  

    I would recommend to trace the UART sequence of the TRF7970AEVM connecting using the GUI and try to reproduce the same sequence with your system. 

  • Thanks for your reply.
    So you mean I must use the full packet data such as : "010B000304180220090000" no matter what software I am using.

    But I think my connection is right. Because I first use USB to connect TRF7970AEVM and read the data by sending "010B000304180220090000" or "18022009" through TRF7970AEVM GUI. And it works well. But I did nothing except changing the software into Serial Port Utility and sent the same commands, but I cannot get anything and it even didn't response no matter by sending "010B000304180220090000" or "18022009". So I think it's not the problem of connection.
    So I have be confusing even by now.
    What do you think the problem is?
    Thanks

    Jing
  • If you notice on the console below, when you send the "18022009" command, the GUI converts it to a full packet: "010B000304180220090000"

    Make sure that you are connecting to the TRF7970AEVM with the correct COM port and also the correct baud rate of 115200.

    I would recommend to first exchange some packets with the working GUI (like a read single block), then close it. Open your Serial Port Utility with the correct configuration and try to send "010B000304180220090000" across. You should get a response.
  • Hi Alex,

    Thanks for your reply. I found the mistake. It's the Baudrate. When I set to 115200, I can receive the ID of the tag directly without sending anything. But when I tried to send "010B000304180220090000", I got nothing and there is no response. I wonder maybe there is some other configuration wrong. The settings are as follows:

    Port: COM1

    Baudrate: 115200

    Data bits:8

    Parity: none

    Stop Bits: 1

    Flow Type: none

    Do you think they are right or not?

    Thanks

    Jing Xu

  • looks correct - COM port settings should be 115200 bps, 8 data bits, no parity, and 1 stop bit (115200 8N1)
    if you are in the test tab, if you send full string, you need to use 'SEND RAW' button. if you want the GUI to add the extra bytes for you, use 'SEND' button.
  • Thanks Josh,
    The configurations are all correct. And I mean if I send "010B000304180220090000" using 'SEND RAW' button in the test tab, I can get some data. But if I use the same configurations in Serial Port Utility, and send "010B000304180220090000", I can get nothing.
    I am confusing. Do you know what's happening?
    Thanks
    Jing Xu
  • most likely its ASCII versus HEX you are running into if sending via another program

    or you need to set up the device with other commands like set protocol, etc. first.

    for example: 

    in ASCII: 

    versus same thing in HEX

  • Thanks Josh,
    I am using the program Docklight and did as what you said, and now it is working well. It solved my problem.
    Thanks you so much!

    Sincerely,
    Jing Xu