From 0e0e4945d8ad060aa50552a0b27369c18442c2d0 Mon Sep 17 00:00:00 2001 From: Erik van der Zalm Date: Fri, 25 Nov 2011 13:59:58 +0100 Subject: [PATCH] Removed ISR overtaken message from ISR routine --- Marlin/Marlin.pde | 1 + Marlin/stepper.cpp | 18 +++++++++++++++--- Marlin/stepper.h | 2 +- 3 files changed, 17 insertions(+), 4 deletions(-) diff --git a/Marlin/Marlin.pde b/Marlin/Marlin.pde index 61078eee7c..edba13f35f 100644 --- a/Marlin/Marlin.pde +++ b/Marlin/Marlin.pde @@ -289,6 +289,7 @@ void loop() manage_heater(); manage_inactivity(1); checkHitEndstops(); + checkStepperErrors(); LCD_STATUS; } diff --git a/Marlin/stepper.cpp b/Marlin/stepper.cpp index ad1fda9e09..2a3b8d8caf 100644 --- a/Marlin/stepper.cpp +++ b/Marlin/stepper.cpp @@ -77,6 +77,9 @@ static bool old_y_max_endstop=false; static bool old_z_min_endstop=false; static bool old_z_max_endstop=false; +static bool bussy_error=false; +unsigned char OCR1A_error=12345; + volatile long count_position[NUM_AXIS] = { 0, 0, 0, 0}; volatile char count_direction[NUM_AXIS] = { 1, 1, 1, 1}; @@ -160,6 +163,16 @@ asm volatile ( \ #define ENABLE_STEPPER_DRIVER_INTERRUPT() TIMSK1 |= (1<