Jump to content

Adafruit Trinket MO + Neopixel ring + Audio FX Soundboard Coding Help

Recommended Posts

I am a total beginner with zero coding experience and I have a Forbidden Planet Blaster Prop I have been working to add basic light and sound functions to. I am 90% there. I have the Adafruit Audio FX Soundboard with speaker connected, 2 sounds loaded and functioning to trigger a power up sound when turned on, and a blaster sound when the momentary trigger switch connected to pin 1 is actuated. Previously I had an LED connected to the ACT pin but it wasn’t bright enough so I got the Trinket MO and the 12 NeoPixel ring. Using Maker I was able to program the Trinket to turn on the Neo ring with the proper color and brightness but I don’t know how to get the Neo to be turned on and off by the ACT pin on the Soundboard. Can someone please help me modify my code so that when pin 4 on Trinket(connected to ACT pin on Soundboard) goes LOW, the neopixel data line connected to pin 0 on Trinket will turn ON Neo Ring, and when Trinket pin 4 goes HIGH it will turn it OFF? Thanks! Here is the Trinket Code I have so far:


let strip: light.NeoPixelStrip = null
forever(function () {
strip = light.createStrip(pins.D0, 12)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...