Power off

Designing hardware and software for systems that use the VS1010 MP3 Audio DSP Microcontroller.
Post Reply
Senior User
Posts: 264
Joined: Mon 2016-05-30 11:54

Power off

Post by Hannu »


Here is something which shuts down VS1010 developer board.

My test method:
Powered through USB connector and UART cable.
  1. write "poweroff" to console
  2. press the PWR button down
  3. Send the last enter to start the program
  4. Disconnect UART cable
  5. Release PWR button
  6. No oscillation on oscilloscope in XTALI pin, or voltages on regulator capacitors
The UART cable feeds back to IOVDD and that's why the LED2 glows dimly. That's why it was disconnected.
Power off program for VS1010
(30.41 KiB) Downloaded 89 times
Posts: 9
Joined: Thu 2021-05-27 17:23

Re: Power off

Post by manuel_k »


i tried the power off, but its not working as expected. Is there anything what can be done wrong?

I working with the developer board. It power consumption is 26mA before pressing power button. If started it´s between 70mA and 90mA while playing files. After doing the power off steps its 55mA, Measuring IOVDD is between 2.2V and 1.2V.

I also use VS1010 with my own design in QFP Package on two other boards and have the same behavior.

I plan to use it with a battery, so power must be as low as possible while in "standby". With IOVDD on 1.2 my LDO for the SD card is still on and the SD card power consumption is quite high.
Senior User
Posts: 264
Joined: Mon 2016-05-30 11:54

Re: Power off

Post by Hannu »

Oh that power off. There is a better one: viewtopic.php?f=15&t=2736&p=14008#p14008

Something is leaking to IOVDD. First suspect: SD card regulator. Run power off and plug card out. On devboard the GPIO0_8 could be driven low. Adding GpioSetPin(0x08, 0) should shutdown down the regulator. adding that line to PowerOff() function and maybe some delay.

Also JP3 should be disconnected if it is connected. The power amplifier regulator isn't controllable.

For the linked power program, I have this PowerOff function. and after that the current goes to some uA . These things require some tweaking always as different devices, capacitor values keep the system in some brown out state.

Code: Select all

void PowerOff(void) {

	struct {
		s_int16 core;
		s_int16 io;
		s_int16 analog;
	} regulatorLowPower = {10, 3, 1};

	printf("Wait PWRBTN release\n");
	while (ReadPowerButton());
	GpioSetPin(PIN_SD_REG, 0);
	printf("%s gpio\n", "Stop");
	GpioUnfloat(0, 0x2f);
	GpioSetPin(PIN_MCLK, 0);

	printf("Low voltages\n");

	// Go to 1X clock

	//Disable SPI1 TV-Out // disable tvout
	PERIP(INT_ENABLE0_LP) &= ~(INTF_SPI1); //Disable TV interrupt
	PERIP(INT_ENABLE0_HP) &= ~(INTF_SPI1); //Disable TV interrupt
	lcd0.clipy2 = 0; 	// Disable tv buffer and tv-out
	SetJmpiHookFunction((void*)102,VoidVoid);  //102=ScreenOutputFunction

	// Set low voltages
	printf("%s peripherals\n", "Stop");

	// Peripherals off
	PERIP(I2S_CF) = 0;
	PERIP(ANA_CF0) = 0;
	PERIP(ANA_CF1) = 0;
	PERIP(ANA_CF2) = 0;
	PERIP(ANA_CF3) = 0;

	printf("%s regulator\n", "Stop");

	// Regulators off
	PERIP(REGU_CF) = 0x17; // All off
	PERIP(REGU_CF) |=  REGU_CF_REGCK;    /* clk up */
	PERIP(REGU_CF) &= ~REGU_CF_REGCK;    /* clk down */

	DelayL(100000); // Power will finally die during this loop.
Posts: 9
Joined: Thu 2021-05-27 17:23

Re: Power off

Post by manuel_k »

Thanks, driving the pin low works on the dev board and i was able to patch my own boards in a similiar way. Seems there was some kind of voltage lock caused by sd card.
Post Reply