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.

CC2430 UART interrupt when running in PM2

Other Parts Discussed in Thread: CC2430

Hej!

I am building my project based on CC2430 running Z-satck 1.4.3 inside. It communicates with sensor by UART periodicly. The application template is SerailApp.c.

Now I low the power mode to PM2 and keep sending uart message by timer interrupt. But what happens now is that only message sent out can be tested by oscillograph, the return sensor value can not be received. Or can I say that the uart interrupt is blocked?? Anyway, RX event handling function is never called.

Since the module I use is of version E, while DMA setting in board configuration file of DB is  according to Version D, I change DMA on USART2 and define HAL_UART_ISR to TRUE as below:

#if HAL_DMA
    #if !defined( HAL_UART_DMA )

          #define HAL_UART_DMA  2    

     #endif
#else
    #undef  HAL_UART_DMA
    #define HAL_UART_DMA 0
  #endif

#if !defined( HAL_UART_ISR )
    #define HAL_UART_ISR     TRUE  
#endif

I am not sure whether it is set correctly or what else I need to do??????

Please help me!

Thanks!

  • Based on my reading of the CC2430 Datasheet (SWRS036) found at the Product Folder http://focus.ti.com/docs/prod/folders/print/cc2430.html, the Power Management mode PM2 implies the following:

    • Power on reset, external interrupts, 32.768KHz oscillator and sleep timer peripherals  are active.
    • IO pins retain the I/O mode and output value set before entering PM2
    • All other internal circuits are powered down.

    This suggests to me that UART will not be active to receive the sensor data.

    Are you able to place the device in PM1 and get the functionality you desire?

  • Hello!

    Thanks for your suggestion!

    To low down the power consumption, the chip in my system needs to run in low power mode as long as possible.

    Do you think the chip can be waken up by UART signal or it can store the UART signal in its register and read it in when chip is polling the UART port?

    Thanks!

     

  • Hi,

    In the case where you want to be waken up externally. I think that you must set your input pin as General Input/Output and

    not as Uart. The interrupt generated on RX_UART won't work when you sleep. I don't know how many times after, your sensor send its response.

    But maybe you should wait by Timeout the response before going in Sleep.

     

    Launix,

  • Prior to my original post, I had considered suggesting configuring the RX input pin as a General Purpose Input which could be used to wake up the device upon a high-to-low transition.

    However, I am concerned about suggesting that implementation because I do not have data to substantiate the wake up time of the device during that period.  Essentially, the high-to-low transition is the beginning of the START bit of a UART transmission.
    I don't think the device will be able to wakeup, take the interrupt, service it and enable the UART in time for it to see the START bit.

     

    The question to xielili is understanding if the sensor is really sending data asynchronously to the CC2430, or does it only send data to the CC2430 as a response to a command transmission (TX) from the CC2430.

  • Hello!

    Taking your advice, I set some parameter to keep CC2430 awake after sending out the sensor request (every 10 secends), until receiving the reply from sensor and sending out by OTA signal.

    From debug window I can see that it runs into the function halSleep() and HAL_SLEEP_SET_POWER_MODE(halPwrMgtMode). I think system is powered down when it is idle.

    But as testing results of current consumption by Oscilloscope, it is 5mA at idle state, tens of thousands times of 0.5uA expected in datasheet.

    I doubt maybe my system is running with 16MHz RC OSC on, but i dont know how to check it. Or maybe some other probelm i have not found! Please give me some suggestion what else I could think about!

    Thanks you all!

     

  • Hi,

    5 mA don't look to be Power_Mode of CC2430. What kind of hardware board are you using? Ti board or your own?

    Do you estimate the consumption of your sensor?

     

    Launix.

  • I am using a small module from a third company (I am not sure whether it is ok to say the company's name), which includes CC2430 and antenna, no user interface.

    Actually, the module is powered from two pins on sensor, does my result includes the consumption of sensor?

     

  • If you introduce your current measurment just behind your Power entry (behind battery or behind supply source ...) you will include your sensor

    consumption. If it is just before CC2430, you won't maybe not include the rest of your board.

    Launix.

  • Yes it is only on the entry of module, and i think only power consumption by module is shown. It seems that the MCU is still working in full power, only RF part is off. What is the reason leading to it?

  • Yes, if you use a 16 Mhz RC OSC it can be the CPU active mode level consumption. What is your POLL_RATE for your end_device?

  • POLL_RATE is 0. I did not mean to use 16MHz RC OSC, and dont know how to set it at low power with all high frequency oscillate off. But the truth is it can not power down with some reason!

  • xielili: What is your status with this issue?
    Have you determined the source of the current consumption?
    Are you getting the CC2430 into a low power state?