Can soundout be used to port more than one tone to more than one pin simultaneously? If not, is there another way to have two different tones coming from two different pins at the same time?
Thanks,
Greg
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I don' t think this could be done with the standard soundout. This would involve Timer interrupts when expressing the length of the notes, with a separate Timer for each tone.
EDIT: Perhaps this would involve using seperate or independent PWM's to replace the blocking function of Pulseout or soundout ON/OFF.
Last edit: kent_twt4 2018-03-31
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Thank you for the replies. I had seen that article and that's what started me thinking about multiple tone output. I'll go back and read the article more closely and see if it points me in the right direction. What he's done is very impressive to say the least although I believe it goes beyond what my abilities with software.
Greg
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
If you turn a pin on/off at 4 KHz, another pin every other so 2 KHz and another every other from that so 1 KHz. Play around but remember don't connect 8 ohm speaker direct to pin as draws to much current. Use 200 R resistor in series.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Can soundout be used to port more than one tone to more than one pin simultaneously? If not, is there another way to have two different tones coming from two different pins at the same time?
Thanks,
Greg
This sounds interesting.
I don' t think this could be done with the standard soundout. This would involve Timer interrupts when expressing the length of the notes, with a separate Timer for each tone.
EDIT: Perhaps this would involve using seperate or independent PWM's to replace the blocking function of Pulseout or soundout ON/OFF.
Last edit: kent_twt4 2018-03-31
This is tidy. http://wiki.pic24.ru/doku.php/en/osa/articles/pk2_osa_piano
Thank you for the replies. I had seen that article and that's what started me thinking about multiple tone output. I'll go back and read the article more closely and see if it points me in the right direction. What he's done is very impressive to say the least although I believe it goes beyond what my abilities with software.
Greg
If you turn a pin on/off at 4 KHz, another pin every other so 2 KHz and another every other from that so 1 KHz. Play around but remember don't connect 8 ohm speaker direct to pin as draws to much current. Use 200 R resistor in series.