On/Off pulse switch

Thread Starter

tsk1979

Joined Dec 4, 2013
6
I have a remote control. Its very simple. When I press the switch, the IR LED sends a pulse sequence. Just like normal remotes.
Now I need to modify it such that.

I need to make a device which takes 2 wires as input.
When the wires are shorted, it activates the switch once.

Its different from the current setup, where continuously pressing the switch makes the IR led send pulse sequences continuously.

I want to
1. IF the switch is pushed to on - Send one pulse
2. If the switch is kept on for more than 2 seconds - Send another pulse when switch is disengaged.

So Lets say
I push switch and release it.
IT should work just like a normal remote
If I keep switch on - It should activate it just once
If switch is kept on for more than 2 seconds, then send the signal again when switched is moved to off position.

Any idea about a compact circuit implementation of the same?
 
Last edited by a moderator:

Wendy

Joined Mar 24, 2008
23,421
I have closed the other thread, please carry on the conversation over here. The other thread is one pulse on switch close, and one on switch open . If you want to explore an idea from over there just mention the post it is in on that thread.

I could do this several ways not involving a µC, but the parts count goes up. A µC could do this with one chip and programming.

To paraphrase, push and release, one pulse.

Push, hold for 2 sec or more, no pulse until released, then send a second pulse. Correct?

What is the duration of the pulse, would one second do?
 

Thread Starter

tsk1979

Joined Dec 4, 2013
6
Sorry for the Faux Pass :)
Will take care in future.

As for my question, lemme explain it better.
Imagine a remote control, a camera shutter remote control.
It has a push button switch, and a IR LED.
When you push the button down, it sends LED flashing, for about 400-500ms total in a specific pattern.

If you keep the button pushed it will keep transmitting.

I want to modify that.
I want to attach a switch such that.

When switch is pushed, it activates, and LED starts flashing, but it should do so only once or twice continously. Not more.
i.e. less than 1s
Even with switch pushed continously it should send one pulse to LED.

The older thread solves this.
When you give power it gives output power once.


When you release the switch, i,e, off, it should again send voltage to the LED controller.

So if
Push switch on - Push switch off - such that time difference between on and off less than 1 second -> give voltage to LED circuit for 0.5s or so. Even 1s is okay

Push switch on - Push switch off -such that time difference between on and off >1s. Or maybe >2s(whichever is easier to implement). - Give power to LED circuit once on on, and once on off (Two times)

This is it.
 

inwo

Joined Nov 7, 2013
2,419
I'm having real trouble understanding.

The first post seems somewhat clear.

Is this what you need from a normal push on/push off ir remote.

First press turns device on like normal. But sends only one coded pulse. (so that device is ready for an "off" signal)

If first press is held over 2 seconds, another normal coded pulse is sent (when releasing button), which turns device off?

I'm sorry! I may be wrong or have made it more confusing.:confused:
 

Thread Starter

tsk1979

Joined Dec 4, 2013
6
I'm having real trouble understanding.

The first post seems somewhat clear.

Is this what you need from a normal push on/push off ir remote.

First press turns device on like normal. But sends only one coded pulse. (so that device is ready for an "off" signal)

If first press is held over 2 seconds, another normal coded pulse is sent (when releasing button), which turns device off?

I'm sorry! I may be wrong or have made it more confusing.:confused:
Okay let me explain the purpose, then it will be clear.
Many cameras have IR sensor, but no wired release.
So you use IR remote to trigger camera if you do not want to press shutter.

Now, its fairly trivial to solder points of a intervalometer output to the switch area of the IR remote and get intervaometer working.

For example
http://www.lukehill.com/creativity/tutorial-diy-time-lapse-intervalometer-sony-nex-5/

So
all we need to do is, set shutter speed/aperture etc., depending upon the mode.
Fire up the intervalometer to activate shutter, and every X seconds, the IR remote will activate.

So you can use a simple canon 2.5mm stereo pin intervalometer for IR cams.

Now why the contraption I want.

Lets go to Astrophotography.

I want the camera to take 60 second long exposures at 61 second intervals.

With a wired release, I set camera to bulb mode.

The intervaometer will activate button, camera shutter will open. After 60 seconds it will release button and exposure will stop. Then one second later, this process repeats.

With a wired release cam this is trivial. How to do this for a IR?

With the older simple method, if I keep button pressed IR led is continously on, In bulb mode the camera will have unpredictable behavior.

So what we need is this

Intervalometer makes the switch to on. IR LED flashes one sequence leading to exposure start. 60 second later when it makes switch open, IR led again flashes for 0.25 or 0.5 seconds and we are done, exposure ends.

So for normal mode, I do not need anything. All I need is to use a simple remote, but instead of push button switch I attach a 2.5mm stereo female jack which can take input from a canon intervalometer.

But for exposures longer than 30 seconds, where bulb mode is required, the only option is to make a complex switch.
 

inwo

Joined Nov 7, 2013
2,419
Thank you, it seems alec_t understands and has solution for you.

One thing that I'm not sure I understand is the standard, unmodified remote function.

Does the same key both start and stop exposure?

Or does one key start and one key stop?
 

Thread Starter

tsk1979

Joined Dec 4, 2013
6
Same key starts and stops.
alec_t's solution is good.
Its a variation of this

always @(posedge clk)
begin
ff1 <= D;
ff2 <= ff1;
end

assign out = ff1^ff2;

Clock frequency and having proper reset state can modulate the time I need.
I guess going with an IC is the way to go!
 

inwo

Joined Nov 7, 2013
2,419
I wonder about switching getting out of step.

That's why I asked about using the same key press for start and stop.

If it misses one signal then it will be out of time.

May not matter, as if it ever misses, it will fail anyhow.
 

inwo

Joined Nov 7, 2013
2,419
I'm not sure I do, now! I don't see how the 2sec feature originally asked for fits in with camera bulb mode and 60 sec exposures 1 sec apart :confused:
I'm so glad to hear that. For some reason it isn't clicking for me.

Closest I can come is that a maintained contact sends a one shot pulse then another pulse every 30 sec. while maintained.

Or one pulse with "make" and another pulse with "break" :confused:
 

Alec_t

Joined Sep 17, 2013
14,314
(1) Does your camera, in bulb mode, need 1 pulse to start the exposure and an identical pulse some time later to stop the exposure, or
(2) Is the camera expecting a start pulse coded differently from the stop pulse?
 

Thread Starter

tsk1979

Joined Dec 4, 2013
6
(1) Does your camera, in bulb mode, need 1 pulse to start the exposure and an identical pulse some time later to stop the exposure, or
(2) Is the camera expecting a start pulse coded differently from the stop pulse?
No difference in start and stop. Identical Pulse. This is how all DSLRs with IR control work.
One pulse sequence to start, and one to end.
 
Top