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.

Using 2 UARTS in ARM CC2530

Other Parts Discussed in Thread: CC2538, CC2530, Z-STACK

Hello,

I used ZStack 2.5.1a for CC2530 and used 2 UART using the same stack. But now i am using ZStack- home and CC2538. How can i use 2 UARTS simultaneously. 

  • From CC2538 datasheet, it has only one UART port.

  • Yes i too noticed that, that's is the reason i  posted this question in this forum. Since top of the data sheet mentioned 2 UARTS. Then how we can use 2 UARTS.  And it mentioned that 2 SPI. But data sheet has only one SPI. You mean we can't use 2 UARTs, 2 SPI, 1 I2C all simultaneously.

    Regards

    Suman 

  • Hi Suman,

    After check the CC2538 user guide (http://www.ti.com/lit/ug/swru319c/swru319c.pdf), I find that it has 2 UART actually. From hal_uart.h of CC2538 Z-Stack, it shows "extern uint8 HalUARTOpen ( uint8 port, halUARTCfg_t *config );", which means that you can use different port number for different UART. I would suggest you to do some test on it.

  • In the Zstack home 1.2.0. "uint8 HalUARTOpen ( uint8 port, halUARTCfg_t *config );". I have noticed in hal_uart.c and hal_uart_isr.c, the variable "port" does not have any effect. what should i give in the port variable(In CC2530 i used HAL_UART_0 or 1). But i didn't see any thing on this.

  • In the Zstack home 1.2.0. "uint8 HalUARTOpen ( uint8 port, halUARTCfg_t *config );". I have noticed in hal_uart.c and hal_uart_isr.c, the variable "port" does not have any effect. what should i give in the port variable(In CC2530 i used HAL_UART_0 or 1). But i didn't see any thing on this

    Which default pin does Zstack home used for 2 UARTS. In ZStack 2.5.1a it use P0_6 as Rx pin in UART0 and P1_7 in UART1. What about Zstack home 1.2.0

  • Suman,

    You are right. After I dig into the source code, I see the same thing. I think TI doesn't support 2 UART in driver of Z-Stack yet. You can try to contact local TI representative to check if they can provide solution.

  • Thank you Mr.chen. So now any TI Employee can response to this post. How can i use 2 UARTS using Z-Home 1.2.0