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.

Compiler/CC3200: Send Hex to PC

Part Number: CC3200

Tool/software: TI C/C++ Compiler

Hi,

Can anyone please tell me that how to send hex value from my CC3200Mod to my pc and receive it in the serial terminal if anybody knows please tell me about that or if you have source code you can share with me.

Thanks in advance

  • Hi,

    From your question is not clear what you need to. Please specify your question better.

    Following examples from CC3200 SDK you to be useful for you:
    - udp_socket
    - tcp_socket
    - serial_wifi
    - http_client_demo

    Jan
  • I have said that one Uart demo code is there if we type anything in terminal it will be echoed as string and it is taking the input as string but I wanted to take the input as Hex in Uart Demo code. Is that possible if yes then how?? Please reply me.
  • Hi,

    Sorry I don't understand. Can you insert here what you expecting as input and output? I means format of the input and output data.

    Jan
  •  \\

    //

    I just wanted to ask how to give input as hex . That's it in CC3200 Uart demo application. I just need to give input as hex that's my task.See this image you get to know i want to give input as hex but this program is designed for taking input as string how can I change that.

  • Hi,

    I not understand what you need to do. Hexadecimal is a numeral system how to represent data. In this example is input from UART read by UartGetChar() byte-to-byte and end of string (input) is determined by characters \r or \n.

    - You want to insert data as BCD representation encoded in in string? E.g. input string "52 86 7D" and convert it into '4', 'V', '}'?
    or
    - You need read any character by UART and send this characters back? In case of that you need save characters into some array, how do you want determine end of the data?

    Jan
  • hi
    I need to give input like this E.g. input string "52 86 7D" but not in string format but in Hexadecimal format . Is this possible or not???
  • Hi,

    OK, understand.

    You can use uart_demo example from SDK as is but you need add routine for conversion to HEX. This routine you need to add around line Report("\n\rcmd#%s\n\rcmd#", cString); in example.

    A few examples how this routine could looks

    Jan

  • Thanks for your reply, one last question can we enable Uart0 and Uart1 at the same time in CC3200 if yes then how??
  • Hi,

    Yes, it is possible. You need:

    - enable UART in pinmux file (enable UART1 peripheral by MAP_PRCMPeripheralClkEnable() and set pins at pinmux for UART)
    - create functions UartGetChar() and UartPutChar() for UART1, e.g.:

    #define UartGetChar1() MAP_UARTCharGet(UARTA1_BASE)
    #define UartPutChar1(c) MAP_UARTCharPut(UARTA1_BASE,c)

    Jan