# HG changeset patch # User Mychaela Falconia # Date 1446363446 0 # Node ID ae647d795c804446e83d3f5c3ec8fe1aef603b46 # Parent d45509318f200544cecf7faba91bfb1ff85f4f47 armio.c: same minimal config as OsmocomBB and FreeCalypso for now diff -r d45509318f20 -r ae647d795c80 chipsetsw/drivers/drv_core/armio/armio.c --- a/chipsetsw/drivers/drv_core/armio/armio.c Sun Nov 01 07:03:53 2015 +0000 +++ b/chipsetsw/drivers/drv_core/armio/armio.c Sun Nov 01 07:37:26 2015 +0000 @@ -231,81 +231,13 @@ // reset the IOs config AI_ResetIoConfig(); - // CLKM_IO_CNTL register configuration : - // select IOs 6,8,9,10,11,12 and 13 on the pins instead of MCSI and MCUEN signals. - #if (CHIPSET != 12) - AI_EnableBit(2); - AI_EnableBit(4); - #endif - - /* Bits 5,6,7,8 are used to output I/O 9,10,11,12 or MCSI pins */ - /* If Bluetooth, IO should be disabled, outputting MCSI used for Bluetooth voice */ -#ifdef BTEMOBILE - #if (CHIPSET != 12) - AI_DisableBit(5); - AI_DisableBit(6); - AI_DisableBit(7); - AI_DisableBit(8); - #endif -#else - #if (CHIPSET != 12) - AI_EnableBit(5); - AI_EnableBit(6); - AI_EnableBit(7); - AI_EnableBit(8); -#endif -#endif - - #if (CHIPSET != 12) - AI_EnableBit(9); - #endif + /* same minimal config as OsmocomBB and FreeCalypso for now */ - // ARMIO_OUT register configuration : - // set IOs 8,9,10,11,12 and 13 as high - // set IOs 0 to 7 as low - #if ((BOARD == 8) || (BOARD == 9)) - *((volatile SYS_UWORD16 *) ARMIO_OUT) = 0x3F00; - - // ARMIO_CNTL_REG register configuration : - // set IOs 0,1,6,8,9,10,11,12 and 13 as ouputs. - AI_ConfigBitAsOutput(0); - AI_ConfigBitAsOutput(1); - AI_ConfigBitAsOutput(6); - AI_ConfigBitAsOutput(8); - AI_ConfigBitAsOutput(9); - AI_ConfigBitAsOutput(10); - AI_ConfigBitAsOutput(11); - AI_ConfigBitAsOutput(12); - AI_ConfigBitAsOutput(13); - #elif ((BOARD == 40) || (BOARD == 41) || (BOARD == 42) || (BOARD == 43) || (BOARD == 45)) - // set IOs 1 and 8 to 13 as high - // set IOs 0 and 2 to 7 as low - // On D-Sample GPIO 1 must be set to high to enable the audio amplifier. - #if (OP_L1_STANDALONE == 0) -// CC test -#if 1 // Dmitriy: GPIO 1 is the interrupt for the ext host, set it to 0 - *((volatile SYS_UWORD16 *) ARMIO_OUT) = 0x3F00; -#else - *((volatile SYS_UWORD16 *) ARMIO_OUT) = 0x3F02; -#endif - //*((volatile SYS_UWORD16 *) ARMIO_OUT) = 0x3F01; -// end - #else - *((volatile SYS_UWORD16 *) ARMIO_OUT) = 0x3F01; - #endif - - // ARMIO_CNTL_REG register configuration : - // set IOs 1,2,5,7,9,14 and 15 as ouputs. -// CC test 0316 - AI_ConfigBitAsOutput(1); -// end - AI_ConfigBitAsOutput(2); - AI_ConfigBitAsOutput(5); - AI_ConfigBitAsOutput(7); - AI_ConfigBitAsOutput(9); - AI_ConfigBitAsOutput(14); - AI_ConfigBitAsOutput(15); - #endif + /* GPIO out all zeros */ + *((volatile SYS_UWORD16 *) ARMIO_OUT) = 0x0000; + /* make GPIOs 1 and 3 outputs */ + AI_ConfigBitAsOutput(1); + AI_ConfigBitAsOutput(3); } /*