SAMD21 Add Flash

Add Flash Chip

The Flash chip [GD25Q16] is available from Adafruit

Adafruit QTPY

Settup refer to The Adafruit settup guide


Sound production

Download and expand The sounds were all converted to 8 bit and 8000 samples persecond to reduce size on the flash.
I use the Goldwave program to manipulate sound files

Coyote Simulator.

First double click the reset button. This will put the QTPY into Circuit Py modes and the device will show up as a Drive named "QTPY_BOOT"
Download qtpy_m0_haxpress and then drag the file into the "QTPY_BOOT" .
This program will load onto the QTPY and then expose the Flash and rename the device to "CIRCUIPY".
at this point you can drag the sounds into the QTPY Flash by treating CIRCUIPY as a flash drive.
Now the files are on the flash and can be accessed by the Samd21. Note: right now there is no way to play sounds using Python .

We have prepared a sound program sketch to play the files, because there was no QTPY library

QTPY play sounds randomly ---> player-rand.ino

The above program will play sounds automatically, but we want controll over the sounds and we want controll remotely so the Coyote box could be placed far from the house
To solution is to use a LORA relay . To use Lora first you need a Yolink Hub connected to your internet and the Yolink app on your phone

1. Install the YoLink app
2. Install the Hub or SpeakerHub (not included), add to the app (scan & play). Follow instructions provided with the Hub
3. Add the Yolink Relay to the app

The sketch is modified to talk when the relay is activated

The circuit is a little more complicated .
1. the input viltage is 12 Volts, needed for the power amp, so the QTPY needs a 5 volt regulator LM7805
2. The old Radio Shack Realistic AMP I'm using requires a power amp as a preamp I will use the LM380
3. External controll is provided by the Yolink Relay

QTPY play sounds randomly starting at 40.wav to 42.wav with relay control---> player-rand40relay.ino

Play it yourself