2004-10-18 08:18 AM
2011-05-17 03:03 AM
Hello.
I tried to use the timer0 interrupt to call i2c xmit function. but it does not work properly. The i2c function works fine except in this way. my purpose is to xmit in a constant time interval. Is there a way, and not just for i2c, to have the timer0 ISR activate a large function (relavite to common ISR functions). thanx.2011-05-17 03:03 AM
std,
I am by no means familiar with the i2c interface on the uPSD series, but there is a fundamental concern with what you're doing. If you're actually CALLING a large function from the ISR for timer 0, you need to keep in mind that any other ISRs at the same priority level or lower will NOT execute until that function returns and you then return from the ISR. As such, if you're depending on some i2c interrupt to do the transmitting for you, you'll need to make it a higher priority than t0 or (ideally), just have the t0 isr set a flag and have a constantly running scheduler loop actually call the function from main code. Best Regards, pHaze426