Hello to all the contributors of your extensive thread!
As I am in Australia, lightsabers are pretty dang expensive to acquire or build here due to shipping costs, but I have always wanted to build one. A few months ago built an analogue RGB saber with a cheap toy soundboard out of what ever I could find: latching power switch for "on" and three 2-state toggle switches to change the colours. It works and I have had fun with it but I really want to go further with it so at this point I have waited the 6 weeks for all the various combinations of Usaber and LSOS parts to arrive so I could finally start modernising this JunkSaber(v2).
Skillset: Electronics
weakness: Coding (I rely on pseudo code to track my variables)
At this point walking through all the code examples to understand Class calls and using libraries with increasing success - slowly In the last few weeks I have spent many evenings examining all the examples and advice here, as well as for LSOS but have not yet got anything fully functional. Originally I hoped recreate the Homebrew method of LSOS but I cant get it Play sounds or detect motion, although my library tests have all worked with these units individually. So think the best thing right now is to roll up the sleeves and start fresh, with a simple plan and a new sketch.
Parts list that I have:
DFplayer
Nano
MPU6050
RGB and RGBW LEDS (and other various ones from projects)
I also have the WT588D-U-32M and clash sensors to test next, with the ADXL on the way soon.
Basic code parameters for now will be:
(after killkey or latch switch)
SETUP
define pins and inclusions # etc
Colour array [1-7]
Colour = 1
Main_Loop:
if Button High < 900ms (only one....BP)
Blade_on/off
colour
If Led_on/off (default blue) call Colour [1 of 7]
send sound power_on
if button = DoubleClick & blade_on = true
if colour ==7 then colour ==1
Else
colour ++1
//Colour Array defined in class
detect swing = play swing
detect clash = play clash
End Loop
Really basic but I thinks its best that I crawl before walking for now as I just want lights, sound and action.
PS I use to use the old PICAXE to control LED projects in the past, very BASIC...
I really hope I can create something that I can be proud of with all the advice that has been compiled here, so thank you for all this information.
Last PS, really love the DIYino but it equates to AUD$100 for me to acquire, so the idea of using AUD$25 worth of parts sounds like a great start for my budget.