FreeCalypso > hg > fc-magnetite
diff src/cs/drivers/drv_app/pwr/pwr_liion_cha.c @ 146:fb95e3f83dc5
imported PWR source: s/ANALOG/ANLG_FAM/ for TCS211 environment
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Sun, 09 Oct 2016 06:06:04 +0000 |
parents | 246f4a7dd92b |
children | c93a236e0d50 |
line wrap: on
line diff
--- a/src/cs/drivers/drv_app/pwr/pwr_liion_cha.c Sun Oct 09 05:59:14 2016 +0000 +++ b/src/cs/drivers/drv_app/pwr/pwr_liion_cha.c Sun Oct 09 06:06:04 2016 +0000 @@ -168,9 +168,9 @@ pwr_send_charge_not_possible_event(BAT_TEMP_OUTSIDE_LIMITS); if (SPI_GBL_INFO_PTR->is_gsm_on == FALSE) /* GSM OFF */ { -#if (ANALOG == 1) +#if (ANLG_FAM == 1) ABB_Write_Register_on_page(PAGE0, VRPCCTL2, 0x00EE); -#elif (ANALOG == 2) +#elif (ANLG_FAM == 2) ABB_Write_Register_on_page(PAGE0, VRPCDEV, 0x0001); #endif } @@ -300,9 +300,9 @@ pwr_send_charge_not_possible_event(BAT_SHORT_TEST_FAILED); if (SPI_GBL_INFO_PTR->is_gsm_on == FALSE) /* GSM OFF */ { -#if (ANALOG == 1) +#if (ANLG_FAM == 1) ABB_Write_Register_on_page(PAGE0, VRPCCTL2, 0x00EE); -#elif (ANALOG == 2) +#elif (ANLG_FAM == 2) ABB_Write_Register_on_page(PAGE0, VRPCDEV, 0x0001); #endif } @@ -352,9 +352,9 @@ pwr_send_charge_not_possible_event(BAT_OPEN_TEST_FAILED); if (SPI_GBL_INFO_PTR->is_gsm_on == FALSE) /* GSM OFF */ { -#if (ANALOG == 1) +#if (ANLG_FAM == 1) ABB_Write_Register_on_page(PAGE0, VRPCCTL2, 0x00EE); -#elif (ANALOG == 2) +#elif (ANLG_FAM == 2) ABB_Write_Register_on_page(PAGE0, VRPCDEV, 0x0001); #endif } @@ -384,7 +384,7 @@ rvf_send_trace("i2v offset (MADC code) ", 23, pwr_env_ctrl_blk->i2v_madc_offset, RV_TRACE_LEVEL_DEBUG_LOW, PWR_USE_ID); pwr_stop_charging(); -#if (ANALOG == 2) +#if (ANLG_FAM == 2) if (pwr_env_ctrl_blk->i2v_madc_offset == 0) { /* IOTA: the offset can be made positive and minimized programming */ @@ -403,7 +403,7 @@ pwr_start_fast_charge(); } -#elif (ANALOG == 1) +#elif (ANLG_FAM == 1) /* the i2v calibration must be done before this initialization */ pwr_env_ctrl_blk->madc_eoc_current_code = (UINT16)(1000 * END_OF_CHARGE_I / MADC_CURRENT_STEP) + pwr_env_ctrl_blk->i2v_madc_offset; @@ -412,7 +412,7 @@ /* Start the fast charging cycle */ pwr_start_fast_charge(); -#endif /* #if (ANALOG == 2) */ +#endif /* #if (ANLG_FAM == 2) */ } @@ -487,9 +487,9 @@ if (SPI_GBL_INFO_PTR->is_gsm_on == FALSE) /* GSM OFF */ { -#if (ANALOG == 1) +#if (ANLG_FAM == 1) ABB_Write_Register_on_page(PAGE0, VRPCCTL2, 0x00EE); -#elif (ANALOG == 2) +#elif (ANLG_FAM == 2) ABB_Write_Register_on_page(PAGE0, VRPCDEV, 0x0001); #endif } @@ -589,9 +589,9 @@ if (SPI_GBL_INFO_PTR->is_gsm_on == FALSE) /* GSM OFF */ { -#if (ANALOG == 1) +#if (ANLG_FAM == 1) ABB_Write_Register_on_page(PAGE0, VRPCCTL2, 0x00EE); -#elif (ANALOG == 2) +#elif (ANLG_FAM == 2) ABB_Write_Register_on_page(PAGE0, VRPCDEV, 0x0001); #endif } @@ -612,9 +612,9 @@ if (SPI_GBL_INFO_PTR->is_gsm_on == FALSE) /* GSM OFF */ { -#if (ANALOG == 1) +#if (ANLG_FAM == 1) ABB_Write_Register_on_page(PAGE0, VRPCCTL2, 0x00EE); -#elif (ANALOG == 2) +#elif (ANLG_FAM == 2) ABB_Write_Register_on_page(PAGE0, VRPCDEV, 0x0001); #endif }