0

alternate playing audio clips

I would like to play two different audio clips using a single GPIO input. I want the audio clips to alternate - press GPIO1 audio clip 1 plays then stops, press GPIO1 again and audio clip 2 plays then stops, next GPIO1 trigger goes back to audio clip 1.

Any suggestions on how I can do this?

Thanks,

David

1 comment

  • 1
    Avatar
    David

    Yuriy solved this for me in support and I thought I would post it here so it might help someone else...

     

    Yes, this is possible. An example presentation made in BrightAuthor 4.4.0.15 is attached below - please take a look on how it can be performed. 
    Event Handlers ensure that the file is going to be played once, without looping it. GPIO inputs are placed to cycle your audio files both after and during playback. 
    The button set on default in this presentation is GPIO0 buy you can set any other button to do the trick.

    Thank you,

    Yuriy S.

Please sign in to leave a comment.