Search the archive:
Simviation Main Site
|
Site Search
|
Upload Images
Simviation Forum
›
Computer Hardware & Software Forum
›
HomeBuild Cockpits
› Switches
(Moderators: Mitch., Fly2e, ozzy72, beaky, Clipper, JBaymore, Bob70, BigTruck)
‹
Previous Topic
|
Next Topic
›
Pages:
1
2
Switches (Read 3431 times)
Oct 30
th
, 2003 at 3:18am
Smoke2much
Offline
Colonel
The Unrepentant Heretic
Sittingbourne, Kent,
Posts: 3879
I need some advice. I am building a "panel" for a single engine GA aircraft to replace many of the keyboard functions.
I am planning to use a game pad and the guts of a keyboard to provide the functions.
My problem is that I want some of the functions to be switches rather than buttons eg the lights. How can I convert a button press to a switch?
For example if I assign "L" to the landing lights on a keyboard I press L and the lights come on. If I solder in a switch to replace L when I switch the lights on it will be the equivalent of holding my finger on L and the lights would constantly switch on and off.
Any clues?
Will
Who switched the lights off? I can't see a thing....... Hold on, my eyes were closed. Oops, my bad...............&&
Back to top
IP Logged
Reply #1 -
Nov 2
nd
, 2003 at 10:49am
JBaymore
Offline
Global Moderator
Under the curse of the
hombuilt cockpit!
Gender:
Posts: 10261
Will,
I have been pondering this one too. Was thinking of building a perfboard or two with a number of IC's that act as solid state latching relays. One pulse to the "trigger" and they turn on and stay on until another pulse goes to the "trigger" and they turn off.
It is not a hard circuit....... but it is a lot of parts and soldering of IC sockets and tiny wiring pins and such. Plus the parts add up the $ quick.
In my search on this, I just found this website (below) that takes the "old" pre-IC approach to the whole issue. There is something to be said for that for the "average person" doing the construction. If you can find the parts via electronic surplus...... it shouldn't be too expensive to accomplish.......... and it is really straightforward wiring construction.
http://home.planet.nl/~schre010/fs/toggle.html
It will work with any type of single pole single throw switch.....not just a toggle....... rockers, slide, and so on too.
If you also want to add a cockpit panel indicator lamp........
Get a DOUBLE pole single throw switch. Wire one set of poles as the above website shows. On the SECOND set of poles...... you wire the poles to act as an "on/off" switch to control 12V dc (or whatever voltage you use) that gets routed to an indicator LED assembly with a current limiting resistor. Then when you flip the switch..... the effect happens in the simulator.... and the light comes on in your cockpit to tell you you have the switch "on".
BTW....look around for a local electronic surplus place. I have one about 30 minutes drive from here that has all manner of stuff. I won't pay more than $1.00 for any switch I will use in my cockpit. Ditto for panel mount LED indicator assemblies with current limiting resistors.
If you can't find one local to you...... try the net and mail order.
best,
................john
PS: Be careful if you add the indicator lamps. If you get the supply voltage for the LED on the wrong pins...... you'll likely "fry" whatever interface that you are driving with the switches.... like that keyboard encoder card you are thinking of using.
Intel i7 960 quad 3.2G LGA 1366, Asus P6X58D Premium, 750W Corsair, 6 gig 1600 DDR3, Spinpoint 1TB 7200 HD, Caviar 500G 7200 HD, GTX275 1280M, Logitec Z640, Win7 Pro 64b, CH Products yoke, pedals + throttle quad, simpit
Back to top
IP Logged
Reply #2 -
Nov 2
nd
, 2003 at 12:32pm
Smoke2much
Offline
Colonel
The Unrepentant Heretic
Sittingbourne, Kent,
Posts: 3879
Thanks John. What I was thinking of doing was using the Keyboard buttons and cleaning the letter information off. Each button would then run two of the press switches at the same time, the LED's would be on a seperate circuit and be battery powered.
Will
Who switched the lights off? I can't see a thing....... Hold on, my eyes were closed. Oops, my bad...............&&
Back to top
IP Logged
Reply #3 -
Nov 2
nd
, 2003 at 11:29pm
Vchat20
Offline
Colonel
Living in my virtual reality
so you don't have to.
Gender:
Posts: 57
can someone plz either explain or redo that diagram in that article for me? im quite confused. what I dont get ishow the 10V source is supposed to temporarily charge the capacitor. might be better if you just explain the whole thing for me so I dont get confused.
Back to top
IP Logged
Reply #4 -
Nov 2
nd
, 2003 at 11:45pm
Smoke2much
Offline
Colonel
The Unrepentant Heretic
Sittingbourne, Kent,
Posts: 3879
I'm trying to get my head around the diagram as well Vchat. I haven't had to look at electronics for the best part of 12 years LOL.
The article states that you need more complex electronics to run Shift + functions or Ctrl + functions, I think it would be possible to run these by simply duplicating the diagram shown, one for each button. Or make the circuit with two capacitors in parrallel, each running a separate relay. The two relays should go off simultaneously giving you the response you need. You could even run the Shift or Ctrl relay from a slightly larger capacitor so that the relay stays on for longer and gives the effect of holding down the button ensuring that it is picked up as a Shift +, and not a Shift then.
If you follow me.
Will
Who switched the lights off? I can't see a thing....... Hold on, my eyes were closed. Oops, my bad...............&&
Back to top
IP Logged
Reply #5 -
Nov 2
nd
, 2003 at 11:49pm
Vchat20
Offline
Colonel
Living in my virtual reality
so you don't have to.
Gender:
Posts: 57
yeah, I follow you. so what you explained could be easily used as an engine cutoff switch if made properly.
this is all getting more confusing by the minute. ???
Back to top
IP Logged
Reply #6 -
Nov 3
rd
, 2003 at 12:02am
Smoke2much
Offline
Colonel
The Unrepentant Heretic
Sittingbourne, Kent,
Posts: 3879
The great thing about the Home cockpit set up is that you can make it as complex or as simple as you like. The great thing about relays is that one switch can be made to operate as many circuits as you want to. With the Shift+ or Ctrl+ functions and an LED or light bulb you have three separate functions from one switch. Nice.
Remember that a keyboard has 67 buttons on it
A-Z (26)
` [ ] ; ' # , . / \ Tab = - Backspace Insert Delete Home End Page Up Page (19)
Num Pad 1-0 (10)
Function Keys (12)
not including 1 to 0 which are hardwired to ATC functions. This effectively gives you 67 switches to play with not including any buttons that come from joysticks/joypads that you have cannibalised for potentiometers.
You shouldn't need to have any shifted functions.
Will
Who switched the lights off? I can't see a thing....... Hold on, my eyes were closed. Oops, my bad...............&&
Back to top
IP Logged
Reply #7 -
Nov 3
rd
, 2003 at 7:08am
Vchat20
Offline
Colonel
Living in my virtual reality
so you don't have to.
Gender:
Posts: 57
well, just sent an email to the guy with the toggle switch wiring page and hopefully I can get a detailed story on exactly how the thing is wired out of him. ill post any results I get here.
Back to top
IP Logged
Reply #8 -
Nov 4
th
, 2003 at 5:03am
HerSELF
Offline
Colonel
DESMOND. Artwork Edited
by Pippin
Norfolk, England
Gender:
Posts: 343
Thanks Vchat it will certainly clear-up the confusion in this house if you can.
Sarah
The female of the species is more deadly than the male.
&&&&
Back to top
IP Logged
Reply #9 -
Nov 4
th
, 2003 at 10:06am
Vchat20
Offline
Colonel
Living in my virtual reality
so you don't have to.
Gender:
Posts: 57
well, i got a reply. hope it helps
Quote:
Hi,
Thanks for your remark. I'll try to reply, though I'm not too sure which part is the tricky one my site. If it is about wiring a relay or a capacitor, please let me know; I could send you some picture or PCB layout. If it is about how exactly this circuit works, then here we go:
Any relay consists of a switch (left part in the relay drawing on the webpage) and a coil (right part). When an electric current is running through it, the coil becomes electromagnetic and thereby attracts and closes the switch. As long as the coil current is strong enough, the relay switch remains closed.
While the capacitor is getting charged more and more by this current, the voltage over the capacitor increases. Hence the voltage over the relay coil diminishes, as the two voltages have to add up to 10 V, the external power source. With the relay coil voltage getting lower and lower, at some point the coil-current will no longer be strong enough to keep the relay switch closed.
In the end the capacitor is charged, its voltage 10 V, the current has stopped. The whole 'pulse' doesn't take more than some milliseconds.
When the main switch is toggled (from the 10 V position to the 0 V position) the capacitor starts to discharge, as it is connected to zero. The generated discharging current activates the relay coil and closes the relay switch. This 'pulse' won't last for long either: the capacitors voltage drops as it loses charge, the current diminishing proportionally.
I hope this will help. Otherwise don't hesitate to remail.
Back to top
IP Logged
Reply #10 -
Nov 6
th
, 2003 at 1:13am
Vchat20
Offline
Colonel
Living in my virtual reality
so you don't have to.
Gender:
Posts: 57
ok. i think I get it now. follow me through this diagram as best as possible:
what happens is when the switch is flipped to on, it connectes the 10V source (anything from a battery or sourced from a ac/dc transformer) to the rest of the circuit. this connects the capacitor (indicated as the break in the circuit with the label "220uF") to that source and charges it. as the capacitor voltage rises up to 10V the current slowly drops. while it is doing this the relay has already done its work and has activated the keystroke. when the capacitor reaches 10V, there is no longer enough current left to operate the relay. the relay then stops the keystroke. the toggle switch is still in the on position but the key is no longer being pressed. when the switch is flipped to the off position, it connects both sides of the capacitor to the 0V source and thus it discharges. when this happens the current is then back to normal and activates the relay once more. and with no electrical source to charge the cpacitor slowly loses al its charge, once that happens the relay stops working again and the keystroke has ended. anyone understand now?
btw, the extra bit with the dashed lines is just showing how to connect a LED indicator to the circuit. the long rectangle part is a resistor and the part below it is the LED.
Back to top
IP Logged
Reply #11 -
Nov 6
th
, 2003 at 10:30am
JBaymore
Offline
Global Moderator
Under the curse of the
hombuilt cockpit!
Gender:
Posts: 10261
Vchat,
You have the idea fundamentally correct.
Just to clarify a tad..... it is the electrical charge stored in the capacitor when it was connected to a positive voltage source that activates the relay as it discharges to the ground (0V) that the switch connects it to when in the "off" position.
This is a pretty simple solution to the "constant keypress" problem.
BTW..... nothing magic about the 10V+ figure. Could be other values...as long as the rating of the coil on the relay and the operating voltage of the capacitor match OK.
best,
...................john
PS: I just had a thought...... Will....if you are using a canabalized keyboard encoder to hook your switches up to, I KNOW that there is a way to adjust the "repeat rate" of a keypress. Is there a a way there to shut it completely OFF? Ah... but that would not solve the problem of RELEASING the switch, would it. Never mind
.
Intel i7 960 quad 3.2G LGA 1366, Asus P6X58D Premium, 750W Corsair, 6 gig 1600 DDR3, Spinpoint 1TB 7200 HD, Caviar 500G 7200 HD, GTX275 1280M, Logitec Z640, Win7 Pro 64b, CH Products yoke, pedals + throttle quad, simpit
Back to top
IP Logged
Reply #12 -
Nov 6
th
, 2003 at 10:51am
Smoke2much
Offline
Colonel
The Unrepentant Heretic
Sittingbourne, Kent,
Posts: 3879
Neither will the capacitor circuit. You need to switch it "on" each time to get a key press. The only way I can see of working stuff with switches is by having three position jobs.
ON
OFF
ON
You would have to push the switch through the off section for each toggle of the "key" relay.
Things are on hold until I get the use of my left thumb back. Stuck a knife in it.
Will
Who switched the lights off? I can't see a thing....... Hold on, my eyes were closed. Oops, my bad...............&&
Back to top
IP Logged
Reply #13 -
Nov 6
th
, 2003 at 11:34am
KnightStryker
Offline
Colonel
What do you mean you can't
hear the voices???
Muskegon, Michigan
Gender:
Posts: 432
Quote:
Things are on hold until I get the use of my left thumb back. Stuck a knife in it.
Now why did you go and do something like that for?
Just kidding.
What if you made a switch that had a rounded flange on the back, kinda like the flanges(?) on a cam shaft in a car that push the valves? then all you need to do is mount them over the keyboard and as you move the switch from the off position to the on position the flange presses the key and releases it as it goes past. Then the same thing happens when you move it back to the off position. It would be a tad bit of work but it would save cost in electronic parts and gizmos. Sorry if you don't understand what im trying to say but it makes perfect sense to me
Another option would be to use a push button with an led inside that lights up when you press it and turns off when pressed again therefore giving you an indication that it is turned on and only giving you one press of the button on the keyboard instead of constant pressure.
Just a few ideas, hopefully someone understands the first one as I am going to try it myself.
Ok I will stop rambling on now and let you get back to your lives.
Confused,
Kevin
Back to top
IP Logged
Reply #14 -
Nov 6
th
, 2003 at 12:43pm
JBaymore
Offline
Global Moderator
Under the curse of the
hombuilt cockpit!
Gender:
Posts: 10261
Quote:
Neither will the capacitor circuit. You need to switch it "on" each time to get a key press.
Will,
Wow..... sorry to hear about the thumb. Hope it is not a really serious cut. Wasn't a scalpel at work by any chance, was it? Dominant hand...or other one?
Actually, the capacitor setup WILL work for some functions. If the keypress function in the sim is "press it once to turn it on....press it again to turn it off"... then it will work just fine. And the led incicator will be in sync with the function in the sim..... if you get it "right" the first time.
If you don't..... you'll have to manually discharge the cap to get it back to the right direction.
The relay closes briefly (generating a keypress) when the toggle is set from "off" to "on" and the cap charges up. Then the circuit sits there for a LONG time with a charge on the capacitor. When the switch is then moved to the "off" position the charge on the capacitor is discharged thru the relay....and it generates another brief keypress.
The cap will hold it's charge a certain amount of time.....not sure exactly how long. Depends on the cap. But it slowly loses it's charge. So this might be a "function issue".
If you shut down the sim with the cap charged......... (switch in the "on" position) and then come back a few days/week/month later and turn on the sim......... it is possible that the switch led indicator and the function in the sim could get "backward". This issue might necessitate installing a "discharge all capacitors" button (bring to ground) in the cockpit that allows you to sort of "cold start" things to be sure. Just add it to your checklist
.
Take care of the thumb.
best,
...................john
Intel i7 960 quad 3.2G LGA 1366, Asus P6X58D Premium, 750W Corsair, 6 gig 1600 DDR3, Spinpoint 1TB 7200 HD, Caviar 500G 7200 HD, GTX275 1280M, Logitec Z640, Win7 Pro 64b, CH Products yoke, pedals + throttle quad, simpit
Back to top
IP Logged
Pages:
1
2
‹
Previous Topic
|
Next Topic
›
« Home
‹ Board
Top of this page
Forum Jump »
Home
» 10 most recent Posts
» 10 most recent Topics
Current Flight Simulator Series
- Flight Simulator X
- FS 2004 - A Century of Flight
- Adding Aircraft Traffic (AI) & Gates
- Flight School
- Flightgear
- MS Flight
Graphic Gallery
- Simviation Screenshots Showcase
- Screenshot Contest
- Edited Screenshots
- Photos & Cameras
- Payware Screenshot Showcase
- Studio V Screenshot Workshop
- Video
- The Cage
Design Forums
- Aircraft & 3D Design
- Scenery & Panel Design
- Aircraft Repainting
- Designer Feedback
General
- General Discussion
- Humour
- Music, Arts & Entertainment
- Sport
Computer Hardware & Software Forum
- Hardware
- Tweaking & Overclocking
- Computer Games & Software
- HomeBuild Cockpits ««
Addons Most Wanted
- Aircraft Wanted
- Other Add-ons Wanted
Real World
- Real Aviation
- Specific Aircraft Types
- Autos
- History
On-line Interactive Flying
- Virtual Airlines Events & Messages
- Multiplayer
Simviation Site
- Simviation News & Info
- Suggestions for these forums
- Site Questions & Feedback
- Site Problems & Broken Links
Combat Flight Simulators
- Combat Flight Simulator 3
- Combat Flight Simulator 2
- Combat Flight Simulator
- CFS Development
- IL-2 Sturmovik
Other Websites
- Your Site
- Other Sites
Payware
- Payware
Old Flight Simulator Series
- FS 2002
- FS 2000
- Flight Simulator 98
Simviation Forum
» Powered by
YaBB 2.5 AE
!
YaBB Forum Software
© 2000-2010. All Rights Reserved.