diff options
| author | Sam Ward <sam@tolon.com.au> | 2011-05-11 19:41:27 +0800 | 
|---|---|---|
| committer | Sam Ward <sam@tolon.com.au> | 2011-05-11 19:41:27 +0800 | 
| commit | cd1d48a1ba34fb91e7a04ee4fa1947a67593aa59 (patch) | |
| tree | 8cd98531752c3e06db1c2113e8b849bce0f4bc34 /Tonokip_Firmware | |
| parent | 7b44d14a539e55ec4fd6f31dac4a664e54b7ff76 (diff) | |
| parent | 61cc2ef42ccdcc6edc21a0795c62bd02bd6aa4ca (diff) | |
Merge branch 'master' of https://github.com/kliment/Sprinter
Diffstat (limited to 'Tonokip_Firmware')
| -rw-r--r-- | Tonokip_Firmware/Tonokip_Firmware.pde | 15 | 
1 files changed, 13 insertions, 2 deletions
diff --git a/Tonokip_Firmware/Tonokip_Firmware.pde b/Tonokip_Firmware/Tonokip_Firmware.pde index 79663fc..161f1b9 100644 --- a/Tonokip_Firmware/Tonokip_Firmware.pde +++ b/Tonokip_Firmware/Tonokip_Firmware.pde @@ -84,7 +84,8 @@ void kill(byte debug);  // M115	- Capabilities string  // M140 - Set bed target temp  // M190 - Wait for bed current temp to reach target temp. - +// M201 - Set max acceleration in units/s^2 for print moves (M201 X1000 Y1000) +// M202 - Set max acceleration in units/s^2 for travel moves (M202 X1000 Y1000)  //Stepper Movement Variables @@ -314,9 +315,9 @@ void loop()      if(savetosd){          if(strstr(cmdbuffer[bufindr],"M29")==NULL){              write_command(cmdbuffer[bufindr]); -            file.sync();              Serial.println("ok");          }else{ +            file.sync(); // maybe this call is not needed              file.close();              savetosd=false;              Serial.println("Done saving file."); @@ -814,6 +815,16 @@ inline void process_commands()  	Serial.print("E:");          Serial.println(current_e);          break; +      #ifdef RAMP_ACCELERATION +      case 201: // M201 +        if(code_seen('X')) x_steps_per_sqr_second = code_value() * x_steps_per_unit; +        if(code_seen('Y')) x_steps_per_sqr_second = code_value() * y_steps_per_unit; +        break; +      case 202: // M202 +        if(code_seen('X')) x_travel_steps_per_sqr_second = code_value() * x_steps_per_unit; +        if(code_seen('Y')) x_travel_steps_per_sqr_second = code_value() * y_steps_per_unit; +        break; +      #endif      }    }  | 
