Search the archive:
YaBB - Yet another Bulletin Board
 
   
 
Pages: 1 
Send Topic Print
Switch Question (Read 120 times)
Jan 13th, 2008 at 9:36pm

Mobius   Offline
Colonel
Highest Point in the Lightning
Storm
Wisconsin

Posts: 4369
*****
 
I would like to use a simple toggle switch to have on-off functionality for something like lights or a master switch where you flip it to one position for a momentary button press and back to off for the same momentary button press, but I'm wondering what kind of switch to use.  I have an SPST switch wired up now, but when it switches on, it stays on, which is pretty much what I expected.  Is there a type of switch or a way to wire a switch that would do what I want?  I was thinking of using a DPST switch, but that would still make the switch stay on in each position so I'm at a bit of a loss.
 

...
IP Logged
 
Reply #1 - Jan 13th, 2008 at 9:54pm

JSpahn   Offline
Colonel
Im too sexy for my hair
Philadelphia,PA

Gender: male
Posts: 1808
*****
 
Im guessing you are using the BU0836? There is no way, I know of that you would be able to use a latch on/off switch with that. A mom/off/mom could be used in this application. Up for on down for off,

here
http://www.wiringproducts.com/index1.html

My guess is the toggle is spring loaded and returns to the off position.

another one:

http://www.hosfelt.com/en-us/dept_157.html
item # 51-219
 

...
IP Logged
 
Reply #2 - Jan 13th, 2008 at 11:13pm

beaky   Offline
Global Moderator
Uhhhh.... yup!
Newark, NJ USA

Gender: male
Posts: 14187
*****
 
I do know that if you're using Hagstrom controllers (and possibly others), you can use a latching toggle switch for a momentary command... and of course you can program the controller to recognize both switch positions as the same command.
  In other words, "ON" creates a closure, which the sim will call "toggle lights", and OFF will open said closure, which will also be "toggle lights".
So when you flip the switch up (ON), the lights will go on, and vise-versa.

I was also going bonkers trying to figure out how to make a mechanically-latching switch read as a momentary closure until I found this out.  Grin
 

...
IP Logged
 
Reply #3 - Jan 14th, 2008 at 3:33am

SilverFox441   Offline
Colonel
Now What?
Mississauga, Ontario, Canada

Gender: male
Posts: 1467
*****
 
Mobius, all the info you need to complete your task is in the link below. There are alternate methods as well, some using only solid state devices. The basic operating principles remain the same for all of them.

http://www.flightsim.com/cgi/kds?$=main/howto/toggle.htm

Some extra info can be found at: http://www.flightsim.com/cgi/kds?$=main/howto/switches.htm

This one describes one variety of solid state solution.
 

Steve (Silver Fox) Daly
&&
IP Logged
 
Reply #4 - Jan 14th, 2008 at 2:56pm

npbosch   Offline
Colonel
I love YaBB 1G - SP1!

Posts: 27
*****
 
JSpahn wrote on Jan 13th, 2008 at 9:54pm:
Im guessing you are using the BU0836? There is no way, I know of that you would be able to use a latch on/off switch with that. A mom/off/mom could be used in this application. Up for on down for off,


It is possible. I use 2 BU0836 in my cockpit. (http://www.lbodnar.dsl.pipex.com/joystick/)
I have a normal toggle switches conected to them (not momentary). They work fine. You have to send them via FSUIPC for that. I can imagine that if you read them as a normal youstick controller you get problems. I have joystick disabled in fs and send all joystick input via FSUIPC, works great.

 
IP Logged
 
Reply #5 - Jan 14th, 2008 at 4:13pm

JBaymore   Offline
Global Moderator
Under the curse of the
hombuilt cockpit!

Gender: male
Posts: 10261
*****
 
Norbert,

The problem with doing it that way is that the controller is then sending a continuous stream of pulses (keypresses) for each toggle that is latched on (which can be MANY of them for long periods).  All those pulses are getting sent and read on the buss continuously,.... slowing down your CPU processing and clogging up the USB buss.

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
IP Logged
 
Reply #6 - Jan 14th, 2008 at 8:00pm

beaky   Offline
Global Moderator
Uhhhh.... yup!
Newark, NJ USA

Gender: male
Posts: 14187
*****
 
JBaymore wrote on Jan 14th, 2008 at 4:13pm:
Norbert,

The problem with doing it that way is that the controller is then sending a continuous stream of pulses (keypresses) for each toggle that is latched on (which can be MANY of them for long periods).  All those pulses are getting sent and read on the buss continuously,.... slowing down your CPU processing and clogging up the USB buss.



But I thought that FSUIPC could offset to eliminate this "traffic"...?

My study of Dowson's own support forums confirms this, although I haven't tested it yet: with FS9 and FSUIPC, builders have successfully used latching switches to trigger momentary commands in the program without any noticeable lag.

I suppose every rig would have its limit for how many closures are being dealt with simultaneously, but apparently it's not a show-stopper if you want to use a few latching switches for realism without getting into relays, etc.




 

...
IP Logged
 
Reply #7 - Jan 14th, 2008 at 9:08pm

JBaymore   Offline
Global Moderator
Under the curse of the
hombuilt cockpit!

Gender: male
Posts: 10261
*****
 
Rottydaddy,

Yes...FSUIPC will "ignore" the repetitive keypresses until they change state, but to my knowledge it cannot tell the hardware device to stop actually sending the keypresses.

So those keypress signals are repeating along.

I just can't see that such an approach makes sense.  it seems to beg developing some interference or processing problems.

When there are devices that DO send single keypresses...... this approach seems like a poor way to accomplish the task.  I'd use this particular interface for stuff where a momentary button is really desireable... and use something else (like a Hagstrom KE72) for the toggle type switches.

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
IP Logged
 
Reply #8 - Jan 14th, 2008 at 9:19pm

beaky   Offline
Global Moderator
Uhhhh.... yup!
Newark, NJ USA

Gender: male
Posts: 14187
*****
 
JBaymore wrote on Jan 14th, 2008 at 9:08pm:
Rottydaddy,

Yes...FSUIPC will "ignore" the repetitive keypresses until they change state, but to my knowledge it cannot tell the hardware device to stop actually sending the keypresses.

So those keypress signals are repeating along.

I just can't see that such an approach makes sense.  it seems to beg developing some interference or processing problems.

When there are devices that DO send single keypresses...... this approach seems like a poor way to accomplish the task.  I'd use this particular interface for stuff where a momentary button is really desireable... and use something else (like a Hagstrom KE72) for the toggle type switches.

best,

.......................john



Yes, that's the problem... I'm thinking KE72, but the original question was about a different controller.
 

...
IP Logged
 
Reply #9 - Jan 15th, 2008 at 7:55pm

JBaymore   Offline
Global Moderator
Under the curse of the
hombuilt cockpit!

Gender: male
Posts: 10261
*****
 
What I am tactfully trying to say is that for THAT particular controller...... use momentaries...and save the toggles and wafer switches for a different interface.   Wink

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
IP Logged
 
Reply #10 - Jan 15th, 2008 at 10:01pm

JSpahn   Offline
Colonel
Im too sexy for my hair
Philadelphia,PA

Gender: male
Posts: 1808
*****
 
Well if anything it has been a good overview of how to use FSUIPC and the pros and cons of different controllers Smiley Lets not forget the added cost of the relays when you consider going this route. 5 bucks a relay with the possibility of 30 inputs Shocked

The haggy  makes sense if you absolutely want switches
 

...
IP Logged
 
Reply #11 - Jan 15th, 2008 at 11:00pm

Mobius   Offline
Colonel
Highest Point in the Lightning
Storm
Wisconsin

Posts: 4369
*****
 
Thanks for the input guys.  I think I might stick with simple momentary switches and buttons for now.
 

...
IP Logged
 
Reply #12 - Jan 16th, 2008 at 6:11am

beaky   Offline
Global Moderator
Uhhhh.... yup!
Newark, NJ USA

Gender: male
Posts: 14187
*****
 
JSpahn wrote on Jan 15th, 2008 at 10:01pm:
Well if anything it has been a good overview of how to use FSUIPC and the pros and cons of different controllers Smiley Lets not forget the added cost of the relays when you consider going this route. 5 bucks a relay with the possibility of 30 inputs Shocked

The haggy  makes sense if you absolutely want switches


Uh, yeah... or the other possibility: fabbing switches that latch mechanically, but provide a momentary closure... I actually considered that (very briefly).

The Hagstrom products cost more on average than Bodnar's stuff, but you get a lot more channels and no need for relays or fancy mechs.

Personally, I've got to have proper latching toggles for some things...half the reason I'm building a pit in the first place! Grin Roll Eyes
 

...
IP Logged
 
Reply #13 - Jan 16th, 2008 at 10:07am

JBaymore   Offline
Global Moderator
Under the curse of the
hombuilt cockpit!

Gender: male
Posts: 10261
*****
 
Momentaries are great for some stuff......... like replys to the in sim ATC, switching views, and other "utility" type functions.

But for switching on landing lights, starting engines, and other stuff...... for realism....gotta' have toggles and wafer switches.  Wink

That little unit looks GREAT for some pots and momentaries though.

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
IP Logged
 
Reply #14 - Jan 16th, 2008 at 10:23am

beaky   Offline
Global Moderator
Uhhhh.... yup!
Newark, NJ USA

Gender: male
Posts: 14187
*****
 
JBaymore wrote on Jan 16th, 2008 at 10:07am:
Momentaries are great for some stuff......... like replys to the in sim ATC, switching views, and other "utility" type functions.




Yeah, man... "clicky-clicky". Grin I'm also starting to think more about "blinky-blinky", but fancy indicator lights will be Day 2 stuff.

That is the ultimate... lots of clicky switches and blinky lights. Grin
 

...
IP Logged
 
Reply #15 - Jan 16th, 2008 at 4:23pm

JSpahn   Offline
Colonel
Im too sexy for my hair
Philadelphia,PA

Gender: male
Posts: 1808
*****
 
beaky wrote on Jan 16th, 2008 at 6:11am:
JSpahn wrote on Jan 15th, 2008 at 10:01pm:
Well if anything it has been a good overview of how to use FSUIPC and the pros and cons of different controllers Smiley Lets not forget the added cost of the relays when you consider going this route. 5 bucks a relay with the possibility of 30 inputs Shocked

The haggy  makes sense if you absolutely want switches


Uh, yeah... or the other possibility: fabbing switches that latch mechanically, but provide a momentary closure... I actually considered that (very briefly).

The Hagstrom products cost more on average than Bodnar's stuff, but you get a lot more channels and no need for relays or fancy mechs.

Personally, I've got to have proper latching toggles for some things...half the reason I'm building a pit in the first place! Grin Roll Eyes



There has to be a toggle out there that uses some sort of cam that will latch on and off. I would think it has a single input and each direction results in a keypress.

Off to Google
 

...
IP Logged
 
Reply #16 - Jan 16th, 2008 at 4:38pm

JSpahn   Offline
Colonel
Im too sexy for my hair
Philadelphia,PA

Gender: male
Posts: 1808
*****
 
 

...
IP Logged
 
Reply #17 - Jan 16th, 2008 at 9:37pm

beaky   Offline
Global Moderator
Uhhhh.... yup!
Newark, NJ USA

Gender: male
Posts: 14187
*****
 
Nope; that's a momentary switch. It will always want to return to the center (off) position.
Very useful for some things (I plan to use a few in lieu of rotary switches for simple increase/decrease controls), but not a latching switch at all.

I went through all this on my own... I don't think you're going to find a toggle that latches while providing a momentary closure, as that kind of thing is usually done  with a switch and a relay.
 

...
IP Logged
 
Reply #18 - Jan 17th, 2008 at 3:45am

SilverFox441   Offline
Colonel
Now What?
Mississauga, Ontario, Canada

Gender: male
Posts: 1467
*****
 
Reposting this link because it's clear that some folks didn't look at it.

http://www.flightsim.com/cgi/kds?$=main/howto/switches.htm

Check out Figure 9 and Figure 10. Two resistors, one capacitor and one 35 cent chip (price reduction available if buying in bulk).

Total cost for 100 circuit assemblies would be around $50 plus some assembly time. You could modify a standard size toggle to incorporate a microswitch and provide the same functionality... at around twice the cost.

Forget relays... do it solid state.
 

Steve (Silver Fox) Daly
&&
IP Logged
 
Reply #19 - Jan 17th, 2008 at 8:42am

JSpahn   Offline
Colonel
Im too sexy for my hair
Philadelphia,PA

Gender: male
Posts: 1808
*****
 
That looks promising and the circuit is not that complicated being farmiliar with opto isolators which are used in medical equipment too much. Not to hijack this thread too much but I have a question.

This setup would not recognize down as off and up as on if you say load a flight or shutdown the sim and restart later without setting all the toggles to off.

My question is does a properly setup haggy recognize the physical position of a switch? or would that require a more elaborate setup?
 

...
IP Logged
 
Reply #20 - Jan 17th, 2008 at 7:22pm

beaky   Offline
Global Moderator
Uhhhh.... yup!
Newark, NJ USA

Gender: male
Posts: 14187
*****
 
SilverFox441 wrote on Jan 17th, 2008 at 3:45am:
Reposting this link because it's clear that some folks didn't look at it.

http://www.flightsim.com/cgi/kds?$=main/howto/switches.htm

Check out Figure 9 and Figure 10. Two resistors, one capacitor and one 35 cent chip (price reduction available if buying in bulk).

Total cost for 100 circuit assemblies would be around $50 plus some assembly time. You could modify a standard size toggle to incorporate a microswitch and provide the same functionality... at around twice the cost.

Forget relays... do it solid state.



Ah yes- I'd seen it, but forgotten. The "etc." in my "relays, etc."

Grin
 

...
IP Logged
 
Reply #21 - Jan 17th, 2008 at 9:05pm

JBaymore   Offline
Global Moderator
Under the curse of the
hombuilt cockpit!

Gender: male
Posts: 10261
*****
 
JSpahn wrote on Jan 17th, 2008 at 8:42am:
My question is does a properly setup haggy recognize the physical position of a switch? or would that require a more elaborate setup?


You can tell it to "remember" or you can tell it NOT to remember in the ini file.  They are very programmable and versatile.

Some of this issue is particluar to the model aircraft you are flying.  SOme will "lose" some or all switch positions.

I run a checklist for shutdown just like in a real aircraft.  That way everthing is configured correctly "cold and dark" when I arrive again in the "plane".

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
IP Logged
 
Reply #22 - Jan 17th, 2008 at 9:25pm

JSpahn   Offline
Colonel
Im too sexy for my hair
Philadelphia,PA

Gender: male
Posts: 1808
*****
 
I was thinking the same thing Smiley. Run a shutdown procedure that way Im covered either way.
 

...
IP Logged
 
Reply #23 - Jan 18th, 2008 at 4:19am

SilverFox441   Offline
Colonel
Now What?
Mississauga, Ontario, Canada

Gender: male
Posts: 1467
*****
 
I remember seeing a simpit website a couple years back where the guy had used the "relay" method of achieving this functionality. He came up with a novel solution to the occasional need to match switch position to sim position.

What he did was make the "circuit breakers" out of momentary switches. One breaker hooked in parallel across each switch allowed him to pulse a specific command at need.

I recall thinking that setting the plane to cold and dark was a better solution, but to each his own.  Smiley:)
 

Steve (Silver Fox) Daly
&&
IP Logged
 
Reply #24 - Feb 11th, 2008 at 6:26pm

Padser   Offline
Colonel
Tally-Ho, chaps...

Posts: 241
*****
 
~S~ all,

I've been reading this thread with interest (just dropped in after a long time away).

I use latching switches with Leo's controller (on-off-on) so some of them (gear, flaps, lights, and  what-not) are one for a good while while I am flying. I have them mapped as joystick buttons rather than sending key strokes and have (as far as I can tell) experienced no problems.

I fly IL-2 rather than FS (my poor old machine won't run FSX properly - maybe when I (can afford an) upgrade... Wink) - IL-2 is pretty greedy of processor and memory esources, too, though... Still, I fly it with all the sliders on full and haven't noticed any particular (or progressive) tailing off of performance even in busy online servers. My machine isn't particularly high-end nowadays - AMD 2800+ Barton processor with 2GB ram and an NVidia 6800S graphics card.

Is there a difference between simply sending the button signal and using a keystroke (I've thought about using something along the lines of Total Game Control to do this in the future). I ask because I'd like to be able to use proper on-off toggle switches on my next project - looks like that capacitor solution mentioned by SilverFox might be the way forward for me (I'd prefer to use the BU0836 if it looks feasible - I like Leo, like his controller, like his prices... Wink

TTFN

Pads


JBaymore wrote on Jan 15th, 2008 at 7:55pm:
What I am tactfully trying to say is that for THAT particular controller...... use momentaries...and save the toggles and wafer switches for a different interface.   Wink

best,

....................john


 
IP Logged
 
Pages: 1 
Send Topic Print