Playback sound Trinket 5V

Hello People,

Can I get a sound file on a 5V trinket (I've found a tutorial for a 3v, but I have lots of 5 volt laying around and would rather use them.)(I've also have some Wemos D1 mini Pro laying around that I also could use!!)

I want a tilt sensor to activate the sound on the trinket and send it to a small speaker and powered by a battery.

What would I need to achieve this in terms of processing (the trinket) and powering it (battery?)

speaker specs :

Rated input power: 2 W
Maximum input power: 2.5 W
Impedance: 4ohm

=> I found the same speakers with 8ohms, would that be better?

Other Microcontroller boards

DFPmini player

My problem with this one is that I don't know if I can ad the tilt function to play, as means of programming it in. This because I don't see any connection as usb or ftdi, and not to eager to desolder de atmel => programming it => solder back on...

WT588D

This one looks perfect, because it has headers and what I think is an usb to alter the code, but nowhere could I find a way of connecting it with arduino to add the tilt function. I might have overlooked with all the other things I'm finding/searching to achieve my goal

Can I get a sound file on a 5V trinket (I've found a tutorial for a 3v, but I have lots of 5 volt laying around and would rather use them.

The voltage a chip is run at has no bearing on what you can do in software. So post a link to the tutorial, unless of course it is an Instructables tutorial then don't bother because it will be crap.

Grumpy_Mike:
The voltage a chip is run at has no bearing on what you can do in software. So post a link to the tutorial, unless of course it is an Instructables tutorial then don't bother because it will be crap.

Adafruit's :slight_smile:

adafruit tutorial

I'm just in the blue why this can not be done on a 5v (the ones I have laying around). Or is it the winbond chip that requires 3V, and if so can a level shifter be an option to press the costs?

And if it's only 1 audio file from a few seconds (quality doesn't really matter), is it possible to have it stored on the trinket. (The winbond chip is discontinued.. and they don't give an alternative :/)

So lot's of ifs, before I order all my stuff ( I need 50 sensor triggered sound modules which can raise the costs quite quickly) I need to make sure if I follow all that's in the tutorial and find an alternative for the winbond chip or if I go for the sound modules and see if they have gpio pins where I can connect my tilt sensor to it.

At last I also found this chip and bought one for tryings sake => JQ6500

:slight_smile:

I'm just in the blue why this can not be done on a 5v (the ones I have laying around). Or is it the winbond chip that requires 3V, and if so can a level shifter be an option to press the costs?

This says :-

Use any microcontroller with SPI. This is a 3.3V part so you'll need to power it with 3.3VDC and use a level shifter if controlling with a 5V micro such as an Arduino.

And if it's only 1 audio file from a few seconds (quality doesn't really matter), is it possible to have it stored on the trinket.

The trinket is a ATtiny85 chip. This has only 8K of flash memory, and it uses a goodly portion of this for the bootloader. But let's assume you have half of this free, then you can store a sound that lasts half a second using this method. Using the same method on the Arduino gives you about 3.5 seconds of audio samples, see Yes-no - Arduino sample player with no extra hardware on Vimeo for an example I did on an Arduino.

The winbond chip is discontinued

Yes there are two problems, the memory size is small for these days, what chips are available tend to be in surface mount packages, like this one SPI flash memory

The trinket is a ATtiny85 chip. This has only 8K of flash memory, and it uses a goodly portion of this for the bootloader. But let's assume you have half of this free, then you can store a sound that lasts half a second using this method. Using the same method on the Arduino gives you about 3.5 seconds of audio samples, see Yes-no - Arduino sample player with no extra hardware on Vimeo for an example I did on an Arduino.

Ok the WT558D supports 2M-32M SPI flash. Which a lot more.
I think it's possible to upload code to the module. datasheet
Something about wring on to the chip with spi flash (with an arduino to flash it I presume).
What I don't see is if there are gpio pins to use to add a tilt sensor. And/Or maybe an infrared sensor.
I/O control output but notting specific about gpio.
(can't copy the text from the data sheet :/)

Whilst the jq6500 has uart communication via usb and has 16m memory...
But I don't get a thing from the code in this to program it and again if it's possible add a sensor to on or two of the pins? serial communiction
I know the code for the serial is something likewise of setting the internal clock on a mcu if i'm not mistaken.
But can I add regular code to those. I.E. If tilt sensor is on = 0x0D
Or am I mixing things up.

Github JQ6500 EDIT so it's programmable and I think has 3 GPIO on the board!! My guess I'll order one of these to test out!

BTW love your work on your site :slight_smile: The glockenspiel I even remember from another work I need help with few years back! That helped me a lot!! Also find it awesome you try to help crossing the bridge between art and technology!!

If above would not be better than the Trinket option I'll start making some levelshifter and some winbond surface mount modules and work my way around then.

What I don't see is if there are gpio pins to use to add a tilt sensor. And/Or maybe an infrared sensor.

You could be right, they all look like they are dedicated to specific functions. Looks like you might have to trigger it with a line of the ATtiny85. But I haven't used that chip myself so all I know is what I have read in the data sheet.