No, I did not forget to add a label.
EXIT is a keyword used to break out of the current loop.
AI, simulation, virtualization.... What happened to the good old breadboard?
Do I really need to...
forget Proteus.
Also I think Henrik forgot to add the label Exit: just before the Serout command.
Ioannis
Thanks !
But nothing on serial ...(in Proteus 8)
What happens if more than one button is pressed at the same time?
Anyway, this might serve as starting point. It compiles but it is not tested.
Long_Press CON 5000
Short_Press con 100
cnt...
i possibly could be enough but you never reevaluate it until the whole timing mess has long completed
richard Yesterday, 10:49you have set timer1 to overflow every 16.38 mS , you never count the overflows
also adding 65535 to a word var seems very odd do you actually intend to subtract 1
i can't see how any of this...
No it just sets it to use external clock
9651
Thanks for reply !
T1CON = %00000110 ; this command does not start timer1?
Or do I have to use the command: T1CON.0 = 1 'start Timer1 ?
How to see if button is released ? IF DataW.... it's...
Qualifying Compiler |
Upgrade Description | |
Upgrade PICBASIC PRO (PBP) 2.60 or later to PBP3 Gold Edition | ||
|
||
|
||
Upgrade PICBASIC Compiler (PBC) to PBP3 Silver Edition |
Re: How to measure how long I pressed a button ?
It works ! Finally, the first program that shows me the duration. BUT .... the correct identification of the pressed button does not work ! I pressed ONLY button 0 : short or long ...It doesn't...
fratello Today, 10:53