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.

CC2650 Sensor Tag

Hi All,

Can somebody explain it for me  why Ti not manage their movement service by using Task like other sensors in their main startup file. But instead using process interrupt callback and wake on movement feature? Is it because they want to get the movement data faster than other and saving the energy for the sensor tag?

I am using Sensor tag with BLE stack ble_cc26xx_2_01_01_44627

Thank you for your consideration!

  • Hi

    What do you mean by "movement service"?
    Are you talking about the difference between a blocking vs callback based drivers?

    Todd
  • Maybe sir, recently i working with this sensor tag. Inside the project, according to what i'm reading. The "movement service" from PROFILE folder and "SensorTag_Mov", which is related to MPU9250. seems not the same with other sensor. Other sensor (like Temp, Hum, Bar) be handled with task from ti RTOS and their task can be create in the "main.c", but not Movement. And in "SensorTag_Mov" i can see they have process interupt, and register callback. So i wonder why? Does it because TI want to have Movement service be a wake on service? Or it because Movement Data so fast , they have to catch it on the register and using interupt to read them?
    Thank you for your consideration sir Tood,
  • Chi,

    The MPU9250 detects physical motion of the device. In other words, when you pick it up, shake it, or turn it sideways. When the device is stationary (i.e. not moving), no data is generated. It would be wasteful of power and CPU cycles to use a task to continuously check the MPU9250 for new data. Therefore, we use the interrupt mechanism. This way, the CPU is only collecting data from the MPU9250 when there is new data. In other words, when you move the device, the MPU9250 generates an interrupt to the CPU which then schedules a task to collect the data. This happens quickly and only when needed.

    Other sensors, like Temperature, Humidity, Pressure, will take a measurement only when asked. In other words, they don't constantly check, only when asked to do so. We use a task to wake up every few seconds and then read the sensor data.

    One small detail. Some sensors, like the Temperature sensor, could in fact be configured to constantly measure temperature and then generate an interrupt if the temperature goes too high or too low. In this case, we would also use the interrupt mechanism.

    ~Ramsey

  • Dear sir Ramsey,
    Thank you for your consideration. I see there are thresholds that help MPU 9250 wake up and back on service. So doesn't it mean there will be a CPU cycle to check MPU data periodly? How can sensor tag detect it on stationary state?
  • Chi,

    I don't really understand your question. But when the MPU9250 raises an interrupt, the CPU will run and use cycles to read the data from the sensor. When the device is stationary, there will not be any interrupt. The last data you acquired from the sensor will still be valid. Nothing has changed.

    If you want, you can still use a task which runs periodically to read the sensor data. However, if you are using a DCM matrix to compute the up vector, you will get very poor results if you read the sensor only occasionally. To compute an accurate DCM, you should sample the sensor frequently when it is moving (around every millisecond). But doing this all the time would waste a lot of power when the device is stationary.

    ~Ramsey

  • There was a suggested answer and since there has been no active on this thread for more than a week, the suggested answer was marked as verify. Please feel free to select the "Reject Answer" button and reply with more details.