Timer vs USB_UART?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Does anyone have any idea why a 16 bit fixed function timer, that interrupts about every 4s,  would interfere with USB_UART operation?  

   

I'm debugging my current boards  (with a CY8C5667LTI-LP041) ,  which show up on Device Manager on an appropriate COM port, but will not connect to putty (and yes, I've double checked my serial settings) .

   

I've turned everything in code off one-by-one until USB_UART is permanently on.  

   

With the Timer_Start(),  the USB will not connect, but if I comment that out, USB will connect to putty again.

   

The odd thing is that I have another timer, a 32B UDB timer, that does not interfere with the USB_UART at all.

   

Both timers are software enabled, have dynamic periods based on software, and cause external interrupts. 

   

 

   

Any advice would be appreciated.

   

Thank you

0 Likes
3 Replies
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

I've never seen something similar.

   

How is the connection from Rx/Tx to your PC made? Level shifter?

   

Is it possible for you to post your complete project, so that we all can have a look at all of your settings? To do so, use
Creator->File->Create Workspace Bundle (minimal)
and attach the resulting file.

   

 

   

Bob

0 Likes
Anonymous
Not applicable

Further investigation shows it is the 25ms worth of blocking adc/eeprom action right after the Timer Interrupt that breaks the UART communication.
Also, my exampe USB_UART code was written polling, so mine is polling instead of interrupt driven.
I'll need to investigate changing that.
 

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

I am not quite sure, but I remember that during eeprom write clocks are changed.

   

25ms in an interrupt handler is a very long time

   

 

   

Bob

0 Likes