[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[paparazzi-commits] [6275] removing obsolete files
From: |
antoine drouin |
Subject: |
[paparazzi-commits] [6275] removing obsolete files |
Date: |
Wed, 27 Oct 2010 08:16:08 +0000 |
Revision: 6275
http://svn.sv.gnu.org/viewvc/?view=rev&root=paparazzi&revision=6275
Author: poine
Date: 2010-10-27 08:16:07 +0000 (Wed, 27 Oct 2010)
Log Message:
-----------
removing obsolete files
Removed Paths:
-------------
paparazzi3/trunk/sw/airborne/pt_ant_estimator.c
paparazzi3/trunk/sw/airborne/pt_ant_estimator.h
paparazzi3/trunk/sw/airborne/pt_ant_sensors.c
paparazzi3/trunk/sw/airborne/pt_ant_sensors.h
Deleted: paparazzi3/trunk/sw/airborne/pt_ant_estimator.c
===================================================================
--- paparazzi3/trunk/sw/airborne/pt_ant_estimator.c 2010-10-26 18:03:28 UTC
(rev 6274)
+++ paparazzi3/trunk/sw/airborne/pt_ant_estimator.c 2010-10-27 08:16:07 UTC
(rev 6275)
@@ -1,23 +0,0 @@
-#include "pt_ant_estimator.h"
-
-struct PtAntEstimatorState pt_ant_estimator_state;
-
-void pt_ant_estimator_update_target(uint8_t id, struct ac_info_ *ac) {
- pt_ant_estimator_state.target_east = ac->east;
- pt_ant_estimator_state.target_north = ac->north;
- pt_ant_estimator_state.target_alt = ac->alt;
-}
-
-void pt_ant_estimator_update_self_attitude(struct PtAntSensorData* data) {
- pt_ant_estimator_state.self_phi = atan2(data->accel_y, data->accel_z);
- float g2 = data->accel_x * data->accel_x +
- data->accel_y * data->accel_y +
- data->accel_z * data->accel_z;
- pt_ant_estimator_state.self_theta = -asin(data->accel_x / sqrt(g2));
-
-}
-
-void pt_ant_estimator_update_self_gps(void) {
-
-
-}
Deleted: paparazzi3/trunk/sw/airborne/pt_ant_estimator.h
===================================================================
--- paparazzi3/trunk/sw/airborne/pt_ant_estimator.h 2010-10-26 18:03:28 UTC
(rev 6274)
+++ paparazzi3/trunk/sw/airborne/pt_ant_estimator.h 2010-10-27 08:16:07 UTC
(rev 6275)
@@ -1,32 +0,0 @@
-#ifndef PT_ANT_ESTIMATOR_H
-#define PT_ANT_ESTIMATOR_H
-
-#include "std.h"
-#include "traffic_info.h"
-#include "pt_ant_sensors.h"
-
-
-struct PtAntEstimatorState {
-
- float self_phi;
- float self_theta;
- float self_psi;
-
- float self_east;
- float self_north;
- float self_alt;
-
- float target_east;
- float target_north;
- float target_alt;
-
-};
-
-extern struct PtAntEstimatorState pt_ant_estimator_state;
-
-extern void pt_ant_estimator_update_target(uint8_t id, struct ac_info_ *ac);
-extern void pt_ant_estimator_update_self_gps(void);
-extern void pt_ant_estimator_update_self_attitude(struct PtAntSensorData*
data);
-
-
-#endif /* PT_ANT_ESTIMATOR_H */
Deleted: paparazzi3/trunk/sw/airborne/pt_ant_sensors.c
===================================================================
--- paparazzi3/trunk/sw/airborne/pt_ant_sensors.c 2010-10-26 18:03:28 UTC
(rev 6274)
+++ paparazzi3/trunk/sw/airborne/pt_ant_sensors.c 2010-10-27 08:16:07 UTC
(rev 6275)
@@ -1,98 +0,0 @@
-#include "pt_ant_sensors.h"
-
-#include "LPC21xx.h"
-#include "armVIC.h"
-
-void SPI0_ISR(void) __attribute__((naked));
-#define S0SPCR_SPIE 7 /* SPI enable */
-#define PT_ANT_SENSOR_SS_PIN 3
-#define PtAntSensorsSelect() { SetBit(IO0SET, PT_ANT_SENSOR_SS_PIN);}
-#define PtAntSensorsUnselect() { SetBit(IO0CLR, PT_ANT_SENSOR_SS_PIN);}
-
-/* set SPI0 clock, PCLK / SPCCR0 = 468.75kHz */
-
-#if (PCLK == 15000000)
-#define SPCCR0 32
-#else
-
-#if (PCLK == 30000000)
-#define SPCCR0 64
-#else
-
-#if (PCLK == 60000000)
-#define SPCCR0 128
-#else
-
-#error unknown PCLK frequency
-#endif
-#endif
-#endif
-
-
-volatile uint8_t pt_ant_sensors_data_available;
-struct PtAntSensorData pt_ant_sensors_data;
-
-volatile uint8_t pt_ant_sensors_buffer_idx;
-uint8_t* pt_ant_sensors_buffer = (uint8_t*)&pt_ant_sensors_data;
-
-void pt_ant_sensors_init(void) {
- pt_ant_sensors_data_available = FALSE;
-
-}
-
-
-void pt_ant_sensors_read(void) {
- PtAntSensorsSelect();
- pt_ant_sensors_buffer_idx = 0;
- S0SPDR = 0xAA;
-}
-
-
-
-
-void pt_ant_sensors_init_spi(void) {
- /* init SPI0 */
- /* setup pins function for sck, miso, mosi */
- PINSEL0 |= 1<<8 | 1<<10| 1<<12;
- /* setup ssel as output */
- IO0DIR |= 1<<PT_ANT_SENSOR_SS_PIN;
- /* unselect sensor */
- PtAntSensorsUnselect();
- /* configure SPI : 8 bits CPOL=0 CPHA=0 MSB_first master */
- S0SPCR = 1<<5;
- /* setup SPI clock rate : PCLK / SPCCR0 = 468.75kHz */
- S0SPCCR = SPCCR0;
-
- /* initialize interrupt vector */
- VICIntSelect &= ~VIC_BIT(VIC_SPI0); // SPI0 selected as IRQ
- VICIntEnable = VIC_BIT(VIC_SPI0); // SPI0 interrupt enabled
- VICVectCntl10 = VIC_ENABLE | VIC_SPI0;
- VICVectAddr10 = (uint32_t)SPI0_ISR; // address of the ISR
-
- /* clear pending interrupt */
- SetBit(S0SPINT, SPI0IF);
- /* enable SPI interrupt */
- SetBit(S0SPCR, S0SPCR_SPIE);
-}
-
-
-void SPI0_ISR(void) {
- ISR_ENTRY();
- /* FIXME : do something usefull with the status register reading */ \
- uint8_t foo __attribute__((unused)) = S0SPSR;
\
- pt_ant_sensors_buffer[pt_ant_sensors_buffer_idx] = S0SPDR;
- pt_ant_sensors_buffer_idx++;
- if (pt_ant_sensors_buffer_idx < sizeof(pt_ant_sensors_data)) {
- S0SPDR = 0xAA;
- }
- else {
- PtAntSensorsUnselect();
- pt_ant_sensors_data_available = TRUE;
- }
-
- /* clear the interrupt */
- S0SPINT = _BV(SPI0IF);
- /* clear this interrupt from the VIC */
- VICVectAddr = 0x00000000;
- ISR_EXIT();
-}
Deleted: paparazzi3/trunk/sw/airborne/pt_ant_sensors.h
===================================================================
--- paparazzi3/trunk/sw/airborne/pt_ant_sensors.h 2010-10-26 18:03:28 UTC
(rev 6274)
+++ paparazzi3/trunk/sw/airborne/pt_ant_sensors.h 2010-10-27 08:16:07 UTC
(rev 6275)
@@ -1,42 +0,0 @@
-#ifndef PT_ANT_SENSORS_H
-#define PT_ANT_SENSORS_H
-
-#include "std.h"
-
-#if 0
-struct PtAntSensorData {
- uint16_t accel_x;
- uint16_t accel_y;
- uint16_t accel_z;
- uint16_t mag_x;
- uint16_t mag_y;
- uint16_t mag_z;
- uint16_t checksum;
-};
-#else
-struct PtAntSensorData {
- uint8_t accel_x;
- uint8_t accel_y;
- uint8_t accel_z;
-};
-#endif
-
-extern volatile uint8_t pt_ant_sensors_data_available;
-extern struct PtAntSensorData pt_ant_sensors_data;
-extern void pt_ant_sensors_init(void);
-extern void pt_ant_sensors_read(void);
-extern void pt_ant_sensors_init_spi(void);
-
-#define PtAntSensorsEventCheckAndHandle() {
\
- if (pt_ant_sensors_data_available) {
\
- pt_ant_sensors_data_available = FALSE;
\
- DOWNLINK_SEND_ANTENNA_DEBUG(&pt_ant_sensors_data.accel_x,
&pt_ant_sensors_data.accel_y, &pt_ant_sensors_data.accel_z); \
- }
\
- }
-
-#define PtAntSensorsPeriodic() { \
- pt_ant_sensors_read(); \
- }
-
-
-#endif /* PT_ANT_SENSORS_H */
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [paparazzi-commits] [6275] removing obsolete files,
antoine drouin <=