Hello, I was just curious if I have one processor that is serving up the arduino sound tracks doing all the heavy lifting and a second processor that is outputting all the sounds. How would that work from a programming point of view?
Hey @UKHeliBob good to see you again. Honestly i was unsure and ask I was just wondering and curious. It’s more of the line I was thinking like a pc in a way how you have the main cpu and a sound card that produces the sound itself.
Not sure what you mean, an esp32 can do WiFi, Bluetooth and process sound easily, no idea re the Leonardo. From what I have read the esp32 is generally more powerful than Arduino's but I have no exposure to the Leonardo. I think the Leonardo is a fairly old product but no idea if it will work well for your use case.
@sonofcy I just mean I don’t need WiFi or Bluetooth for this project. Wondering how I can pass the code through from one arduino to anotherThe audio file.
Well, you could use an SD card. What is the audio? Something you are creating from a microphone? Don’t forget most sound also has a timing component. That makes the audio intelligible if that is necessary.
Do you mean videos? If not, then only audio? Why not use your phone, it has a recorder, or purchase an audio recorder, they can be had for $20 at the low end and most are about $35.
In the vast majority of cases, using two controllers not only doesn't provide a 2x speedup, but can actually slow down processing. This is because for a combination of two controllers to work quickly, you need a powerful and reliable data communication channel, which requires a lot of resources. As a result, a combination of two Arduinos can be slower than a single controller.
read a byte of audio file
calculate crc
wait for ready ack
send a byte of audio file
if not EOF repeat
.
.
receive a byte of audio file
verify crc
ack the byte
write a byte of audio file
if not EOF, repeat
.
.
"play" the file.
I wrote a data transfer for 1553 (1Mbit/s) which took a few seconds per file (1553 was the customer's internal comm method)... Each file took a few seconds. They had time to wait.