The Steampunk Forum at Brass Goggles
December 18, 2017, 11:21:26 pm *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Support BrassGoggles! Donate once or $3/mo.
 See details here.
 
   Home   Blog Help Rules Login Register  
Pages: [1] 2   Go Down
  Print  
Author Topic: 'Electrical' problem; converting toggle to 'impulse'?  (Read 1860 times)
Torvald_Faust
Zeppelin Admiral
******
Netherlands Netherlands


Persistent pilfering privateer


WWW
« on: October 06, 2011, 04:25:34 pm »

Before I get started, I will add that I am not quite sure if I am using the correct terminology. Apologies beforehand Wink

I (want to) build a wide variety of props, and my latest idea is building a tactile control panel that I will use to send signals to my computer or laptop, so the PC can, say, play a sound or play a video; the idea being that if I toggle the "hyperspace drive" on, a nice computer lady would be able to confirm my action Wink

The problem I have ran into is a problem of toggle versus 'impulse' switches. The switches I want to use are either on or off. The original idea I had, was to hack something together to convince my computer that, say, the 'a' key on my keyboard was pressed. Though that worked, my computer was convinced the 'a' key was continuously pressed - and no sound program I have tried to use was able to cope with that, leading to unwanted looping of sound.

Though I think there may be a software solution to this, I found myself wondering; would there be a hardware/'eletrical' solution to this problem? E.g. toggle a switch to 'On' and then some thingamajig prevents that the signal is send continuously?
Logged

Professor Bevel
Officer
***
United Kingdom United Kingdom


No, meddle first, understand later.


« Reply #1 on: October 06, 2011, 05:32:07 pm »

A few solutions suggest themselves;

first, buy 'momentary' (usually 'MOM' in the catalogue) switches that do a brief make and then open again when released.  The fact that you're using latching switches is what's giving you the problem.

Second, and there's any amount of googleable circuit designs out there, something monostable that responds to the closing of each side of a SPDT switch (or is it DPST?  Can never remember which way round they go, I just count terminals and check it with a meter before installing) by sending a transient 'on' before dropping back to a monostable 'on' position.

Third, get and program an arduino to send suitable serial-line signals on detecting changes of state in a switch.  You can control several switches from one arduino, and have a wider array of responses than 'treat it as keypress insert-letter-here'

that's just off the cuff, there are probably more, and I haven't even thought about the software solutions because .
I hate coding with a passion.
Logged

You know what this situation calls for?  More gin.
Torvald_Faust
Zeppelin Admiral
******
Netherlands Netherlands


Persistent pilfering privateer


WWW
« Reply #2 on: October 06, 2011, 05:50:06 pm »

Ah! Momentary! Now I remember what I was forgetting Cheesy I'm afraid they're not an option, atleast, not for the feel I want. When I toggle something on, I want it to stay on Wink

Option number two sounds intriguing, and that's mostly because I don't understand what you're saying Wink I'll see if Google-Fu will help.

As far as option number three goes, I'm aware of it. I feel it's a tad pricey, so I hope to avoid it.

Thanks for your help!
Logged
Professor Bevel
Officer
***
United Kingdom United Kingdom


No, meddle first, understand later.


« Reply #3 on: October 06, 2011, 07:53:46 pm »

http://en.wikipedia.org/wiki/Multivibrator#Monostable_multivibrator_circuit - this is the absolute bog basics, there are some more details but that'll get you started.
Logged
Birdnest
Zeppelin Admiral
******
United States United States



WWW
« Reply #4 on: October 06, 2011, 10:18:06 pm »

momentary, yes ...

perhaps a programmable relay?  alliedelec.com

computer modding sites have what's called a latching momentary switch (push-click-momentary on).  similar to a power switch on a pc.
Logged

Onward ho!
Torvald_Faust
Zeppelin Admiral
******
Netherlands Netherlands


Persistent pilfering privateer


WWW
« Reply #5 on: October 06, 2011, 10:21:57 pm »

Perhaps I should've added I've already got switches Smiley But I suppose given that's the case, I'll need a software solution Wink
Logged
xanthra
Snr. Officer
****
United States United States


« Reply #6 on: October 07, 2011, 12:00:13 am »

The professor is on the right track.  I'd use a 555 timer.
http://www.kpsec.freeuk.com/555timer.htm#monostable
Logged
Professor Bevel
Officer
***
United Kingdom United Kingdom


No, meddle first, understand later.


« Reply #7 on: October 07, 2011, 12:28:57 am »

Yep, most monostable/astable switching circuits available in kit form use a 555 somewhere, although you can do them without.  With tuneable caps and resistors you can get some interestingly analogue effects.
Logged
Torvald_Faust
Zeppelin Admiral
******
Netherlands Netherlands


Persistent pilfering privateer


WWW
« Reply #8 on: October 07, 2011, 08:25:45 am »

So, if I understand correctly, such a circuit, when triggered, gives output once, but once the timer reaches 'zero', it goes back to (virtually) no output?
Logged
von Corax
Squire of the Lambda Calculus
Moderator
Immortal
*
Canada Canada

Prof. Darwin Prætorius von Corax


« Reply #9 on: October 07, 2011, 09:48:47 am »

So, if I understand correctly, such a circuit, when triggered, gives output once, but once the timer reaches 'zero', it goes back to (virtually) no output?

Pretty much, yes. The magic word here is "monostable" ie. having one stable state, in which it will happily remain indefinitely if undisturbed; if forced (by an external input) into the other state, it will eventually return on its own to the stable state. The other alternatives are "bistable" (two stable states), which will remain in either state until external input forces it to switch to the other state (like your toggle switches) and "astable" (no stable states) which, lacking external input, will periodically switch itself between the two states, like a clock pendulum.
Logged

By the power of caffeine do I set my mind in motion
By the Beans of Life do my thoughts acquire speed
My hands acquire a shaking
The shaking becomes a warning
By the power of caffeine do I set my mind in motion
The Leverkusen Institute of Paleocybernetics is 5838 km from Reading
Torvald_Faust
Zeppelin Admiral
******
Netherlands Netherlands


Persistent pilfering privateer


WWW
« Reply #10 on: October 07, 2011, 10:03:51 am »

Continuing that train of thought...If I figure out how my toggle switches can trigger such a circuit - would it really result in a single output?

What I'm thinking is this; a toggle switch is continuous input (I think Wink) and this input goes into the proposed circuit. The circuit gives output once, until it goes back into it's stable state. But wouldn't it go into the other state immediately given that it is still getting input?

I suppose it's time I draw out a circuit, with components...Then find a electronics store and figure out it if it wouldn't be cheaper to go for a Arduino, still Wink

And I think that by now I'm proving I'm quite new to electrical engineering Tongue
« Last Edit: October 07, 2011, 10:06:19 am by Torvald_Faust » Logged
Professor Bevel
Officer
***
United Kingdom United Kingdom


No, meddle first, understand later.


« Reply #11 on: October 07, 2011, 10:37:44 am »

Oh, I think you're proving that handily, dear boy.  We've all been there, and I don't doubt there's a few fond and misty moments of nostalgia behind posts in this thread, as we think back to the days when we, too, were that green.
Logged
Torvald_Faust
Zeppelin Admiral
******
Netherlands Netherlands


Persistent pilfering privateer


WWW
« Reply #12 on: October 07, 2011, 10:45:32 am »

As green as I am and as much as I like 'roleplay', I do dare to raise my eyebrow at being called 'dear boy' Wink But I am sure you mean no insult Smiley

And that aside, I know the feeling you are talking about. For instance, I am quite proficient in Photshop - it was amusing to try and explain this and that to a acquaintance of mine.

Speaking of Photoshop, I will use it at my earliest convenience to try and map the circuit-to-be Smiley
Logged
Professor Bevel
Officer
***
United Kingdom United Kingdom


No, meddle first, understand later.


« Reply #13 on: October 07, 2011, 12:14:21 pm »

I am sure you mean no insult Smiley

Indeed not - it's  a matter of perspective.  You just reach my age and see if anyone under 30 doesn't start looking like a kid to you, too.
Logged
Torvald_Faust
Zeppelin Admiral
******
Netherlands Netherlands


Persistent pilfering privateer


WWW
« Reply #14 on: October 07, 2011, 12:30:13 pm »

I do plan to reach such an age, so we will see what happens Wink
Logged
von Corax
Squire of the Lambda Calculus
Moderator
Immortal
*
Canada Canada

Prof. Darwin Prætorius von Corax


« Reply #15 on: October 08, 2011, 08:24:11 am »

Continuing that train of thought...If I figure out how my toggle switches can trigger such a circuit - would it really result in a single output?

What I'm thinking is this; a toggle switch is continuous input (I think Wink) and this input goes into the proposed circuit. The circuit gives output once, until it goes back into it's stable state. But wouldn't it go into the other state immediately given that it is still getting input?

No. The typical monostable multivibrator circuit is also called a "one-shot" in that it's triggered not by a "high" input but by a low-to-high (or high-to-low) transition — in short, when its input is triggered, it generates a single output pulse, and won't do so again until it is reset by the input being switched off.
Logged
Professor Bevel
Officer
***
United Kingdom United Kingdom


No, meddle first, understand later.


« Reply #16 on: October 08, 2011, 12:11:21 pm »

Continuing that train of thought...If I figure out how my toggle switches can trigger such a circuit - would it really result in a single output?

What I'm thinking is this; a toggle switch is continuous input (I think Wink) and this input goes into the proposed circuit. The circuit gives output once, until it goes back into it's stable state. But wouldn't it go into the other state immediately given that it is still getting input?

No. The typical monostable multivibrator circuit is also called a "one-shot" in that it's triggered not by a "high" input but by a low-to-high (or high-to-low) transition — in short, when its input is triggered, it generates a single output pulse, and won't do so again until it is reset by the input being switched off.

You're not quite alongside the Edification of Youth yet, are you?  Don't tell 'em everything, they learn more if they have to look it up.
Logged
von Corax
Squire of the Lambda Calculus
Moderator
Immortal
*
Canada Canada

Prof. Darwin Prætorius von Corax


« Reply #17 on: October 09, 2011, 03:17:42 am »

You're not quite alongside the Edification of Youth yet, are you?  Don't tell 'em everything, they learn more if they have to look it up.
I just figure he'll be more confident in his search if he knows what he's looking for, and that what he's looking for is actually there to be found.
Logged
Torvald_Faust
Zeppelin Admiral
******
Netherlands Netherlands


Persistent pilfering privateer


WWW
« Reply #18 on: October 10, 2011, 01:51:28 pm »

Thank you, Corax Smiley

By now, my expectations begin to shift from 'possible' to 'impossible'. I think I'm going to look into a software solution...
Logged
Professor Bevel
Officer
***
United Kingdom United Kingdom


No, meddle first, understand later.


« Reply #19 on: October 10, 2011, 01:58:31 pm »

Thank you, Corax Smiley

By now, my expectations begin to shift from 'possible' to 'impossible'. I think I'm going to look into a software solution...

Amusingly, I'd be the other way about.  The more it looks like a software solution, the less I like it.  Although I have finally given in and accepted that my best method of getting code written is to kidnap a coder and motivate him with a scientifically-calibrated system of rewards and massive, massive electric shocks.
Logged
Torvald_Faust
Zeppelin Admiral
******
Netherlands Netherlands


Persistent pilfering privateer


WWW
« Reply #20 on: October 10, 2011, 02:15:18 pm »

Given that I do not have the time nor the knowledge to research an solution for the hardware side, I think you can forgive me to think 'software' Tongue
Logged
Captain Shipton Bellinger
Master Tinkerer
***
United Kingdom United Kingdom

Why the goggles..? In case of ADVENTURE!


WWW
« Reply #21 on: October 10, 2011, 06:00:51 pm »

Torvald,

Before you despair of a hardware solution, take a look at this page, especially the section toward the bottom on the NOR gate monostable. This should achieve your aim with (possibly) the smallest component count.

The CMOS 4001 or TTL 7402 integrated circuits each have four 2 input NOR gates, so you would be able to get two monostables from each IC.

If you need any help, drop me a line.

Logged

Capt. Shipton Bellinger R.A.M.E. (rtd)

mark V
Snr. Officer
****
England England


where's the firing shovel

1CC1_36006
« Reply #22 on: October 14, 2011, 06:17:14 pm »

What sort of toggle switches have you got (there are many flavours) it may be possible to open them up to make them passing contact  or to adjust them to spring load them to off (which would give a similar effect in use)   M 
Logged

general hammer abuser former lawnmower fireman
xanthra
Snr. Officer
****
United States United States


« Reply #23 on: October 14, 2011, 11:54:02 pm »

Given that I do not have the time nor the knowledge to research an solution for the hardware side, I think you can forgive me to think 'software' Tongue

So now I must ask...  How are you planning to avoid "hardware" when you still need to interface those switches to your computer somehow?  It can't be actually be "pure" software solution : )
Logged
Torvald_Faust
Zeppelin Admiral
******
Netherlands Netherlands


Persistent pilfering privateer


WWW
« Reply #24 on: October 17, 2011, 09:10:22 am »

Torvald,

Before you despair of a hardware solution, take a look at this page, especially the section toward the bottom on the NOR gate monostable. This should achieve your aim with (possibly) the smallest component count.

The CMOS 4001 or TTL 7402 integrated circuits each have four 2 input NOR gates, so you would be able to get two monostables from each IC.

If you need any help, drop me a line.

I will probably drop you a line sooner or later, then. I hope to reduce my 'worries' to a component list and a scheme what to solder to what Wink

What sort of toggle switches have you got (there are many flavours) it may be possible to open them up to make them passing contact  or to adjust them to spring load them to off (which would give a similar effect in use)   M

That's not a bad idea, actually...Tweaking the switches themselves sounds like fun!

So now I must ask...  How are you planning to avoid "hardware" when you still need to interface those switches to your computer somehow?  It can't be actually be "pure" software solution : )

Obviously I do need hardware, but the problem I see can probably be solved either within the hardware or the software. I have actually made bits and pieces of software, so I have more experience with it Smiley
Logged
Pages: [1] 2   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.20 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.302 seconds with 17 queries.