Skip to content

Commit

Permalink
remove interrupts
Browse files Browse the repository at this point in the history
Remove interrupts for bsongis due to lag of mavlink transmissions
  • Loading branch information
Clooney82 committed Aug 10, 2015
1 parent 790fa20 commit 78e1b09
Show file tree
Hide file tree
Showing 3 changed files with 542 additions and 497 deletions.
70 changes: 45 additions & 25 deletions MavLink_FrSkySPort/FrSkySPort.h
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,31 +1,54 @@
#ifndef _FRSKY_SPORT_H_
#define _FRSKY_SPORT_H_
// Frsky Sensor-ID to use.
// ID of sensor. Must be something that is polled by FrSky RX

enum SensorsEnum {
SENSOR_ID_VARIO,
SENSOR_ID_ALTITUDE,
SENSOR_ID_FLVSS,
SENSOR_ID_FAS,
SENSOR_ID_GPS,
SENSOR_ID_RPM,
SENSOR_ID_HDOP,
SENSOR_ID_ACCX,
SENSOR_ID_ACCY,
SENSOR_ID_ACCZ,
SENSOR_ID_GPS_STATUS,
SENSOR_ID_ROLL_ANGLE,
SENSOR_ID_PITCH_ANGLE,
SENSOR_ID_FLIGHT_MODE,
SENSOR_ID_ARM_MODE,
};
/* These were used on v1.3 but don't match any with the current (v2.08) OpenTX sources so are being removed
#define SENSOR_ID1 0x1B // sensor hub data id
#define SENSOR_ID2 0x0D // sensor hub data id
#define SENSOR_ID3 0x34 // sensor hub data id
#define SENSOR_ID4 0x67 // sensor hub data id
*/
/*
#define SENSOR_ID_VARIO 0x00 // 0
#define SENSOR_ID_ALTITUDE 0x00 // 1 +1
#define SENSOR_ID_FLVSS 0xA1 // 2
#define SENSOR_ID_FAS 0x22 // 3
#define SENSOR_ID_GPS 0x83 // 4
#define SENSOR_ID_RPM 0xE4 // 5
#define SENSOR_ID_HDOP 0x45 // 6
#define SENSOR_ID_ACCX 0x45 // 7
#define SENSOR_ID_ACCY 0xC6 // 8
#define SENSOR_ID_ACCZ 0x45 // 9
#define SENSOR_ID_GPS_STATUS 0xC6 // 10
#define SENSOR_ID_ROLL_ANGLE 0x45 // 11
#define SENSOR_ID_PITCH_ANGLE 0xC6 // 12
#define SENSOR_ID_FLIGHT_MODE 0xC6 // 13
#define SENSOR_ID_ARM_MODE 0xC6 // 14
*/
// To disable a specific sensor, just comment out the sensor_id define (place // first on the line defining the sensor id)
/*
#define SENSOR_ID_VARIO 0x00 // 0
#define SENSOR_ID_FLVSS 0xA1 // 1
#define SENSOR_ID_FAS 0x22 // 2
#define SENSOR_ID_GPS 0x83 // 3
#define SENSOR_ID_RPM 0xE4 // 4
#define SENSOR_ID_SP2UH 0x45 // 5
#define SENSOR_ID_SP2UR 0xC6 // 6
*/
// We'll use some undefined SENSOR_ID's so expect things to break if OpenTX changes

// Frsky-specific
#define START_STOP 0x7e
#define DATA_FRAME 0x10

// Frsky DATA ID's

//Frsky DATA ID's
#define FR_ID_ALTITUDE 0x0100 //ALT_FIRST_ID
#define FR_ID_VARIO 0x0110 //VARIO_FIRST_ID
#define FR_ID_VFAS 0x0210 //VFAS_FIRST_ID
Expand Down Expand Up @@ -53,6 +76,8 @@ enum SensorsEnum {
#define FR_ID_BATT 0xF104 // used by the radio system
#define FR_ID_SWR 0xF105 // used by the radio system



/* The following are defined at frsky_sport.cpp (v2.08) but not used here
#define ALT_LAST_ID 0x010f
Expand All @@ -74,8 +99,3 @@ enum SensorsEnum {
#define A4_LAST_ID 0x091f
#define AIR_SPEED_LAST_ID 0x0a0f
*/

extern "C" void sport_uart0_status_isr(void);

#endif

0 comments on commit 78e1b09

Please sign in to comment.