|Anonymous | Login | Signup for a new account||2017-04-23 15:43 UTC|
|Main | My View | View Issues | Roadmap | Repositories|
|View Issue Details|
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0000293||Firmware||Decoders||public||2011-10-10 11:09||2011-10-10 14:17|
|Target Version||Future||Fixed in Version|
|Summary||0000293: For 2 Edge Decoders Check Consistency Of Observed Pin State|
|Description||IE, make sure that each alternate interrupt is an alternate interrupt. I realised last night that it is possible that a noise pulse could trigger the interrupt to occur and go away again before the ISR samples the pin state to determine rising/falling edge. Then I realised that if we keep a history of this, we can check to ensure that our edge is correct.|
For single edge decoders a similar thing can be done in terms of ensuring that it is always the same and correct. If not, it's noise, lose sync with a specific error.
Preferably add these as part of the decoder interface common code base.
|Tags||No tags attached.|
|Risk of Breakage||low|
Another way to do this would be to check for the interrupt flag telling us that we're about to run again and clear it, and lose sync, right there and then.
This way would also protect from excess RPM, and give something in the log saying "interrupt arrived before we were done = noise or too high RPM for current code efficiency and pattern in use" - I like this solution.
|Copyright © 2000 - 2011 MantisBT Group|