Ioannis,
Just in case you're still thinking, It can't be that (Post #89) because this works ...
Code:
while portb.0=1
wend
high led1
If you look at the PORTB.0 diagram. You can see that it uses a TTL input buffer when reading PORTB as digital inputs. So, the High and Low voltage levels are 2.0V and 0.8V.
With the circuit on the PICDEM2+ you'll get around 2.25V with the switch open (depending on the forward voltage of the LED). So it works fine with the digital Inputs.
<img src=http://www.picbasic.co.uk/forum/attachment.php?attachmentid=1800&stc=1&d=118290623 7>
But the signal for the INT interrupt, goes thru a Schmitt Trigger. And it's levels are .8VDD (4V) High, and .2VDD(1V)Low.
The circuits on PORTB.0 of the PICDEM2+ don't produce enough voltage to trigger the interrupt. (when the LED's are engaged)
HTH
Bookmarks