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

speed detection

Archive: 8 posts


hi all i made a train and i need to detect the speed of the train.So i was wondering if there is and logic to detect speed of an object.2011-02-15 15:51:00

Author:
soulriver
Posts: 67


do you got any speed control on that train? You could get speed from same signal that you feed the train engine

There is way to detect analog signal changes, place combiner and timer, put timer input action to speed, plug source signal to + of combiner, output of combiner to timer, timer output to - of combiner. Set timer time size to something around 0.1s-0.5s. now combiner output analog signal will raise on any change of analog signal positively if change is incresing value, negatively if decreasing value. Timer time size will decide how much cool down of change value you will have, longer time of timer = longer tiem will take diffrential signal to go to 0 if signal not changes

Now since you want to detect train speed, you can detect that by monitoring chnage of analog signal of tag sensor that his analog signal shows disstance between tag and sensor. Put a tag on end of you level and tag sensor with 5000.0 (lowest possible will be best try to change range of tag sensor on start position of your train and set it to range when it start to detect tag on end of the level), and plug that sensor to combiner of circut that i said above, now combiner should output analog signal of speed. Noe all you need is sequencer on positional action input to detect specific speed, ere you got tutorial how to do that:


http://www.youtube.com/watch?v=-yundMiJ5GM
2011-02-15 16:20:00

Author:
Shadowriver
Posts: 3991


thank you men this is a great tutorial but i ovredy figure it out and btw i wanted to detect speed when the train lets say going dawn hill and with no one in controls and my speed controls are set up like this i have adv.. rotators on the wheels set to speed control so what this means when i get the train to lets say "50km" and then relese the analog stick the train still moves but when the train is coasting then i have no way to detect it speed.2011-02-15 16:36:00

Author:
soulriver
Posts: 67


I'm not aware of any good way to do this, so I'll explain my kinda' wonky method. What I do is emit bits of holo with tags on them. I set the emitter to 0.0s about .3s lifetime and max at once to 4. Then get your object going at it's maximum speed and pause. The holo bits should be trailing behind it. Adjust a tag sensor so that it's maximum radius just barely encompasses the furthest key, set it to require 4 keys to activate, and set its input type to closeness. It will output a weaker signal the further the tags get from it, and since it requires 4 keys to activate, it will output the value of the furthest one. Run it through a NOT gate to invert the signal so that it gets stronger the faster the object goes (you might be able to just invert the sensor's output instead of using a NOT, but I'm not exactly sure how that will work with the require 4 thing).2011-02-15 18:01:00

Author:
Sehven
Posts: 2188


that sound complicated what i did basically is made a square put a mover on it connect with a spring to the train so when the train is faster then the mover the square moves closer to the train and the distance between the train and the square shows me the speed of the train.2011-02-15 19:51:00

Author:
soulriver
Posts: 67


wow, sometimes two worlds collide. *Cough* don't they...

Sweet logic theory Shadow, i'm gonna play with that idea some point soon. I've been messing about with using sensors plugged into possitional sequencers rigged with increasing/decreasing analogue strength batteries to essentially make a conduit to output dynamic range as an interplolating analogue current. Been getting extremely interesting results with holo and movers interacting with these rigs set with different paramiters.

Your whole speed detection system will surely add a very interesting flavour to the mix. Looking forward to it XD
2011-02-15 20:12:00

Author:
Epicurean Dreamer
Posts: 224


Well that component is actually what i call analog signal smoother ( i think rtm223 used that also to make a sine wave) , the timer in that curcit actually will follow analog signal value, since combiner works like substractor, doing that asource signal and current timer state it will generate speed signal needed timer to reach same value, since difference decreases over time timer will slow down and smoothly reach source signal state. So combiner sends differential signal and timer sends smother version of changing source signal

I used in few creation, for example Real CTF i used randomizer and that smoother to achieve to generate nice electronic distortion effect on one of the lamps, you can see that here:


http://www.youtube.com/watch?v=YmVlYkKosrM
2011-02-15 21:04:00

Author:
Shadowriver
Posts: 3991


Well that component is actually what i call analog signal smoother ( i think rtm223 used that also to make a sine wave) , the timer in that curcit actually will follow analog signal value, since combiner works like substractor, doing that asource signal and current timer state it will generate speed signal needed timer to reach same value, since difference decreases over time timer will slow down and smoothly reach source signal state. So combiner sends differential signal and timer sends smother version of changing source signal

I used in few creation, for example Real CTF i used randomizer and that smoother to achieve to generate nice electronic distortion effect on one of the lamps, you can see that here:


http://www.youtube.com/watch?v=YmVlYkKosrM

oh WOW so thats how thats done!! thank you mightily kind sir!! since seeing the video of the saw>trapezoid>sine conversion based on RTM's blog i've REALLY rated importantly finding out how to create that, well, 'interesting' motion of the timer, the potential applications speak for themselves. Now i know.

I just realized, it's your videos i've been watching allot of recently. You have a fan! I've learned a massive amount from them, Your doing the community a huge favour, thank you so much!
2011-02-15 22:30:00

Author:
Epicurean Dreamer
Posts: 224


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.