# PMi_GetSoundPower

## C Specification

      #include <nitro/spi.h>

      u32 PMi_GetSoundPower( PMSoundPowerSwitch* swBuf );

## Description

This function gets the current settings of the sound unit power switch.

The `PMSoundPowerSwitch` enumerator type value is stored in the `swBuf` argument. The `swBuf` argument can contain either one of the following values:

`PM_SOUND_POWER_OFF` | Turns the sound unit power OFF.
`PM_SOUND_POWER_ON` | Turns the sound unit power ON.

This function uses PXI to send the command that performs the corresponding operation in the ARM7 processor. The ARM7 side that receives that command is executed by operating the PMIC. Therefore, this function may not operate promptly after you call it.

Before you use this function, initialize the PM library by using the `PM_Init()` function. The `PM_Init()` function has to be called only once.

The `OS_Init()` function is called from within the `PM_Init()` function. If you need to call the `OS_Init()` function, you have to call the `PM_Init()` function only once. There is no need for the `OS_Init()` function to be called separately.

## Internal Operation

This function reads the PMIC_CTL value of the PMIC register.

## Arguments

`swBuf` | the buffer that stores the obtained results of sound unit power switch

## Return Values

The `PM_RESULT_SUCCESS` return value indicates that the execution of the command has succeeded.

The `PM_RESULT_ERROR` return value indicates that an error has occurred with the ARM7 processor.

## See Also

`PM_Init`, `PMi_SetSoundPower*`

## Revision History

08/09/2004 Initial version