ΣSigmaStudio Ask AI Русский Log in

Change input/output signal by push button

SigmaDSP & SigmaStudio DaNhanCach Jun 13, 2024 00:00 4 replies Original on forum ↗
Subscribe
DaNhanCach Question
Jun 13, 2024 00:00

Hi Everyone,

Can use a push button that when pressed and released will change the input signal, and when pressed and held for about 3 seconds will change the output signal.

Thank!!

Audio Signal Processors

hardware

adau1401

button

SigmaDSP Audio Processors

Harishgowtham Reply
Jun 13, 2024 00:00

Hello DaNhanCach,

Please try the attached project. You have to do some work though. Since I have the sigma350 core in my desk, I made the project for sigma3xx processors. However, I made this project by only using the blocks which are available on ADAU1401, I avoided using shifter like blocks which is not available and needs additional logics to implement shifting operations in sigma200 core.

So, you have to change to 28.0 format wherever I used 32.0.

I quickly prepared this project, just change the settings to get the correct hold time. I believe it will give you an idea, but I haven't tested this completely due to time constraints, maybe I will update it tomorrow if anything is needed.

This was working perfectly with sigma3xx core since it has a pulse counter with interval block. (sigma300 core users can use this)

Change input output signal by push button v2.dspproj

Please copy this project for your ADAU1401.

Any other ideas from forum users/experts are always welcome.

pastedimage1718285839995v1.png
pastedimage1718285839995v1.png
pastedimage1718286024724v2.png
pastedimage1718286024724v2.png
DaNhanCach Reply
Jun 13, 2024 00:00

Thank you for your interest in my question. I saw your project. it's still not what I want. I want when the output changes the input should not change.

DaNhanCach Reply
Jun 14, 2024 00:00

I edited it but it looks too complicated. Hope someone has a simpler idea.

Assign 2 functions to one push button.dspproj

Screenshot-2024-06-14-195053.png
Screenshot-2024-06-14-195053.png
KJBob Reply
Jun 14, 2024 00:00

Hello,

My attempt to simplify this application saves a few instructions by eliminating the Divide block. It runs on a ADAU1701MINIZ board, which has its middle button wired to MP3. Since the button grounds MP3 when pressed, I inverted MP3 in the Register settings. A short button press (between 0.5 -- 2 seconds) switches between two tones, a longer press moves the sound between left and right channels. Any change occurs when the button is released:

Short-Long.dspproj

Best regards,

Bob

Short-Long_sch.png
Short-Long_sch.png