No video

Arduino Polyphonic Sound Synthesis - 8-bit Music and DTMF Tone Generator

  Рет қаралды 12,299

Gadget Reboot

Gadget Reboot

Күн бұрын

Playing around with "The_Synth" Arduino library by DZL blog.dzl.dk/
Using one PWM output on the Uno, up to four channels of 8-bit video game music and sound effects can be generated from various waveforms stored in memory, including some wave shaping and modulation options.
I also tried to reproduce some DTMF and other call progress telephone tones by generating multiple simultaneous tones - they sound right to me but I'd still like to test them using a DTMF decoder IC.
Sketch: github.com/Gad...
*Must install the_synth library as noted on github readme.
Patreon: / gadgetreboot
#ElectronicsCreators

Пікірлер: 36
@leachim66
@leachim66 5 жыл бұрын
I love this stuff, this is the type of content nobody else is doing
@electronic7979
@electronic7979 5 жыл бұрын
Nice project👍I like it
@bigsailboatproject
@bigsailboatproject 4 жыл бұрын
Strange! I had the same idea with a PIC chip. It does modem sounds and RRTY, CW AMTRO etc. Cool to see
@toolzshed
@toolzshed 5 жыл бұрын
great tutorial, very informative!
@fsecofficial
@fsecofficial Жыл бұрын
You can also make a dtmf decoder and use it to control things around the house. I used to have a cd Walkman with 2600hz tones tracks 1-5 were $1-$5. Early pay phones would accept the tons before the line was active. Later they caught on and cut off the mic until the line was activated so you would literally drop a dime and then play your tones. There was lots of boxes back in the day. Including my fav which was the cheese box 📦.. most of that is obsolete now as suddenly phone calls cost less even though there’s more of them made than ever. Shocking 😮
@tablatronix
@tablatronix 5 жыл бұрын
Holy shit this is impressive
@MusicalBox
@MusicalBox 5 жыл бұрын
Wait a minute, Doc. Are you telling me that you built a music machine... out of an Arduino?
@toolzshed
@toolzshed 5 жыл бұрын
A synth machineeee? Out of an Ardiuno??? :/
@HazeAnderson
@HazeAnderson 5 жыл бұрын
Back to the Feature.
@vegtersbaas
@vegtersbaas 5 жыл бұрын
chek my SN76489 card --> kzbin.info/www/bejne/nX22oYqLg9aEgsU
@newburypi
@newburypi 5 жыл бұрын
Now the tough part... dialtone detection DTMF decoding. 😁
@GadgetReboot
@GadgetReboot 5 жыл бұрын
Luckily I was going to cheat with that because currently the only dial tone detecting I need is the actual modem when it tries to dial out, so I was actually hoping to use the modem to double check that the dialtone I created was accurate. If I can get the modem to start dialling then it’s all good. Of course I could use the AT command to tell the modem to not wait for a dial tone before dialling but what fun would that be. I have an MT8870 DTMF decoder for the keypad tone detection that I will need to put to use. It still might be fun to use some other discrete chips to detect the other call progress tones just to see it in action.
@newburypi
@newburypi 5 жыл бұрын
@@GadgetReboot MT8870. Wow, that takes me back. I use to work near the guys that designed that chip. Company was called Mitel at the time. Then Zarlink, now Microsemi. All I can remember about DTMF decoding was that it was a pain to design the filters that would work in all use cases. To test, we had a recording of a phone operator from the southern states, who's voice could trip false digits.
@pileofstuff
@pileofstuff 5 жыл бұрын
@@GadgetReboot In a previous lifetime my co-workers built a remote control box that made use of the MT8870 and a bunch of TTL logic. It answered the phone line, received a passcode, and then accepted commands to turn on/off relays (which ultimately controlled some functions at a remotely located broadcast transmitter). I wish I still had the schematic. It was quite a machine.
@GadgetReboot
@GadgetReboot 5 жыл бұрын
Sounds like the project I did in the 90s using the beloved 68hc11 to interpret the DTMF and control relays. I would have liked to have seen a schematic with a bunch of TTL all over it!
@your.free.electrons
@your.free.electrons 3 жыл бұрын
This is cool...
@ThunderboltFedSig
@ThunderboltFedSig Жыл бұрын
Is there as version for the mega 2650?
@stevex3976
@stevex3976 Жыл бұрын
How did you avoid the "narrowing" error of int to char in the arrays defined in tables.h? src/tables.h:1746:1: error: narrowing conversion of '254' from 'int' to 'char' inside { } [-Wnarrowing] }; ^ src/tables.h:1746:1: error: narrowing conversion of '254' from 'int' to 'char' inside { } [-Wnarrowing] src/tables.h:1746:1: error: narrowing conversion of '254' from 'int' to 'char' inside { }...
@GnuReligion
@GnuReligion 5 жыл бұрын
Nifty. Need to take this library apart to see how it works. Expected that direct output from your Arduino would produce a 5V peak-to-peak signal ... too loud for a line input, which should only be about 0.8V. Perhaps there is a way to use the 1.1V internal reference to scale the PWM output? Certainly, with audio that good they did not cut the 256-value steps down by more than 1/6th.
@GadgetReboot
@GadgetReboot 5 жыл бұрын
I don’t have any insight to know if scaling the digital side would retain or impact any overall quality in trying to reproduce things, I wonder if it needs to maintain some sort of headroom while it makes its way out of the Arduino and it’s better to just do scaling externally with a divider or an op amp to match it to other inputs.
@GnuReligion
@GnuReligion 5 жыл бұрын
@@GadgetReboot The author of the library is a very good programmer. Clean code. If it interests you: sox sample.wav -r 20000 -b 8 -e unsigned-integer -c 1 samp.raw trim $time1 $time2 Will let you convert whatever audio sample you want into an 8-bit raw 20khz file, compatible with the DZL scheme. Then, you could use a script like: cat samp.raw \ | hexdump -v -e '/1 "%02x "' \ | awk '{ printf("0x%s,",$0); if (c++>8) { printf(" "); c=0; } }' to spit out a bunch of comma separated data that could easily be put into a const PROGMEM uint8_t *samp {,,,}; structure (in flash), then play the sample back on your Arduino. Not much room to store a lot though.
@falmircamion3534
@falmircamion3534 4 жыл бұрын
Just add a 330 Ohm or less resistor in parallel with the 10nF capacitor.
@bornach
@bornach 5 жыл бұрын
Has any ever gotten through to Jenny on that number?
@GadgetReboot
@GadgetReboot 5 жыл бұрын
It’s hard to say, I’m pretty sure she had to change the number around 1981.
@falmircamion3534
@falmircamion3534 4 жыл бұрын
You might want to check on github for a time travel library, then ;-)
@Larry_Welsh
@Larry_Welsh 4 ай бұрын
The question was asked before by someone else, but here goes again. Is there a way to make this work on the Mega2560? I tried to get this working but with no success. I bought the Uno and it works like a charm. Problem is I need two more digital ports (for my pay phone) Then Uno has. I have been using IC's to generate dial tone and touch tone. The a decoder to send the data to the Mega2560. This discovery could eliminate the need for the chips and decode.
@GadgetReboot
@GadgetReboot 4 ай бұрын
lately I use mozzi and it looks like it lists mega as a supported device along with many others but I haven’t tested that github.com/sensorium/Mozzi I have used it for DTMF tones on ESP modules, here’s one of those videos on my other channel as a reference for how to use the library kzbin.info/www/bejne/o2nbgKN_e7yZkMk
@heshamhegazy4264
@heshamhegazy4264 2 жыл бұрын
Is it possible to combine Five SINE channels simultaneously, I've tried manipulating the code and managed to play five notes together but could get them all to play SINE. Also, how can I view the waveform on the serial plotter?
@GadgetReboot
@GadgetReboot 2 жыл бұрын
I'm not sure what that synth can do, in fact I'm about to start experimenting with the Mozzi synth for DTMF tones, but I'll have to figure out how to do it still. I think it will be easier to generate multiple simultaneous sounds and more features, and it can be used on multiple Arduino platforms github.com/sensorium/Mozzi I don't know if a serial plotter would be fast enough to generate a usable waveform unless only sending out infrequent data points would generate a viewable representation, but the bigger concern might be the time it takes for serial transmission if the processor is busy trying to get data for the audio and send it to the DAC. Sending serial data may cause the audio generation to pause. But I wonder if a faster ESP could handle it...
@HazeAnderson
@HazeAnderson 5 жыл бұрын
Check out pseudo random bit sequence generators ... I just built one using a 555, 4014 shift register and 4070 logic gate. It sounds like Robotron meets Joust. :)
@GadgetReboot
@GadgetReboot 5 жыл бұрын
Is that a linear feedback shift register configuration? I’ve been meaning to make something like that for over a year. Soon enough.
@HazeAnderson
@HazeAnderson 5 жыл бұрын
Yes it is! :)
Игровая консоль на Arduino своими руками [часть 1]
20:40
Заметки Ардуинщика
Рет қаралды 176 М.
Teensy Drum Sample Player
13:06
Gadget Reboot
Рет қаралды 18 М.
Doing This Instead Of Studying.. 😳
00:12
Jojo Sim
Рет қаралды 37 МЛН
Zombie Boy Saved My Life 💚
00:29
Alan Chikin Chow
Рет қаралды 18 МЛН
WHO CAN RUN FASTER?
00:23
Zhong
Рет қаралды 44 МЛН
Yum 😋 cotton candy 🍭
00:18
Nadir Show
Рет қаралды 7 МЛН
СИНТЕЗАТОР НА АРДУИНО
6:13
First Jinn
Рет қаралды 4,5 М.
Arduino Speech Synthesizer:  Talkie Library LPC Speech Generator
10:01
Top Fifteen Mistakes People Make When Designing Prototype PCBs
12:26
Cosplay Light and Sound
Рет қаралды 146 М.
DTMF telephone tone generator - W91312 & T25089
5:08
Pynenberg3
Рет қаралды 4,7 М.
How Oldschool Sound/Music worked
8:44
The 8-Bit Guy
Рет қаралды 3,2 МЛН
MT8870 DTMF Decoder Module - Arduino Test with PWM Audio Synth Tones
10:16
Direct Digital Synthesis - How DDS Works and an Arduino Example
14:22
#818 DTMF (part 1 of 6) Encoder HT9200A
7:50
IMSAI Guy
Рет қаралды 3,5 М.
Doing This Instead Of Studying.. 😳
00:12
Jojo Sim
Рет қаралды 37 МЛН