Hello,
I am working on an arduino project (my first) to replace an audio element in a snow globe that used to play a song! The slot that it needs to fit inside is tiny (circular and 27.5mm in diameter). The GEMMA v2 would fit and the QT Py might fit (can't find its dimensions), but on the CircuitPython Audio Out page, it says, "QT Py M0, Trinket M0 and Gemma M0 do not support audioio!" Does this warning also apply to the newer GEMMA v2 or only the older GEMMA M0, and is this https://www.adafruit.com/product/4600 QT PY the QT PY M0 (meaning it also doesn't have audio out capabilities)? With respect to the GEMMA v2, I suspect that it does have audio capabilities, because I found this: https://www.adafruit.com/product/1759
Additionally, if I got that kit and used it for my purposes, three more questions:
1. How long could the audio file be in seconds?
2. Could I substitute a coin 3v cell battery so that it would fit?
3. What elements in that kit would I not need? I don't need any of the motion sensing stuff; I just want to press a button and have the song play.
Thanks so much for your help!!!
Audioio
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- adafruit_support_carter
- Posts: 29150
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Audioio
That warning only applies to CircuitPython. Since you are going to use Arduino, it does not apply. Further, the Gemma V2 can not even run CircuitPython, which is why it's not even mentioned in the warning.
That kit may be a good way to get started. The motion control is done with a very simple tilt sensor:
https://www.adafruit.com/product/173
which essentially acts like a button. So the kit, as is, could provide an easy start, or at least a good reference design.
That kit may be a good way to get started. The motion control is done with a very simple tilt sensor:
https://www.adafruit.com/product/173
which essentially acts like a button. So the kit, as is, could provide an easy start, or at least a good reference design.
- mahaar
- Posts: 9
- Joined: Mon Feb 22, 2021 2:04 pm
Re: Audioio
1. How long can the audio file be (in seconds) using that kit? I ask because an owl's chirp is significantly shorter than a song.
2. Could I replace the battery in the kit with a 3v button cell battery? The battery included in the kit would not fit inside the slot.
2. Could I replace the battery in the kit with a 3v button cell battery? The battery included in the kit would not fit inside the slot.
- adafruit_support_carter
- Posts: 29150
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Audioio
The owl example uses tone generation, so sound length can be as long as you want. But if you want something like wav file playback, then it's a matter of how much can fit in GEMMA memory.
Any special reason you are using Arduino instead of CircuitPython?I am working on an arduino project (my first)
- mahaar
- Posts: 9
- Joined: Mon Feb 22, 2021 2:04 pm
Re: Audioio
I can’t find any board that runs circuit python that would fit inside of the circular 27.5mm diameter hole inside the snow globe.
What kind of file would I give to Gemma for sound generation?
And if wave, do you know how much can fit in GEMMA memory?
What kind of file would I give to Gemma for sound generation?
And if wave, do you know how much can fit in GEMMA memory?
- adafruit_support_carter
- Posts: 29150
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Audioio
Look at Arduino examples that store wave files in memory and use that for output. That will give you some idea of what's involved.
- mahaar
- Posts: 9
- Joined: Mon Feb 22, 2021 2:04 pm
Re: Audioio
I have; most of them use much larger boards than Gemma. That’s why I ask, is there any chance you know how much storage is on Gemma?
- mahaar
- Posts: 9
- Joined: Mon Feb 22, 2021 2:04 pm
Re: Audioio
Also, could I replace the battery in the kit with a 3v button cell battery? The battery included in the kit would not fit inside the slot.
- adafruit_support_carter
- Posts: 29150
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Audioio
See here for info on suggested battery input options:
https://learn.adafruit.com/adafruit-gem ... -2912360-2
https://www.adafruit.com/product/783
https://learn.adafruit.com/adafruit-gem ... -2912360-2
A single cell would only be ~3V, so not enough. The guide links to this as the suggested coin cell option:You can plug anything from around 4 VDC up to 6 VDC.
https://www.adafruit.com/product/783
- mahaar
- Posts: 9
- Joined: Mon Feb 22, 2021 2:04 pm
Re: Audioio
Thanks! Most of the other arduino music players use much larger boards than Gemma. That’s why I ask about the length of the song I could fit, is there any chance you know how much storage is on Gemma?
- mahaar
- Posts: 9
- Joined: Mon Feb 22, 2021 2:04 pm
Re: Audioio
I am still waiting for a reply, please respond!
- adafruit_support_carter
- Posts: 29150
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Audioio
The GEMMA V2 has 8kB of flash and 512B of RAM.
The GEMMA M0 has 256kB of flash and 32kB of RAM.
The GEMMA M0 has 256kB of flash and 32kB of RAM.
Please be positive and constructive with your questions and comments.