kopia lustrzana https://github.com/OpenRTX/OpenRTX
Module17: implemented control of power on switch, introduced in rev 0.1e
rodzic
5c3e8fed80
commit
beca0ea093
|
@ -73,6 +73,7 @@
|
|||
#define MIC_GAIN GPIOC,5
|
||||
|
||||
#define AIN_HWVER GPIOA,3
|
||||
#define POWER_SW GPIOA,15
|
||||
|
||||
/* I2C for MCP4551 */
|
||||
#define I2C_SDA GPIOB,7
|
||||
|
|
|
@ -37,6 +37,9 @@ static hwInfo_t hwInfo;
|
|||
|
||||
void platform_init()
|
||||
{
|
||||
gpio_setMode(POWER_SW, OUTPUT);
|
||||
gpio_setPin(POWER_SW);
|
||||
|
||||
/* Configure GPIOs */
|
||||
gpio_setMode(PTT_LED, OUTPUT);
|
||||
gpio_setMode(SYNC_LED, OUTPUT);
|
||||
|
@ -90,6 +93,8 @@ void platform_terminate()
|
|||
adc1_terminate();
|
||||
nvm_terminate();
|
||||
audio_terminate();
|
||||
|
||||
gpio_clearPin(POWER_SW);
|
||||
}
|
||||
|
||||
uint16_t platform_getVbat()
|
||||
|
|
Ładowanie…
Reference in New Issue