Home    LittleBigPlanet 2 - 3 - Vita - Karting    LittleBigPlanet 2    [LBP2] Help!
#1

Sensing button release?

Archive: 8 posts


What can i do so that I don't sense a button until it is released? Like a small pulse from a counter that is a pulser? Also, I'd like to know how I can make a timer go up until I let go of a button. I would usually experiment to find out but I'm away from LBP for a while and I got an idea.2011-09-08 21:57:00

Author:
11204
Posts: 111


Feed your button output into a NOT gate and then into a one shot counter to sense a button release.

To time a button press feed the button output into a timer that is set to on/off. When the button is held the timer will count up, when not held it will stay at where is it. If you want it to instantly reset after the button release, feed the button output into a NOT gate and then that NOT gate into the counter's reset input. If you want to determine what position the timer stops at you will need to use a positional sequencer, which I can elaborate on if you need me to.
2011-09-08 22:40:00

Author:
Xaif
Posts: 365


If you want only a pulse then connect say X button to not gate and not gate to the cycle input of a selector that has 2 ins-outs. Then connect the 2nd output of the selector to its 1st input. You will get a pulse from the 2nd output as soon as you release the X button.

If you want a toggle you can just connect the X button to a not gate and then to a toggle switch.

About the timer i think connecting the button to a timer that goes up and down should be enough.

Seems we posted about the same time....
2011-09-08 22:45:00

Author:
zupaton
Posts: 167


What I did was:

Wire the -Button- to a Forwards/Backwards timer.
Wire the timer to a counter set to count to 1.
Wire the timer to a NOT gate.
Wire both the Counter and the NOT gate to an AND gate.
Wire the AND gate's output to the counter's reset input.
Wire the AND gate to a piece of hologram.

The Forwards/Backwards timer should also work for your second question
2011-09-08 22:53:00

Author:
MonarioBabii
Posts: 128


What I did was:

Wire the -Button- to a Forwards/Backwards timer.
Wire the timer to a counter set to count to 1.
Wire the timer to a NOT gate.
Wire both the Counter and the NOT gate to an AND gate.
Wire the AND gate's output to the counter's reset input.
Wire the AND gate to a piece of hologram.


I am surprised that it worked! lol
j/k
It seems we posted in a complexity order. lol
2011-09-08 23:15:00

Author:
zupaton
Posts: 167


Lol I just tried to tackle both questions in one, that way you can set the amount of time you want the button to be held before releasing it for the result.
I'm slow with logic lol, as soon as I read the thread, I went to test if this would work, but by the time I finished posting there were 2 people that posted before me
2011-09-08 23:23:00

Author:
MonarioBabii
Posts: 128


Thanks for the replies everybody! As soon as I get back to LBP I'll try it out, but it seems like it will work. Thanks 2011-09-08 23:24:00

Author:
11204
Posts: 111


The best release gate is a two node selector. Wire the button signal to the 2nd input node and wire the 2nd output node back to input node #1.

A selector will always use the highest signal. So while the button is pushed it's signal will be #2, but this is also now sending a signal to #1, so when it is released, #1 will be triggered. As with most of my brilliant ideas, all credit goes to comphermc. But I use these all over my logic now. They work great!
2011-09-09 04:46:00

Author:
v0rtex
Posts: 1878


LBPCentral Archive Statistics
Posts: 1077139    Threads: 69970    Members: 9661    Archive-Date: 2019-01-19

Datenschutz
Aus dem Archiv wurden alle persönlichen Daten wie Name, Anschrift, Email etc. - aber auch sämtliche Inhalte wie z.B. persönliche Nachrichten - entfernt.
Die Nutzung dieser Webseite erfolgt ohne Speicherung personenbezogener Daten. Es werden keinerlei Cookies, Logs, 3rd-Party-Plugins etc. verwendet.