Skip to content
Snippets Groups Projects
Commit 2db5a2b5 authored by Andrew Tridgell's avatar Andrew Tridgell Committed by Pat Hickey
Browse files

purple: add the remaining hw defines for purple hardware

parent 252e8580
No related branches found
No related tags found
No related merge requests found
...@@ -48,10 +48,18 @@ ...@@ -48,10 +48,18 @@
#ifndef CONFIG_APM_HARDWARE #ifndef CONFIG_APM_HARDWARE
# define CONFIG_APM_HARDWARE APM_HARDWARE_APM1 # define CONFIG_APM_HARDWARE APM_HARDWARE_APM1
#else #endif
# if CONFIG_APM_HARDWARE == APM_HARDWARE_PURPLE
# define CONFIG_IMU_TYPE CONFIG_IMU_MPU6000 //////////////////////////////////////////////////////////////////////////////
# endif // PURPLE HARDWARE DEFAULTS
//
#if CONFIG_APM_HARDWARE == APM_HARDWARE_PURPLE
# define CONFIG_IMU_TYPE CONFIG_IMU_MPU6000
# define CONFIG_PUSHBUTTON DISABLED
# define CONFIG_RELAY DISABLED
# define MAG_ORIENTATION ROTATION_NONE
# define CONFIG_SONAR_SOURCE SONAR_SOURCE_ANALOG_PIN
#endif #endif
////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////
......
...@@ -197,10 +197,15 @@ static void init_ardupilot() ...@@ -197,10 +197,15 @@ static void init_ardupilot()
pinMode(C_LED_PIN, OUTPUT); // GPS status LED pinMode(C_LED_PIN, OUTPUT); // GPS status LED
pinMode(A_LED_PIN, OUTPUT); // GPS status LED pinMode(A_LED_PIN, OUTPUT); // GPS status LED
pinMode(B_LED_PIN, OUTPUT); // GPS status LED pinMode(B_LED_PIN, OUTPUT); // GPS status LED
#if SLIDE_SWITCH_PIN > 0
pinMode(SLIDE_SWITCH_PIN, INPUT); // To enter interactive mode pinMode(SLIDE_SWITCH_PIN, INPUT); // To enter interactive mode
#endif
#if CONFIG_PUSHBUTTON == ENABLED
pinMode(PUSHBUTTON_PIN, INPUT); // unused pinMode(PUSHBUTTON_PIN, INPUT); // unused
#endif
#if CONFIG_RELAY == ENABLED
DDRL |= B00000100; // Set Port L, pin 2 to output for the relay DDRL |= B00000100; // Set Port L, pin 2 to output for the relay
#endif
// If the switch is in 'menu' mode, run the main menu. // If the switch is in 'menu' mode, run the main menu.
// //
// Since we can't be sure that the setup or test mode won't leave // Since we can't be sure that the setup or test mode won't leave
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment