Arrange the leds in a circle and turn them all on. make a disk mask with a hole in it. Bicycle brake cable to the foot switch operates a cog-wheel much like the balance wheel in a watch... you remember windup watches don't you??... Foot switch lets disk rotate to the next position. Remove the cog for the ones you want to skip. Glue a PIC on the disk so you can say it has one. Write "pragma" on the disk too. I always liked that word...
Didn't find your answer? Ask the community — no account required.
K
krw
Our customers certainly pay all the money for them. Sometimes there just isn't a better technology.
E
ehsjr
Sigh. No answer. So I took some time today to dig out a
16F84A and program it. Works fine - but I had to do the testing with a wire jumper because I didn't have a 10 pos dip switch. (Switch is now on order.) Anyway, it's a little different than I outlined above. I didn't use an interrupt or a counter to keep track of which LED is the current one. Instead, I did everything based on bit testing and advancing though the LEDs in sequence. I figure it is easier that way for a noobie to read the asm source.
I'll post the source if anyone wants it (I can email the schematic) but I figure those who already have a programmer & MPLAB or equivalent and know how to use them can easily program the thing themselves.
Ed
D
don
Yes, this is alway a problem with using "whats on hand".
After spending a few hours on my PC, I finally came out with this circuit:
formatting link
you can get a larger print using the "All sizes". But some how it doesn't work if 2 switches are ON next to each other, ie you cannot bypass led 2&3 or 4&5&6. Is there anyway to get around this problem? The 555 is used as a one shot and the 4081 may be replaced with 4011 to make an RS FF to debounce the foot switch. Sine only 1 LED is switched on at one time I used only one 330 resistors.
So in this project, I think it is defintely more appropiate to use a PIC.
Allen.
E
ehsjr
Hi Allen,
It looks like a timing problem. The 555 extra clock pulse kicks the 4017 to increment by 1, and you need that increment to trigger the 555 to produce another extra pulse when bypassing consecutive LEDs. Trouble is, the 555 pulse is still active, and in addition, the C2/R6 TC hasn't allowed C2 to discharge enough. You need to wait for the 555 to time out, and for the C2/R6 TC before generating the second (third, fourth etc) extra clock pulse.
The relay circuit I posted a while back allows bypassing multiple consecutive lights, but requires SPDT switches. I can post a complete tested** PIC solution using a 16F84A chip if you like. Complete = code (assembler) and schematic. I can also post a picture of it wired on perf board to ABSE or send you email with the schematic & photo if you don't have access to ABSE. The PIC solution also allows bypassing any combination of LEDs.
** = tested with a PC board switch. I don't know how much your foot switch bounces, so I wrote the debounce routine with a multiplier that can be increased to handle badly bouncing switches.
The PIC solution offers the advantage of low parts count:
6 resistors, 1 cap, the 10 position dip switch, the LEDs and the PIC (18 pins). On my perf board, I added a 5V regulator (78L05 and 2 caps). The PIC disadvantage is that you need a programmer and software and have to know how to use them. If you're already set up for that, the disadvantage disappears.
If you want a good no relay hardware solution , use whatever John recommends. His circuits are NICE!
Ed
A
Allen Bong
e
'
Hi Ed,
Thanks very much for your comments on my circuit. Yes I would like a copy of your pic solution as well as the software. I have a 16F628 which is similar to 16F84A to try out your circuit. I've already made the PIC programmer that uses RS232 and it can handle 8/18/28/40 pin PIC.
AFAIK, John has not designed any circuit regarding this application. Actually I enjoyed studying his circuit very much but I was disappointed this time.
As for my circuit, I would see if I can have a workaround on it when I have time.
Allen.
E
ehsjr
I posted the schematic and the .asm file on ABSE. The subject line is: From SED "Need a LED switch"
The 16F628 will work fine - just make sure the option register settings in the .asm file are right for it.
Ed
A
Allen Bong
I
use
ss'
?
e
e
f
e
Ed, I can't access the ABSE as I am using groups.google.com. Would you kindly send a copy to my email address? It's
snipped-for-privacy@yahoo.com
Thanks and regards.
Allen
A
Ardent
Hi Allen
What is that 6502 in your email id? Does it refer to that wonderful
8bit processor?
Just Curious
Archer
Join the Discussion
Have something to add? Share your thoughts — no account required.
Didn't find your answer?
Ask the community — no account required
Report Content
You are reporting this content to the moderators. They will look at it
ASAP.