Reduce it!!! Let's say ~1-10K pull-up.
AND, wait a few Usec after you detect the falling edge...
Reduce it!!! Let's say ~1-10K pull-up.
AND, wait a few Usec after you detect the falling edge...
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Wiat let me correct that... I just looked at the schematic, there is not a pull up on PortA.5. Sorry about that, I did not do the hardware, I am just doing the programming.
I have a 3uS pause after the falling edge (was 1uS, but Alain correct me on that already)
Thanks for all your help so far guys...
I am still learning this digital stuff, and have been slowly making my way up the hill.
A floating input would for sure screw-the-pooch since it returns a random value when
the port pin is read...;o}
Looking at the first post,
I think this could be the issue here.
Code:X var PORTA.5 Y var PORTF.6 REPEAT UNTIL x = 0 ' X = 1 ; wait until it is 0. High y ' Here, X = 0. while x = 0 : wend ' Here, X = 0, wait until it is 1. REPEAT UNTIL x = 0 ' X = 1 ; wait until it is 0. Pauseus 1 Location1=PortJ while x = 0 : wend ' Here, X = 0, wait until it is 1. REPEAT UNTIL x = 0 ' X = 1 ; wait until it is 0. pauseus 1 CharLow=PortJ while x = 0 : wend ' Here, X = 0, wait until it is 1. REPEAT UNTIL x = 0 pauseus 1 CharHigh=PortJ while x = 0 : wend ' Here, X = 0, wait until it is 1.
------------
"If the Earth were a single state, Istanbul would be its capital." Napoleon Bonaparte
If these changes made no difference, then you have an issue with your inputs.
_______________-
"If the Earth were a single state, Istanbul would be its capital." Napoleon Bonaparte
Bookmarks