mirror of
https://github.com/k3ng/k3ng_rotator_controller.git
synced 2025-01-02 19:36:47 +00:00
2020.05.11.01
Handle ARDUINO_AVR_MICRO having Serial port as Serial_ class and Serial1 as HardwareSerial class
This commit is contained in:
parent
97c655108f
commit
0f74085281
@ -482,6 +482,10 @@
|
|||||||
2020.05.08.01
|
2020.05.08.01
|
||||||
Made improvement to rotator_k3ngdisplay.cpp to reduce LCD bus traffic from cursor positioning
|
Made improvement to rotator_k3ngdisplay.cpp to reduce LCD bus traffic from cursor positioning
|
||||||
|
|
||||||
|
2020.05.11.01
|
||||||
|
Handle ARDUINO_AVR_MICRO having Serial port as Serial_ class and Serial1 as HardwareSerial class
|
||||||
|
|
||||||
|
|
||||||
All library files should be placed in directories likes \sketchbook\libraries\library1\ , \sketchbook\libraries\library2\ , etc.
|
All library files should be placed in directories likes \sketchbook\libraries\library1\ , \sketchbook\libraries\library2\ , etc.
|
||||||
Anything rotator_*.* should be in the ino directory!
|
Anything rotator_*.* should be in the ino directory!
|
||||||
|
|
||||||
@ -493,7 +497,7 @@
|
|||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define CODE_VERSION "2020.05.08.01"
|
#define CODE_VERSION "2020.05.11.01"
|
||||||
|
|
||||||
#include <avr/pgmspace.h>
|
#include <avr/pgmspace.h>
|
||||||
#include <EEPROM.h>
|
#include <EEPROM.h>
|
||||||
@ -933,16 +937,31 @@ byte current_az_speed_voltage = 0;
|
|||||||
SERIAL_PORT_CLASS * control_port;
|
SERIAL_PORT_CLASS * control_port;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(FEATURE_MASTER_WITH_SERIAL_SLAVE)
|
#if !defined(ARDUINO_AVR_MICRO)
|
||||||
SERIAL_PORT_CLASS * remote_unit_port;
|
#if defined(FEATURE_MASTER_WITH_SERIAL_SLAVE)
|
||||||
|
SERIAL_PORT_CLASS * remote_unit_port;
|
||||||
|
#endif
|
||||||
|
#else
|
||||||
|
#if defined(FEATURE_MASTER_WITH_SERIAL_SLAVE)
|
||||||
|
SERIAL_PORT_CLASS_SECONDARY * remote_unit_port;
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(FEATURE_GPS)
|
#if !defined(ARDUINO_AVR_MICRO)
|
||||||
SERIAL_PORT_CLASS * gps_port;
|
#if defined(FEATURE_GPS)
|
||||||
#ifdef GPS_MIRROR_PORT
|
SERIAL_PORT_CLASS * gps_port;
|
||||||
SERIAL_PORT_CLASS * (gps_mirror_port);
|
#ifdef GPS_MIRROR_PORT
|
||||||
#endif //GPS_MIRROR_PORT
|
SERIAL_PORT_CLASS * (gps_mirror_port);
|
||||||
#endif //defined(FEATURE_GPS)
|
#endif //GPS_MIRROR_PORT
|
||||||
|
#endif //defined(FEATURE_GPS)
|
||||||
|
#else
|
||||||
|
#if defined(FEATURE_GPS)
|
||||||
|
SERIAL_PORT_CLASS_SECONDARY * gps_port;
|
||||||
|
#ifdef GPS_MIRROR_PORT
|
||||||
|
SERIAL_PORT_CLASS_SECONDARY * (gps_mirror_port);
|
||||||
|
#endif //GPS_MIRROR_PORT
|
||||||
|
#endif //defined(FEATURE_GPS)
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#if defined(FEATURE_MOON_TRACKING) || defined(FEATURE_SUN_TRACKING) || defined(FEATURE_CLOCK) || defined(FEATURE_GPS) || defined(FEATURE_REMOTE_UNIT_SLAVE) || defined(OPTION_DISPLAY_ALT_HHMM_CLOCK_AND_MAIDENHEAD) || defined(OPTION_DISPLAY_CONSTANT_HHMMSS_CLOCK_AND_MAIDENHEAD)
|
#if defined(FEATURE_MOON_TRACKING) || defined(FEATURE_SUN_TRACKING) || defined(FEATURE_CLOCK) || defined(FEATURE_GPS) || defined(FEATURE_REMOTE_UNIT_SLAVE) || defined(OPTION_DISPLAY_ALT_HHMM_CLOCK_AND_MAIDENHEAD) || defined(OPTION_DISPLAY_CONSTANT_HHMMSS_CLOCK_AND_MAIDENHEAD)
|
||||||
|
@ -21,7 +21,10 @@
|
|||||||
|
|
||||||
#if defined(ARDUINO_MAPLE_MINI)
|
#if defined(ARDUINO_MAPLE_MINI)
|
||||||
#define SERIAL_PORT_CLASS USBSerial
|
#define SERIAL_PORT_CLASS USBSerial
|
||||||
#elif defined(ARDUINO_AVR_PROMICRO) || defined(ARDUINO_AVR_LEONARDO) || defined(ARDUINO_AVR_MICRO) || defined(ARDUINO_AVR_YUN) || defined(ARDUINO_AVR_ESPLORA) || defined(ARDUINO_AVR_LILYPAD_USB) || defined(ARDUINO_AVR_ROBOT_CONTROL) || defined(ARDUINO_AVR_ROBOT_MOTOR) || defined(ARDUINO_AVR_LEONARDO_ETH)
|
#elif defined(ARDUINO_AVR_MICRO)
|
||||||
|
#define SERIAL_PORT_CLASS Serial_
|
||||||
|
#define SERIAL_PORT_CLASS_SECONDARY HardwareSerial
|
||||||
|
#elif defined(ARDUINO_AVR_PROMICRO) || defined(ARDUINO_AVR_LEONARDO) || defined(ARDUINO_AVR_YUN) || defined(ARDUINO_AVR_ESPLORA) || defined(ARDUINO_AVR_LILYPAD_USB) || defined(ARDUINO_AVR_ROBOT_CONTROL) || defined(ARDUINO_AVR_ROBOT_MOTOR) || defined(ARDUINO_AVR_LEONARDO_ETH)
|
||||||
#define SERIAL_PORT_CLASS Serial_
|
#define SERIAL_PORT_CLASS Serial_
|
||||||
#elif defined(TEENSYDUINO)
|
#elif defined(TEENSYDUINO)
|
||||||
#define SERIAL_PORT_CLASS usb_serial_class
|
#define SERIAL_PORT_CLASS usb_serial_class
|
||||||
|
@ -121,7 +121,11 @@ You can tweak these, but read the online documentation!
|
|||||||
#define GPS_MIRROR_PORT_BAUD_RATE 9600
|
#define GPS_MIRROR_PORT_BAUD_RATE 9600
|
||||||
#define CONTROL_PORT_MAPPED_TO &Serial // change this line to map the control port to a different serial port (Serial1, Serial2, etc.)
|
#define CONTROL_PORT_MAPPED_TO &Serial // change this line to map the control port to a different serial port (Serial1, Serial2, etc.)
|
||||||
#define REMOTE_PORT_MAPPED_TO &Serial3 // change this line to map the remote_unit port to a different serial port
|
#define REMOTE_PORT_MAPPED_TO &Serial3 // change this line to map the remote_unit port to a different serial port
|
||||||
#define GPS_PORT_MAPPED_TO &Serial2 // change this line to map the GPS port to a different serial port
|
#if !defined(ARDUINO_AVR_MICRO)
|
||||||
|
#define GPS_PORT_MAPPED_TO &Serial2 // change this line to map the GPS port to a different serial port
|
||||||
|
#else
|
||||||
|
#define GPS_PORT_MAPPED_TO &Serial1
|
||||||
|
#endif
|
||||||
//#define GPS_MIRROR_PORT &Serial1 //3 // use this to mirror output from a GPS unit into the Arduino out another port (uncomment to enable)
|
//#define GPS_MIRROR_PORT &Serial1 //3 // use this to mirror output from a GPS unit into the Arduino out another port (uncomment to enable)
|
||||||
#define OPTION_SEND_STRING_OUT_CONTROL_PORT_WHEN_INITIALIZING_STRING ("test\n\r")
|
#define OPTION_SEND_STRING_OUT_CONTROL_PORT_WHEN_INITIALIZING_STRING ("test\n\r")
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user