Can't leave VLPS mode on TSI Touch Input.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Can't leave VLPS mode on TSI Touch Input.

1,551 Views
taimurwajad123
Contributor III

Hi All,
I'm working on Kinetis K10 'MK10DN64VLF5' and using TSS library. A system requirement is to enter VLPS mode if on touch is detected for specified period of time. After entering the VLPS mode, I'm not able to wakeup uC on touch input. When it enters in the VLPS mode, the TSI stops working and no interrupt occurs on TSI. Any hints or document I should study, or any other similar thread which can help.
PS: uC wakeup from VLPS on UART edge interrupt.

Any help will be highly appreciated

13 Replies

1,142 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi,

K10_50MHz TSI module normal interrupt (TSI0_GENCS[TSIIE]) related to two types of interrupt: End of Scan interrupt and Out of Range interrupt.

The Out of Range interrupt is only available in TSI low power mode.

The TSI mentioned low power mode only supports LLS, VLLSx, not includes the VLPS.

pastedImage_1.png

The Out of Range interrupt related threshold register only works for TSI low power mode

pastedImage_2.png

pastedImage_3.png

The Out of Range interrupt doesn't work at VLPS mode.

While, the End of Scan interrupt still work and can wake up the K10 from VLPS mode.

In general, the TSS library using TSI out of range interrupt to wake the chip from low power mode.

Thank you for the attention.

best regards,

Mike

0 Kudos

1,142 Views
taimurwajad123
Contributor III

Hi Mike,

Thanks for the explaination.

However, I'm still confused in the following points.

1- In reference manual, it is mentioned that GENCS[STPE] bit should be SET before entering (STOP, VLPS, LLS and VLLS{3,2,1})
mode.

STPE.png

And it is also mentioned that in STOP and VLPS modes, all the attached pins (electrodes) to TSI module are active.

2- I'm confused about your comment:

"In general, the TSS library using TSI out of range interrupt to wake the chip from low power mode."

Did you meant that, in order to wakeup K10 from VLPS mode, I must not use TSS library, or?

Can you please clarify me on this point.

Regards

Taimur

0 Kudos

1,142 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Taimur,

1> TSI module using interrupt to wake up the core from low power mode. There are two kinds of interrupt, as I mentioned above, the End of Scan interrupt still works at VLPS mode.
I had tested at TWR-K20D50M board. So, it need to use the End of Scan interrupt to wake up the core from VLPS mode. The STPE bit still need be set before enter into the low power mode (VLPS), when you using TSI end-of-scan interrupt to wake up the core.

2> There are two kinds of applications for TSI wake up the core from low power mode: One is when the key was pressed (using out of range interrupt), the other one is wake up the core periodically (using end of scan interrupt). My above comment does bring the confusion, sorry for that. When customer want to wake up the core from VLPS mode, it need to use TSI end of scan interrupt to wake up the core periodically. The TSS library using the first type application in low power wake-up demo, while customer can modify to use the second type application, when the core enter into VLPS low power mode. The TSS library can wake up the core from VLPS mode. Customer need to make sure the TSI0_GENCS[ESOR] bit is set before enter into the VLPS low power mode.

Wish it helps.

best regards,

Mike

1,142 Views
taimurwajad123
Contributor III

Hi Mike,

Thanks for your detailed explanation.

Unfortunately, still I'm not 100% clear. As you write, End of scan interrupt is used to wakeup the core periodically? my requirement is to wake up core on Touch input, by periodically u meant, periodic scan of touch, or?

Also, I have tried with End of Scan interrupt, without luck.
Can you please share the configurations for entering and leaving VLPS mode. And the clock configurations. I just wants to compare with configurations I'm using, maybe it will give me a hint about what I'm doing wrong.

I shall be thankful to you for this.

Kind Regards

Taimur

0 Kudos

1,142 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Taimur,

Sorry for the delay reply.

I check the <Touch Sensing Software User Guide Rev.6> at TSS library folder.

The chapter 5.5 Low power feature indicate the typical use of low power function, you could check page67 of <TSSUG.pdf> for the detailed info.

The typical application will use [Out of range] interrupt to wake up the chip.

Please check my test code to use [End-of-Scan] interrupt to wake up the K20 from VLPS mode.

The test code will break the TSS software architecture, which just shows the TSI module could wake up the K20 from VLPS mode.

If customer want to period wake up the K20 from VLPS mode, I would recommend customer to use a timer, such as LPTMR. Using a timer to wake up the K20 chip will not break the TSS software architecture.

Thank you for the attention.

best regards,

Mike

1,142 Views
taimurwajad123
Contributor III

Hi Mike,

Thanks for your reply and test code. Unforntunately, still I'm not able to wake K10 from VLPS mode with TSI input, using any of interrupt. I also configured entry in VLPS mode and TSS according to your test code.

In my case I'm using FEI to BLPI transion and vice versa.

I'm able to wake up K20 from LLS mode with TSI, however, in that case only one electrode is active, which doesn't meet my system requirements.

Also, did you able to wake up K20 with touch input from VLPS mode?

Best Regards

Taimur

0 Kudos

1,142 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Taimur,

My test code is wake up the K20_50MHz chip from VLPS mode with TWR-K20D50M board.

That test code should works with TWR-K20D50M board.


Have a great day,
Mike

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

1,142 Views
taimurwajad123
Contributor III

Hi Mike,
Unfortunately I'm still stuck in this problem. The current requirement was fullfilled with VLPR mode, but it turns out that when UART module is used, the current consumption in VLPR increases drastically. So again I'm assigned to configure the uc in VLPS mode. I have tried literally everything.
Can you please guide me what should I do next?

Any help will be highly appreciated.
Regards
Taimur

0 Kudos

1,142 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Taimur,

My colleague had created a demo based on TWR-K20D50M to use UART wake up chip from VLPS mode.

Please check his comments below:

You can refer the low_power_demo example in KINETIS_50MHZ_SC. It will show you how to configure MCU in VLPS mode (without using PE).If you want to use UART to wake up the MCU, you just need to enable the RxD Input Active Edge Interrupt(UART1_BDH[RXEDGIE]=1) and clear RxD Pin Active Edge Interrupt Flag(UART1_S2[RXEDGIF]) in the uart1_status_isr.

I would recommend to create a service request at NXP online support system, then my colleague will send that software project to you directly.

Please refer below document about how to create a service request:

https://community.nxp.com/message/597118?commentID=597118#comment-597118 

Thank you for the attention.

best regards,

Mike

1,142 Views
taimurwajad123
Contributor III

Hi Mike,
I'm actually able to wakeup uc with UART Rx edge interrupt. The problem is with TSI using TSS library.

I configured my system for LLS mode, and I'm able to wakeup with touch input, however the problemm is only one elctrode is active in LLS mode.

My requirement is that all TSI electrodes should be active in Low Power Mode. That's why I must configure the system to enetr and leave VLPS with touch input.

Best Regards

Taimur

0 Kudos

1,142 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Taimur,

I will be out of office next week, I couldn't check this issue next week.

If you have an urgent issue, I would recommend to create a new thread about the issue.

My colleague will provide the support.

Otherwise, I will check this issue when I back to office (Feb. 5th).

Thank you for the understanding.

best regards,

Mike

0 Kudos

1,142 Views
taimurwajad123
Contributor III

Hi Mike,
Thanks for the reply. I have created a service request, I hope i will get some solution regarding this issue.

Can you please send link to the

"low_power_demo example in KINETIS_50MHZ_SC".

Best Regards

Taimur Wajad

0 Kudos

1,142 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Taimur,

Please download Kinetis 50MHz bare metal sample code(REV 1.6) from here.

You will find the [low_power_demo] example with default path:

..\kinetis_50MHz_sc\k20d50m_sc_baremetal\build\iar\low_power_demo

Wish it helps.

best regards,

Mike