Espruino Star Wars (first steps) #2124
Replies: 9 comments
-
Posted at 2015-05-07 by @allObjects Begin with fun, resume with fun... |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-05-07 by d0773d That's awesome! I'm a huge Starwars fan. I know this is late "May the Fourth be with you." :) |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-05-07 by @gfwilliams Love it! Thanks for posting it up :) I think this is actually the first time I've seen a project with images in it... Did you use the ImageMagick commands in the graphics page to get the images into Espruino, or did you do it some other way? Also, I don't know if it helps, but it's actually possible to get two separate pitches out of one speaker. Just connect each side of it to a PWM output (and make sure you do You can also output actual waveforms if you want to, even at once. I did a forum post on it, but I'm the most un-musical person ever so never managed to come up with two distinct music tracks to play at once :) |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-05-07 by LawrenceGrif My 7 yr old will want me to build one too, Great Fun thanks for sharing! |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-05-07 by vickingur Hi All, Thanks for positive feedback! Gordon, The first image was created just as bitmap buffer, then we found your ImageMagick tutorial and used it for creating other images. It worked very nice. The only thing is that we inverted colors in some images using '-negate' option. Also, thanks for your suggestion about 2 pitches from 1 speaker - we're looking forward into investigating this, maybe it's possible to create a quartet from 2 speakers?)) We'll look into using waveforms as well, it seems promising. It looks like our appetites are growing, so will keep you posted ;) Thanks, |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-05-13 by vickingur Thanks for suggesion regarding connecting both sides of seaker to PWM outputs! Not bad techno music for my taste :) Also, this time I feel ready to share the code for this demo (still not perfect though), maybe it will help somebody.
The result was achieved pretty quickly, making me confident we can play even better tunes in future. Thanks, |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-05-13 by @allObjects Really nice code! The wave thing, is it for play (back) of a recording made using waves? PS: BUZZER#s are variables too... it is good practice to define them as such (epecially when evetually putting the code into a module. Not adding the var, messes with the global name space. In this sample code not releveant because it is already in the global namespace). All upper case makes it clear that it is not really a var. For the pitches (PITCHES), the property names do not need to be quoted. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-05-13 by vickingur Thanks for pointing to missing 'var' statements, I just overlooked that! I'm not using JavaScript often, so tend to forget simple things. Yes, wave thing is for playing WaveForms. It's not used here as I didn't get it output something really interesting yet. I know it's somewhat confusing in this example, but I was planning to make a reusable module from Buzzer, which could play both WaveForm and simple pitches, so the code is mentioning waves. As for the PITCHES - this is a copy-paste from espruino examples. And too me it's more clear to have quotes there. There is no need to dig into JavaScript magic in this case :) Thanks for the feedback, it is really useful! |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-05-14 by @gfwilliams That's great! It's really nice to have a reusable bit of code that plays each instrument :) Strange about the sound - it seems that when the two notes interact it's a bit quieter? |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-05-06 by vickingur
Hi guys!
Just started playing with my brand new Espruino Pico boards and can't stand sharing this.
I know it's very basic, but it's just.. so fun!!
So here are the results of me and my friend's 2 hours of life. We are just starting, so don't judge hard.
https://vimeo.com/127084624
Enjoy,
Victor
Beta Was this translation helpful? Give feedback.
All reactions