Go Down

Topic: Arduino Lightsaber (Read 5689 times) previous topic - next topic

b-james

You have a very saleable winner there. Thats why you are being quizzed so thoroughly.  Hang on to it man and send it to someone who can manufacture it for you . You will make a fortune

I am getting ready to start a similar build and had found the same swing sensor but the part I cant figure out is how to configure it to detect a swing and not a tilt as the data sheets show its primary a tilt sensor.

I had thought about mounting it vertical the hilt with ball contact down but then if you tilt the saber at the ground it would continually trigger a swing.

Do you just detect on change condition but then I would think a slow tilt would still trigger a swing event and the toy sabers don't seem to do that and I am sure the expensive sound boards don't.

JakeSoft

You have a very saleable winner there. Thats why you are being quizzed so thoroughly.  Hang on to it man and send it to someone who can manufacture it for you . You will make a fortune
It's funny you should say that. I posted up a similar thread to this one in the forums at The Custom Saber shop and the moderator wasn't too keen on people asking me how was built since they sell lightsaber control boards.

While I really just built this for fun and not for sale, everyone tells me I should sell it. LOL

JakeSoft

#33
Feb 19, 2015, 09:09 pm Last Edit: Feb 19, 2015, 09:47 pm by JakeSoft
I am getting ready to start a similar build and had found the same swing sensor but the part I cant figure out is how to configure it to detect a swing and not a tilt as the data sheets show its primary a tilt sensor.

I had thought about mounting it vertical the hilt with ball contact down but then if you tilt the saber at the ground it would continually trigger a swing.

Do you just detect on change condition but then I would think a slow tilt would still trigger a swing event and the toy sabers don't seem to do that and I am sure the expensive sound boards don't.
Let me summarize by saying "It ain't perfect".

I did write the code to detect a change in state; the sensor is basically just a switch with only 2 possible states. I mounted it vertically (and slightly tilted) in the hilt with the ball down. That way when I spin it, swings are detected. When I slash with it, it usually works too, but it's not perfect.  I've worked with some of the toy sabers before and they seem to work the same way (a slow swing will still make a swing sound happen).

It is more sensative than you might expect, though. Just experiment and you'll see. If you want to be able to tell the difference between a slow swing and a fast swing you'll need a different kind of sensor. I know some of the high-priced lightsaber control boards use accelerometers to accomplish this, but expect your code to be more tricky if you go that route.

Go Up
 


Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

Arduino
via Egeo 16
Torino, 10131
Italy