bbcmicrobit / bbcmicrobit/micropython
Suggestions about connecting speakers (speech module)
- Dominant language
- C
- Stars
- 646
- Forks
- 290
- PR merge metrics
- No merged PRs in 30d
Description
This resource:
https://microbit-micropython.readthedocs.io/en/latest/tutorials/speech.html
...suggests connecting a speaker directly to the pins. It has caused a few questions on the micro-python mailing list about whether this could cause damage to the micro:bit.
There is a small chance that directly connecting a bare (wound) speaker to the pins of a micro:bit could cause back-emf from the inductive load, that exceeds the specified maximum pin voltage of the GPIO pins on the NRF51, causing permanent damage. Not knowing the specific make and model and specification of speaker, it is hard to say whether damage would be caused or not.
My recommendation would be to use a powered speaker. It might be worth in the meantime, to be on the safe side, changing the docs to suggest using a powered speaker.
However, some advice could be added to the docs, as to additional components to add to the speaker connection that would give suitable protection against over-voltage from inductive loads. For example, something like this response (from DarioG on 17 Nov 2007), the Zeners are for over voltage protection. http://www.microchip.com/forums/m295795.aspx
I haven't done the maths or taken any experimental readings, it might be that in practice the frequencies involved mean that the back-emf generated from the inductive load when it is being switched is still within the specified maximum working voltage of the pins.
I just wanted to put this issue here as a placeholder so we don't forget about this fact. If I get a chance I will test a few different arbitrary speakers and do some rudimentary maths to see how close to the voltage limit of the micro:bit pins it reaches.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.