TWL3025: add default APC ramp
authorHarald Welte <laforge@gnumonks.org>
Sun, 21 Feb 2010 10:32:40 +0000 (11:32 +0100)
committerHarald Welte <laforge@gnumonks.org>
Mon, 1 Mar 2010 22:48:44 +0000 (23:48 +0100)
src/target/firmware/abb/twl3025.c
src/target/firmware/include/abb/twl3025.h

index b9c5569..5138e75 100644 (file)
 #define TWL3025_DEV_IDX                0       /* On the SPI bus */
 #define TWL3025_TSP_DEV_IDX    0       /* On the TSP bus */
 
+/* values encountered on a GTA-02 for GSM900 (the same for GSM1800!?) */
+const uint16_t twl3025_default_ramp[16] = {
+       ABB_RAMP_VAL( 0,  0),
+       ABB_RAMP_VAL( 0, 11),
+       ABB_RAMP_VAL( 0, 31),
+       ABB_RAMP_VAL( 0, 31),
+       ABB_RAMP_VAL( 0, 31),
+       ABB_RAMP_VAL( 0, 24),
+       ABB_RAMP_VAL( 0,  0),
+       ABB_RAMP_VAL( 0,  0),
+       ABB_RAMP_VAL( 9,  0),
+       ABB_RAMP_VAL(18,  0),
+       ABB_RAMP_VAL(25,  0),
+       ABB_RAMP_VAL(31,  0),
+       ABB_RAMP_VAL(30,  0),
+       ABB_RAMP_VAL(15,  0),
+       ABB_RAMP_VAL( 0,  0),
+       ABB_RAMP_VAL( 0,  0),
+};
+
 struct twl3025 {
        uint8_t page;
 };
index 8ccbf19..2cd35a5 100644 (file)
@@ -110,6 +110,8 @@ enum twl3025_tsp_bits {
        STARTADC        = 0x02,
 };
 
+extern const uint16_t twl3025_default_ramp[16];
+
 /* Enqueue a TSP signal change via the TPU */
 void twl3025_tsp_write(uint8_t data);