Membrane switch control
Blackbird455
Posts: 124
I am trying to find the best way to use momentary membrane switches to control a BS1.......
· Since you cannot interrupt a BS1(right?) , the push of the switch will not have any effect, until the end of a string of commands.
When I used a momentary switch on a BS2, I would have functions running out of an I/O, for about 900ms, and I would have to hold the switch for about a second until it would respond differently.
·My question is.........using two seperate BS1's........
· If I had BS1 #1 setup to "
IF ( in0 = 1 ) THEN
DO
high 15······ ' 15 would go to BS1 #2 and pull it high until it had time to cycle and respond
pause 2000
low 15
loop until···· ' whatever else I want it to do.........and so on......
Would this be the best way...........or am i missing something?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
ETERNAL NOOB, you could learn alot from a dummy.......
"one should not profess ones ignorance, one should just read more books"
······························································ ......unknown
· Since you cannot interrupt a BS1(right?) , the push of the switch will not have any effect, until the end of a string of commands.
When I used a momentary switch on a BS2, I would have functions running out of an I/O, for about 900ms, and I would have to hold the switch for about a second until it would respond differently.
·My question is.........using two seperate BS1's........
· If I had BS1 #1 setup to "
IF ( in0 = 1 ) THEN
DO
high 15······ ' 15 would go to BS1 #2 and pull it high until it had time to cycle and respond
pause 2000
low 15
loop until···· ' whatever else I want it to do.........and so on......
Would this be the best way...........or am i missing something?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
ETERNAL NOOB, you could learn alot from a dummy.......
"one should not profess ones ignorance, one should just read more books"
······························································ ......unknown
Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
http://www.tranzistoare.ro/datasheets/320/85522_DS.pdf
Connect your switch so that it triggers the S (Set) In your program you just check the output as you normally would as if it were a button or switch directly connected to the pin, but immediately after you check it, send a signal to the R (Reset) pin to reset the IC.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Beau Schwabe
IC Layout Engineer
Parallax, Inc.
By making the RESET pin an OUTPUT and LOW you reset the latch state.
By making the RESET pin an INPUT you allow the switch to control the latch state.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Beau Schwabe
IC Layout Engineer
Parallax, Inc.
After researching your info, and weighing my options, I think that I will use two BS1's so that I have more available I/O's on BS#2.
Plus......that means that I'll be buying more Stamps [noparse]:)[/noparse]
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
ETERNAL NOOB, you could learn alot from a dummy.......
"one should not profess ones ignorance, one should just read more books"
······························································ ......unknown