I have a working circuit that generates a signal (a range of slow and fast tones) and sends them to a speaker. I tried to switch to a piezo driver and speaker and was successful using the MAX9788 as the driver, however I was unable to make it loud enough.
The MAX9788 requires 2.7V to 5.5V. If I supply it with 5V from a power supply and use a regular speaker then I am able to create the desired volume during which the power supply reads between 250mA to 850mA depending on the speed of the tone, i.e. steady and slow to very fast.
My problem comes from when I supply my circuit with a 9V battery and use a linear DC-DC regulator to send 5V to the MAX9788 (I am using a L7805). I am able to hear the slower tones but at a much lower volume and never the faster ones. I have been able to increase the volume using a voltage follower with a darlington pair, my current during this time has never exceeded 50mA.
I believe my mistake was using a linear DC-DC regulator and my next step is to use a buck convertor to hopefully get more current to the MAX9788.
TLDR - my systems works if I supply the MAX9788 with a power supply but not with a 9V.
My question is will this work? is there a better way to see the current I need on the driver using a 9V battery?