I've hooked up 2 speakers on my unit and just realized that the tone function can only output to whatever is the first pin you trigger. What are the simplest alternatives for outputting audio on separate pins? I could just split the cable, but I'm thinking I might want 2 separate audio channels in the future.
While I'm asking about audio programming, are there any good libraries for simpler sound programming or premade sound "effects", instead of programming each note?
but I'm thinking I might want 2 separate audio channels in the future.
Then, a different board is in your future. The tone() function uses a timer. There is only one timer. If it is being used to control the noise coming from pin A it is not available to control the noise coming from pin B.
What about a DFplayer Mini? Send it a message using a serial pin and it will play a track of your choice from its built-in micro-sd card. It can drive a single speaker directly, or two channels through amplified speakers. Cheap as chips, too!