changeset 666:711b1c6c4e72

LPG and PWL config for D-Sample and GTM900 targets
author Mychaela Falconia <falcon@freecalypso.org>
date Wed, 27 May 2020 23:19:42 +0000
parents 2795a11973b8
children 36df58db1640
files src/cs/system/main/init.c targets/dsample.h targets/gtm900mgc.h
diffstat 3 files changed, 10 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/cs/system/main/init.c	Wed May 27 22:46:55 2020 +0000
+++ b/src/cs/system/main/init.c	Wed May 27 23:19:42 2020 +0000
@@ -354,12 +354,17 @@
         #else
           #if (BOARD==35)
             *((volatile SYS_UWORD16 *) ASIC_CONF) = 0x2000;
-          #elif defined(CONFIG_TARGET_PIRELLI)
+          #elif defined(CONFIG_TARGET_PIRELLI) || defined(CONFIG_TARGET_DSAMPLE)
             /*
              * Pirelli's version of this Init_Target() function
              * in their fw sets the ASIC_CONF register to 0x6050,
              * which means PWL on the LT/PWL pin and LPG on the
              * DSR_MODEM pin.
+             *
+             * Also as a bold FreeCalypso change, we now set the same
+             * PWL and LPG pin configs on the D-Sample: the DS board
+             * has LEDs for PWL and for LPG and they work as expected,
+             * thus the board is clearly wired for this pin config.
              */
             *((volatile SYS_UWORD16 *) ASIC_CONF) = 0x6050;
           #elif defined(CONFIG_TARGET_GTAMODEM) || defined(CONFIG_TARGET_GTM900)
@@ -373,6 +378,7 @@
              */
             *((volatile SYS_UWORD16 *) ASIC_CONF) = 0x6040;
           #else
+            /* TI's original firmware setting */
             *((volatile SYS_UWORD16 *) ASIC_CONF) = 0x6000;
           #endif   /* (BOARD == 35) */
         #endif
--- a/targets/dsample.h	Wed May 27 22:46:55 2020 +0000
+++ b/targets/dsample.h	Wed May 27 23:19:42 2020 +0000
@@ -1,3 +1,5 @@
 #define	CONFIG_TARGET_DSAMPLE	1
 #define	GPIO1_SPEAKER_CTRL	1
 #define	UARTFAX_CLASSIC_DTR_DCD	1
+#define	TARGET_HAS_LPG		1
+#define	TARGET_HAS_PWL		1
--- a/targets/gtm900mgc.h	Wed May 27 22:46:55 2020 +0000
+++ b/targets/gtm900mgc.h	Wed May 27 23:19:42 2020 +0000
@@ -2,3 +2,4 @@
 #define	CONFIG_TARGET_MGC2GSMT	1
 #define	GPIO1_SPEAKER_CTRL	0
 #define	UARTFAX_CLASSIC_DTR_DCD	1
+#define	TARGET_HAS_LPG		1