From: Keith Packard Date: Mon, 25 Mar 2013 06:52:14 +0000 (-0700) Subject: altos/telegps: Hook up cc115l driver X-Git-Tag: altosdroid_v1.2-1~83 X-Git-Url: https://git.gag.com/?p=fw%2Faltos;a=commitdiff_plain;h=6fe1e32f5361e901b88b63a30f070e67d460ada1 altos/telegps: Hook up cc115l driver Doesn't actually do anything yet, but should initialize the chip at least Signed-off-by: Keith Packard --- diff --git a/src/telegps-v0.1/Makefile b/src/telegps-v0.1/Makefile index 48caee4d..26d9eaa0 100644 --- a/src/telegps-v0.1/Makefile +++ b/src/telegps-v0.1/Makefile @@ -13,6 +13,8 @@ INC = \ ao_product.h \ ao_task.h \ ao_whiten.h \ + ao_cc115l.h \ + ao_fec.h \ stm32l.h \ Makefile @@ -44,7 +46,9 @@ ALTOS_SRC = \ ao_usb_stm.c \ ao_exti_stm.c \ ao_serial_stm.c \ - ao_gps_skytraq.c + ao_gps_skytraq.c \ + ao_cc115l.c \ + ao_fec_tx.c PRODUCT=TeleGPS-v0.1 PRODUCT_DEF=-DTELEGPS diff --git a/src/telegps-v0.1/ao_pins.h b/src/telegps-v0.1/ao_pins.h index 77b2373d..46d0b9f2 100644 --- a/src/telegps-v0.1/ao_pins.h +++ b/src/telegps-v0.1/ao_pins.h @@ -122,37 +122,30 @@ #define AO_MONITOR_LED AO_LED_GREEN /* - * Radio (cc115) + * Radio (cc115l) */ /* gets pretty close to 434.550 */ -#define AO_RADIO_CAL_DEFAULT 0x6ca333 +#define AO_RADIO_CAL_DEFAULT 0x10b6a5 #define AO_FEC_DEBUG 0 -#define AO_CC1120_SPI_CS_PORT (&stm_gpioa) -#define AO_CC1120_SPI_CS_PIN 0 -#define AO_CC1120_SPI_BUS AO_SPI_2_PB13_PB14_PB15 -#define AO_CC1120_SPI stm_spi2 +#define AO_CC115L_SPI_CS_PORT (&stm_gpiob) +#define AO_CC115L_SPI_CS_PIN 12 +#define AO_CC115L_SPI_BUS AO_SPI_2_PB13_PB14_PB15 +#define AO_CC115L_SPI stm_spi2 -#define AO_CC1120_INT_PORT (&stm_gpioc) -#define AO_CC1120_INT_PIN 13 +#define AO_CC115L_INT_PORT (&stm_gpioa) +#define AO_CC115L_INT_PIN (9) -#define AO_CC1120_MCU_WAKEUP_PORT (&stm_gpioc) -#define AO_CC1120_MCU_WAKEUP_PIN (0) +#define AO_CC115L_MCU_WAKEUP_PORT (&stm_gpioa) +#define AO_CC115L_MCU_WAKEUP_PIN (10) -#define AO_CC1120_INT_GPIO 2 -#define AO_CC1120_INT_GPIO_IOCFG CC1120_IOCFG2 +#define AO_CC115L_INT_GPIO 2 +#define AO_CC115L_INT_GPIO_IOCFG CC115L_IOCFG2 -#define AO_CC1120_MARC_GPIO 3 -#define AO_CC1120_MARC_GPIO_IOCFG CC1120_IOCFG3 +#define AO_CC115L_MARC_GPIO 0 +#define AO_CC115L_MARC_GPIO_IOCFG CC115L_IOCFG0 -/* - * Profiling Viterbi decoding - */ - -#ifndef AO_PROFILE -#define AO_PROFILE 0 -#endif #endif /* _AO_PINS_H_ */ diff --git a/src/telegps-v0.1/ao_telegps.c b/src/telegps-v0.1/ao_telegps.c index 9865674d..fdf365e3 100644 --- a/src/telegps-v0.1/ao_telegps.c +++ b/src/telegps-v0.1/ao_telegps.c @@ -41,11 +41,7 @@ main(void) ao_cmd_init(); ao_usb_init(); -// ao_radio_init(); -// ao_monitor_init(); -// ao_rssi_init(AO_LED_RED); -// ao_packet_master_init(); -// ao_send_packet_init(); + ao_radio_init(); ao_gps_init();