RealNobser / BetterDuinoFirmwareV4

7 stars 2 forks source link

betterduino sound commands #9

Open stewartgill1977 opened 3 weeks ago

stewartgill1977 commented 3 weeks ago

Hi hope you can help i have noticed after changing to betterduino some sounds are not triggering with the sequence trigged eg the beep cantina the panels work but the sound for that seq dose not trigger anymore as showing in the picture the command im using. I have not changed anything apart from the firmware is there a bug or do i need to change something?. I have notices some buttons now have different seq after the flash but that's no problem just trying to get the sound working. In saying that the leia one is working and scream one is fine as well so im not two shore what going on. Also CONFIGURE: Arrow Down + CIRCLE i had set to disco witch dose the panels but not the sounds at well

Untitled Untitled

stewartgill1977 commented 3 weeks ago

just tired to assign the command disco to another button and yep get the panels but no sound :SE09 very strange as it was find with the old firmware hmmm

RealNobser commented 3 weeks ago

Hi Steward. First of all: Don't mix things up. MarcDuino/BetterDuino has nothing to do with your code snipplet above. The one above is ShadowMD. BetterDuino has nothing to do with button assignment.

HINT BetterDuino supports multiple sound interfaces. Have a look here: https://github.com/RealNobser/BetterDuinoFirmwareV4?tab=readme-ov-file#setup-commands

Configure the right one, default is SparkFun MP3

MPxx | Set MP3-Player Type·

MP00 : SparkFun MP3 Trigger·

MP01 : DFPlayer·

MP02 : Vocalizer

Please read the documentation an configure BetterDuino matching your hardware setup.

stewartgill1977 commented 3 weeks ago

HI im a little confused lol sorry. I have set it all up using the commands on your page yes im using mp3 trigger. I have entered :SE09 (disco) and :SE07 cantina dance i get the panels but no sound trigger for those two commands all others are working. do those two now have no sound attached to them now?

thanks :)

RealNobser commented 3 weeks ago

They have, they work fine here. Can you please send a list of the directory structure of you MP3 SD-card directory?

stewartgill1977 commented 3 weeks ago

image

stewartgill1977 commented 3 weeks ago

its not a Biggy its only two sequences that do not trigger the sound but i found a work around as in the pic. All others work as intended image i have no idea why the number for the sound file is not the actual number on the sdcard i just copied the sound number from the r2 app that was what i had on my old setup works no problems but yea strange music used is 181 mus-6. on sd card and 86 in the code

RealNobser commented 3 weeks ago

$86 means "bank 8, song 6"

There had been an change in the most recent MarcDuino-Versions regarding the numbers of the sound banks and songs. BetterDuino also uses that mapping. Use the following numbering:

201 Beep Cantina 202 Star Wars 203 Imperial 204 Mana Mana 205 Cantina 206 Disco 207 R2 Star Wars 208 R2 Imperial 255 Startup Sound

stewartgill1977 commented 3 weeks ago

arrr ok so this is why maybe its not trigging the sound? Do you have a link to the updated sounds list or is it just these ones that have changed? and all i have to do is renumber the files i have to the numbers you show here?

RealNobser commented 3 weeks ago

It is just the music files. They moved from 176++ to 201++

stewartgill1977 commented 3 weeks ago

great thanks for the info )

stewartgill1977 commented 3 weeks ago

so should look like this then just copy to sdcard like that and all should be good ? ignore the files names 806 to 815 this is what the r2 app uses to trigger those music files no idea why but just dose lol image

RealNobser commented 3 weeks ago

Should work that way. Give it a try...

stewartgill1977 commented 1 week ago

hello it looks like the play sound command $x will not play the bank at random eg i use Serial1.print("$9\r"); to play music in bank 9 at random but nothing happens also tired other banks. It does how ever work if you also add the track number eg Serial1.print("$921\r"); is there a bug im trying to assign a button to play all music in the bank. Untitled

RealNobser commented 5 days ago

If this one is part of the MarcDuino standard, I will implement it. Will reopen that issue and check soon.

RealNobser commented 4 days ago

Official MarcDuino code:

/////////////COMMAND VOCABULARY///////////
// Play sound command by bank/sound numbers
// $xyy
// x=bank number
// yy=sound number. If none, next sound is played in the bank
//

So $x ist allowed, but does not play random, but next sound. Nevertheless Betterduino does not support that, yet.

stewartgill1977 commented 4 days ago

I got it by using this code so now plays random

image