2020.03.11.01

Upon deactivation of moon or sun tracking using the button pins (moon_tracking_button, sun_tracking_button) or the activation lines (moon_tracking_activate_line, sun_tracking_activate_line), any in progress rotation will now stop (Thanks Steve VE3RX)
This commit is contained in:
Anthony Good 2020-03-11 20:45:39 -04:00
parent ac0be598e7
commit e5166c2b6d
4 changed files with 31 additions and 6 deletions

View File

@ -416,13 +416,16 @@
2020.03.07.01
Added LCD_PERIODIC_REDRAW_TIME_SECS, LCD_CLEAR_BEFORE_REDRAW, LCD_REDRAW_UPON_COMMANDS to settings files
Fixed bug with sun and moon tracking deactivation not stopping rotation (Thanks Steve VE3RX)
Fixed bug with sun and moon tracking deactivation (\U and \M CLI commands) not stopping rotation (Thanks Steve VE3RX)
Minor addition in the k3ngdisplay code for display updates and redraws
2020.03.08.01
Change made to ensure slow start completes before slow stop activates
Add \H command line interface command - clear and redraw the LCD display
2020.03.11.01
Upon deactivation of moon or sun tracking using the button pins (moon_tracking_button, sun_tracking_button) or the activation lines (moon_tracking_activate_line, sun_tracking_activate_line), any in progress rotation will now stop (Thanks Steve VE3RX)
All library files should be placed in directories likes \sketchbook\libraries\library1\ , \sketchbook\libraries\library2\ , etc.
Anything rotator_*.* should be in the ino directory!
@ -432,7 +435,7 @@
*/
#define CODE_VERSION "2020.03.08.01"
#define CODE_VERSION "2020.03.11.01"
#include <avr/pgmspace.h>
#include <EEPROM.h>
@ -3548,6 +3551,11 @@ void check_buttons(){
debug.println("check_buttons: moon tracking off");
#endif // DEBUG_BUTTONS
moon_tracking_active = 0;
submit_request(AZ, REQUEST_STOP, 0, DBG_CHECK_BUTTONS_MOON);
#ifdef FEATURE_ELEVATION_CONTROL
submit_request(EL, REQUEST_STOP, 0, DBG_CHECK_BUTTONS_MOON);
#endif
}
moon_tracking_button_pushed = 0;
}
@ -3583,6 +3591,10 @@ void check_buttons(){
debug.print("check_buttons: sun tracking off");
#endif // DEBUG_BUTTONS
sun_tracking_active = 0;
submit_request(AZ, REQUEST_STOP, 0, DBG_CHECK_BUTTONS_SUN);
#ifdef FEATURE_ELEVATION_CONTROL
submit_request(EL, REQUEST_STOP, 0, DBG_CHECK_BUTTONS_SUN);
#endif
}
sun_tracking_button_pushed = 0;
}
@ -13839,6 +13851,10 @@ void service_moon_tracking(){
if ((moon_tracking_active) && (digitalReadEnhanced(moon_tracking_activate_line)) && (moon_tracking_activated_by_activate_line)) {
moon_tracking_active = 0;
moon_tracking_activated_by_activate_line = 0;
submit_request(AZ, REQUEST_STOP, 0, DBG_SERVICE_MOON_TRACKING);
#ifdef FEATURE_ELEVATION_CONTROL
submit_request(EL, REQUEST_STOP, 0, DBG_SERVICE_MOON_TRACKING);
#endif
}
}
@ -13916,6 +13932,10 @@ void service_sun_tracking(){
if ((sun_tracking_active) && (digitalReadEnhanced(sun_tracking_activate_line)) && (sun_tracking_activated_by_activate_line)) {
sun_tracking_active = 0;
sun_tracking_activated_by_activate_line = 0;
submit_request(AZ, REQUEST_STOP, 0, DBG_SERVICE_SUN_TRACKING);
#ifdef FEATURE_ELEVATION_CONTROL
submit_request(EL, REQUEST_STOP, 0, DBG_SERVICE_SUN_TRACKING);
#endif
}
}

View File

@ -170,5 +170,10 @@
#define AUDIBLE_ALERT_SERVICE 0
#define AUDIBLE_ALERT_ACTIVATE 1
#define DBG_CHECK_BUTTONS_SUN 251
#define DBG_CHECK_BUTTONS_MOON 252
#define DBG_SERVICE_SUN_TRACKING 253
#define DBG_SERVICE_MOON_TRACKING 254
/* ------end of macros ------- */

View File

@ -152,8 +152,8 @@
#define OPTION_DISPLAY_GPS_INDICATOR // display GPS indicator on LCD - set position with LCD_GPS_INDICATOR_POSITION and LCD_GPS_INDICATOR_ROW
// #define OPTION_DISPLAY_MOON_TRACKING_CONTINUOUSLY
//#define OPTION_DISPLAY_DIRECTION_STATUS // N, W, E, S, NW, etc. direction indicator
#define OPTION_DISPLAY_SUN_TRACKING_CONTINUOUSLY
// #define OPTION_DISPLAY_MOON_OR_SUN_TRACKING_CONDITIONAL
// #define OPTION_DISPLAY_SUN_TRACKING_CONTINUOUSLY
#define OPTION_DISPLAY_MOON_OR_SUN_TRACKING_CONDITIONAL
#define OPTION_DISPLAY_VERSION_ON_STARTUP //code provided by Paolo, IT9IPQ
// #define OPTION_LCD_HEADING_FIELD_FIXED_DECIMAL_PLACE

View File

@ -169,8 +169,8 @@
#ifdef FEATURE_MOON_TRACKING
#define moon_tracking_active_pin 0 // goes high when moon tracking is active
#define moon_tracking_activate_line 0 // ground this pin to activate moon tracking (not for use with a button)
#define moon_tracking_button 0 // use with a normally open momentary switch to ground
#define moon_tracking_activate_line A15 // ground this pin to activate moon tracking (not for use with a button)
#define moon_tracking_button A14 // use with a normally open momentary switch to ground
#endif //FEATURE_MOON_TRACKING
#ifdef FEATURE_SUN_TRACKING