After ADC function and POWER_SAVING enabled simultaneous, all signal not coming
>base on SimpleBLEPeripheral sampled code, enable POWER_SAVING and put LED toggle function in periodic event loop and LED can blinking
>follow example https://e2e.ti.com/support/wireless_connectivity/bluetooth_low_energy/f/538/t/404426
and porting ADC init code to SimpleBLEPeripheral_init(), the signal not coming anymore
//------------------------------------------------------------------------------------
static void SimpleBLEPeripheral_init(void)
{
...
// Create one-shot clocks for internal periodic events.
Util_constructClock(&periodicClock, SimpleBLEPeripheral_clockHandler,
SBP_PERIODIC_EVT_PERIOD, SBP_PERIODIC_EVT_PERIOD, true, SBP_PERIODIC_EVT);
...
hGpioPin = PIN_open(&pinGpioState, BoardGpioInitTable);
...
//------Init ------
Hwi_Params hwiParams;
Hwi_Params_init(&hwiParams);
hwiParams.enableInt = true;
Hwi_construct(&hwi, INT_AUX_ADC, adcIsr, &hwiParams, NULL);
// Enable clock for ADC digital and analog interface (not currently enabled in driver)
AUXWUCClockEnable(AUX_WUC_MODCLKEN0_ANAIF_M|AUX_WUC_MODCLKEN0_AUX_ADI4_M);
// Connect AUX IO7 (DIO5) as analog input.
AUXADCSelectInput(ADC_COMPB_IN_AUXIO7);
// Set up ADC
AUXADCEnableSync(AUXADC_REF_FIXED, AUXADC_SAMPLE_TIME_2P7_US, AUXADC_TRIGGER_MANUAL);
//------------
}
static void SimpleBLEPeripheral_taskFxn(UArg a0, UArg a1)
{
SimpleBLEPeripheral_init();
// Application main loop
for (;;)
{
...
ICall_Errno errno = ICall_wait(ICALL_TIMEOUT_FOREVER);
LED_Toggle(Board_LED_ORANGE);
...
if (events & SBP_PERIODIC_EVT)
{
events &= ~SBP_PERIODIC_EVT;
Util_startClock(&periodicClock);
// Perform periodic application task
SimpleBLEPeripheral_performPeriodicTask();
LED_Toggle(Board_LED_GREEN);
}
...
}