diff --git a/grbl/config.h b/grbl/config.h index 6697735..bb8b3f8 100644 --- a/grbl/config.h +++ b/grbl/config.h @@ -34,8 +34,8 @@ // NOTE: OEMs can avoid the need to maintain/update the defaults.h and cpu_map.h files and use only // one configuration file by placing their specific defaults and pin map at the bottom of this file. // If doing so, simply comment out these two defines and see instructions below. -#define DEFAULTS_GENERIC -#define CPU_MAP_ATMEGA328P // Arduino Uno CPU +// #define DEFAULTS_GENERIC +// #define CPU_MAP_ATMEGA328P // Arduino Uno CPU // Serial baud rate // #define BAUD_RATE 230400 @@ -579,8 +579,158 @@ */ // Paste CPU_MAP definitions here. +// Define serial port pins and interrupt vectors. +#define SERIAL_RX USART_RX_vect +#define SERIAL_UDRE USART_UDRE_vect + +// Define step pulse output pins. NOTE: All step bit pins must be on the same port. +#define STEP_DDR DDRD +#define STEP_PORT PORTD +#define X_STEP_BIT 2 // Uno Digital Pin 2 +#define Y_STEP_BIT 3 // Uno Digital Pin 3 +#define Z_STEP_BIT 4 // Uno Digital Pin 4 +#define STEP_MASK ((1< 62.5kHz +// #define SPINDLE_TCCRB_INIT_MASK (1< 7.8kHz (Used in v0.9) +// #define SPINDLE_TCCRB_INIT_MASK ((1< 1.96kHz +#define SPINDLE_TCCRB_INIT_MASK (1< 0.98kHz (J-tech laser) + +// NOTE: On the 328p, these must be the same as the SPINDLE_ENABLE settings. +#define SPINDLE_PWM_DDR DDRB +#define SPINDLE_PWM_PORT PORTB +#define SPINDLE_PWM_BIT 3 // Uno Digital Pin 11 // Paste default settings definitions here. - +#define DEFAULT_X_STEPS_PER_MM 250.0 +#define DEFAULT_Y_STEPS_PER_MM 250.0 +#define DEFAULT_Z_STEPS_PER_MM 250.0 +#define DEFAULT_X_MAX_RATE 500.0 // mm/min +#define DEFAULT_Y_MAX_RATE 500.0 // mm/min +#define DEFAULT_Z_MAX_RATE 500.0 // mm/min +#define DEFAULT_X_ACCELERATION (10.0*60*60) // 10*60*60 mm/min^2 = 10 mm/sec^2 +#define DEFAULT_Y_ACCELERATION (10.0*60*60) // 10*60*60 mm/min^2 = 10 mm/sec^2 +#define DEFAULT_Z_ACCELERATION (10.0*60*60) // 10*60*60 mm/min^2 = 10 mm/sec^2 +#define DEFAULT_X_MAX_TRAVEL 200.0 // mm +#define DEFAULT_Y_MAX_TRAVEL 200.0 // mm +#define DEFAULT_Z_MAX_TRAVEL 200.0 // mm +#define DEFAULT_SPINDLE_RPM_MAX 1000.0 // rpm +#define DEFAULT_SPINDLE_RPM_MIN 0.0 // rpm +#define DEFAULT_STEP_PULSE_MICROSECONDS 10 +#define DEFAULT_STEPPING_INVERT_MASK 0 +#define DEFAULT_DIRECTION_INVERT_MASK 0 +#define DEFAULT_STEPPER_IDLE_LOCK_TIME 25 // msec (0-254, 255 keeps steppers enabled) +#define DEFAULT_STATUS_REPORT_MASK 1 // MPos enabled +#define DEFAULT_JUNCTION_DEVIATION 0.01 // mm +#define DEFAULT_ARC_TOLERANCE 0.002 // mm +#define DEFAULT_REPORT_INCHES 0 // false +#define DEFAULT_INVERT_ST_ENABLE 0 // false +#define DEFAULT_INVERT_LIMIT_PINS 0 // false +#define DEFAULT_SOFT_LIMIT_ENABLE 0 // false +#define DEFAULT_HARD_LIMIT_ENABLE 0 // false +#define DEFAULT_INVERT_PROBE_PIN 0 // false +#define DEFAULT_LASER_MODE 0 // false +#define DEFAULT_HOMING_ENABLE 0 // false +#define DEFAULT_HOMING_DIR_MASK 0 // move positive dir +#define DEFAULT_HOMING_FEED_RATE 25.0 // mm/min +#define DEFAULT_HOMING_SEEK_RATE 500.0 // mm/min +#define DEFAULT_HOMING_DEBOUNCE_DELAY 250 // msec (0-65k) +#define DEFAULT_HOMING_PULLOFF 1.0 // mm #endif