Commit 3b8fe81c authored by MagoKimbra's avatar MagoKimbra

Merge remote-tracking branch 'refs/remotes/origin/dev'

parents 3ccfce35 9e51ea06
...@@ -285,6 +285,7 @@ ...@@ -285,6 +285,7 @@
**************************** Fan configuration *************************** **************************** Fan configuration ***************************
**************************************************************************/ **************************************************************************/
// Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino // Increase the FAN pwm frequency. Removes the PWM noise but increases heating in the FET/Arduino
// Only 8 bit boards
//#define FAST_PWM_FAN //#define FAST_PWM_FAN
// Use software PWM to drive the fan, as for the heaters. This uses a very low frequency // Use software PWM to drive the fan, as for the heaters. This uses a very low frequency
......
...@@ -2236,9 +2236,9 @@ ...@@ -2236,9 +2236,9 @@
#define ORIG_TEMP_BED_PIN 4 // ANALOG NUMBERING #define ORIG_TEMP_BED_PIN 4 // ANALOG NUMBERING
#define ORIG_TEMP_0_PIN 0 // ANALOG NUMBERING #define ORIG_TEMP_0_PIN 0 // ANALOG NUMBERING
#define ORIG_TEMP_1_PIN -1 // 1 // ANALOG NUMBERING #define ORIG_TEMP_1_PIN 1 // ANALOG NUMBERING
#define ORIG_TEMP_2_PIN -1 // 2 // ANALOG NUMBERING #define ORIG_TEMP_2_PIN 2 // ANALOG NUMBERING
#define ORIG_TEMP_3_PIN -1 // 3 // ANALOG NUMBERING #define ORIG_TEMP_3_PIN 3 // ANALOG NUMBERING
#if NUM_SERVOS > 0 #if NUM_SERVOS > 0
#define SERVO0_PIN 5 #define SERVO0_PIN 5
...@@ -2286,11 +2286,6 @@ ...@@ -2286,11 +2286,6 @@
#define BTN_EN2 52 #define BTN_EN2 52
#define BTN_ENC 48 #define BTN_ENC 48
#if UI_VOLTAGE_LEVEL != 1
#undef UI_VOLTAGE_LEVEL
#define UI_VOLTAGE_LEVEL 1
#endif
#elif ENABLED(SSD1306_OLED_I2C_CONTROLLER) #elif ENABLED(SSD1306_OLED_I2C_CONTROLLER)
#define BTN_EN1 50 #define BTN_EN1 50
#define BTN_EN2 52 #define BTN_EN2 52
...@@ -2328,6 +2323,10 @@ ...@@ -2328,6 +2323,10 @@
#if MB(RAMPS_FD_V1) || MB(RAMPS_FD_V2) #if MB(RAMPS_FD_V1) || MB(RAMPS_FD_V2)
#define KNOWN_BOARD #define KNOWN_BOARD
#ifndef __SAM3X8E__
#error Oops! Make sure you have 'Arduino Due' selected from the 'Tools -> Boards' menu.
#endif
#if MB(RAMPS_FD_V1) #if MB(RAMPS_FD_V1)
#define RAMPS_FD_V1 #define RAMPS_FD_V1
#define INVERTED_HEATER_PINS #define INVERTED_HEATER_PINS
...@@ -2391,21 +2390,21 @@ ...@@ -2391,21 +2390,21 @@
#define ORIG_HEATER_1_PIN 10 #define ORIG_HEATER_1_PIN 10
#define ORIG_HEATER_2_PIN 11 #define ORIG_HEATER_2_PIN 11
#define ORIG_TEMP_BED_PIN 7 // ANALOG NUMBERING #define ORIG_TEMP_BED_PIN 0 // ANALOG NUMBERING
#define ORIG_TEMP_0_PIN 6 // ANALOG NUMBERING #define ORIG_TEMP_0_PIN 1 // ANALOG NUMBERING
#define ORIG_TEMP_1_PIN 5 // 2 // ANALOG NUMBERING #define ORIG_TEMP_1_PIN 2 // ANALOG NUMBERING
#define ORIG_TEMP_2_PIN 4 // 3 // ANALOG NUMBERING #define ORIG_TEMP_2_PIN 3 // ANALOG NUMBERING
#define ORIG_TEMP_3_PIN 3 // ANALOG NUMBERING #define ORIG_TEMP_3_PIN 4 // ANALOG NUMBERING
#if NUM_SERVOS > 0 #if NUM_SERVOS > 0
#define SERVO0_PIN 11 #define SERVO0_PIN 7
#if NUM_SERVOS > 1 #if NUM_SERVOS > 1
#define SERVO1_PIN 6 #define SERVO1_PIN 6
#if NUM_SERVOS > 2 #if NUM_SERVOS > 2
#define SERVO2_PIN 5 #define SERVO2_PIN 5
#if NUM_SERVOS > 3 #if NUM_SERVOS > 3
#define SERVO3_PIN 4 #define SERVO3_PIN 3
#endif #endif
#endif #endif
#endif #endif
...@@ -2449,6 +2448,10 @@ ...@@ -2449,6 +2448,10 @@
#if MB(SMART_RAMPS) #if MB(SMART_RAMPS)
#define KNOWN_BOARD #define KNOWN_BOARD
#ifndef __SAM3X8E__
#error Oops! Make sure you have 'Arduino Due' selected from the 'Tools -> Boards' menu.
#endif
#define ORIG_X_STEP_PIN 54 #define ORIG_X_STEP_PIN 54
#define ORIG_X_DIR_PIN 55 #define ORIG_X_DIR_PIN 55
#define ORIG_X_ENABLE_PIN 38 #define ORIG_X_ENABLE_PIN 38
...@@ -2471,9 +2474,9 @@ ...@@ -2471,9 +2474,9 @@
#define ORIG_HEATER_1_PIN 9 #define ORIG_HEATER_1_PIN 9
#define ORIG_HEATER_BED_PIN 8 #define ORIG_HEATER_BED_PIN 8
#define ORIG_TEMP_0_PIN 9 // Due analog pin # #define ORIG_TEMP_0_PIN 9 // ANALOG NUMBERING
#define ORIG_TEMP_1_PIN 8 // Due analog pin # #define ORIG_TEMP_1_PIN 10 // ANALOG NUMBERING
#define ORIG_TEMP_BED_PIN 10 // Due analog pin # #define ORIG_TEMP_BED_PIN 11 // ANALOG NUMBERING
#define ORIG_E0_STEP_PIN 26 #define ORIG_E0_STEP_PIN 26
#define ORIG_E0_DIR_PIN 28 #define ORIG_E0_DIR_PIN 28
......
...@@ -177,6 +177,12 @@ ...@@ -177,6 +177,12 @@
::pinMode(pin,mode); ::pinMode(pin,mode);
} }
static inline void delayMicroseconds(unsigned int delayUs) {
::delayMicroseconds(delayUs);
}
static inline void delayMilliseconds(unsigned int delayMs) {
::delay(delayMs);
}
static inline unsigned long timeInMilliseconds() { static inline unsigned long timeInMilliseconds() {
return millis(); return millis();
} }
......
...@@ -344,7 +344,7 @@ bool setTargetedExtruder(int code); ...@@ -344,7 +344,7 @@ bool setTargetedExtruder(int code);
ECHO_V(n); ECHO_V(n);
else else
ECHO_V( (char) ('A'+n-10) ); ECHO_V( (char) ('A'+n-10) );
delay(2); HAL::delayMilliseconds(2);
} }
void prt_hex_byte(unsigned int b) { void prt_hex_byte(unsigned int b) {
...@@ -4945,12 +4945,12 @@ inline void gcode_M92() { ...@@ -4945,12 +4945,12 @@ inline void gcode_M92() {
for(i = 0; i < 16; i++) { // and 16 data bytes for(i = 0; i < 16; i++) { // and 16 data bytes
prt_hex_byte( *(ptr+i)); prt_hex_byte( *(ptr+i));
ECHO_M(" "); ECHO_M(" ");
delay(2); HAL::delayMilliseconds(2);
} }
ECHO_M("|"); // now show where non 0xE5's are ECHO_M("|"); // now show where non 0xE5's are
for(i = 0; i < 16; i++) { for(i = 0; i < 16; i++) {
delay(2); HAL::delayMilliseconds(2);
if ( *(ptr+i)==0xe5) if ( *(ptr+i)==0xe5)
ECHO_M(" "); ECHO_M(" ");
else else
...@@ -4959,7 +4959,7 @@ inline void gcode_M92() { ...@@ -4959,7 +4959,7 @@ inline void gcode_M92() {
ECHO_M("\n"); ECHO_M("\n");
ptr += 16; ptr += 16;
delay(2); HAL::delayMilliseconds(2);
} }
ECHO_M("Done.\n"); ECHO_M("Done.\n");
return; return;
...@@ -5815,16 +5815,16 @@ inline void gcode_M226() { ...@@ -5815,16 +5815,16 @@ inline void gcode_M226() {
const float PULSE_LENGTH = 0.01524; const float PULSE_LENGTH = 0.01524;
for (int i = 0; i < NUM_PULSES; i++) { for (int i = 0; i < NUM_PULSES; i++) {
WRITE(PHOTOGRAPH_PIN, HIGH); WRITE(PHOTOGRAPH_PIN, HIGH);
_delay_ms(PULSE_LENGTH); HAL::delayMilliseconds(PULSE_LENGTH);
WRITE(PHOTOGRAPH_PIN, LOW); WRITE(PHOTOGRAPH_PIN, LOW);
_delay_ms(PULSE_LENGTH); HAL::delayMilliseconds(PULSE_LENGTH);
} }
delay(7.33); HAL::delayMilliseconds(7.33);
for (int i = 0; i < NUM_PULSES; i++) { for (int i = 0; i < NUM_PULSES; i++) {
WRITE(PHOTOGRAPH_PIN, HIGH); WRITE(PHOTOGRAPH_PIN, HIGH);
_delay_ms(PULSE_LENGTH); HAL::delayMilliseconds(PULSE_LENGTH);
WRITE(PHOTOGRAPH_PIN, LOW); WRITE(PHOTOGRAPH_PIN, LOW);
_delay_ms(PULSE_LENGTH); HAL::delayMilliseconds(PULSE_LENGTH);
} }
#endif // HASNT(CHDK) && HAS(PHOTOGRAPH) #endif // HASNT(CHDK) && HAS(PHOTOGRAPH)
} }
...@@ -8513,7 +8513,7 @@ void manage_inactivity(bool ignore_stepper_queue/*=false*/) { ...@@ -8513,7 +8513,7 @@ void manage_inactivity(bool ignore_stepper_queue/*=false*/) {
if (Spool_must_read[e]) { if (Spool_must_read[e]) {
if (RFID522.getID(e)) { if (RFID522.getID(e)) {
Spool_ID[e] = RFID522.RfidDataID[e].Spool_ID; Spool_ID[e] = RFID522.RfidDataID[e].Spool_ID;
delay(200); HAL::delayMilliseconds(200);
if (RFID522.readBlock(e)) { if (RFID522.readBlock(e)) {
Spool_must_read[e] = false; Spool_must_read[e] = false;
density_multiplier[e] = RFID522.RfidData[e].data.density; density_multiplier[e] = RFID522.RfidData[e].data.density;
...@@ -8527,7 +8527,7 @@ void manage_inactivity(bool ignore_stepper_queue/*=false*/) { ...@@ -8527,7 +8527,7 @@ void manage_inactivity(bool ignore_stepper_queue/*=false*/) {
if (Spool_must_write[e]) { if (Spool_must_write[e]) {
if (RFID522.getID(e)) { if (RFID522.getID(e)) {
if (Spool_ID[e] == RFID522.RfidDataID[e].Spool_ID) { if (Spool_ID[e] == RFID522.RfidDataID[e].Spool_ID) {
delay(200); HAL::delayMilliseconds(200);
if (RFID522.writeBlock(e)) { if (RFID522.writeBlock(e)) {
Spool_must_write[e] = false; Spool_must_write[e] = false;
ECHO_SMV(INFO, "Spool on E", e); ECHO_SMV(INFO, "Spool on E", e);
...@@ -8584,7 +8584,7 @@ void kill(const char* lcd_msg) { ...@@ -8584,7 +8584,7 @@ void kill(const char* lcd_msg) {
// FMC small patch to update the LCD before ending // FMC small patch to update the LCD before ending
sei(); // enable interrupts sei(); // enable interrupts
for (int i = 5; i--; lcd_update()) delay(200); // Wait a short time for (int i = 5; i--; lcd_update()) HAL::delayMilliseconds(200); // Wait a short time
cli(); // disable interrupts cli(); // disable interrupts
#if HAS(SUICIDE) #if HAS(SUICIDE)
suicide(); suicide();
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
#define RESUME "//action:resume" // command for host that support action #define RESUME "//action:resume" // command for host that support action
#define DISCONNECT "//action:disconnect" // command for host that support action #define DISCONNECT "//action:disconnect" // command for host that support action
#define SERIAL_INIT(baud) MKSERIAL.begin(baud), delay(1) #define SERIAL_INIT(baud) MKSERIAL.begin(baud), HAL::delayMilliseconds(1)
#define SERIAL_WRITE(x) MKSERIAL.write(x) #define SERIAL_WRITE(x) MKSERIAL.write(x)
#define SERIAL_PRINT(msg, args...) MKSERIAL.print(msg, ##args) #define SERIAL_PRINT(msg, args...) MKSERIAL.print(msg, ##args)
#define SERIAL_ENDL MKSERIAL.println() #define SERIAL_ENDL MKSERIAL.println()
......
...@@ -229,6 +229,18 @@ ...@@ -229,6 +229,18 @@
#include "../Pins.h" #include "../Pins.h"
/**
* SAM3X8E
*/
#ifdef __SAM3X8E__
#ifdef FAST_PWM_FAN
#undef FAST_PWM_FAN
#endif
#ifdef M100_FREE_MEMORY_WATCHER
#undef M100_FREE_MEMORY_WATCHER
#endif
#endif
/** /**
* DONDOLO * DONDOLO
*/ */
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
#define WELCOME_MSG MACHINE_NAME " ready." #define WELCOME_MSG MACHINE_NAME " ready."
#define MSG_SD "SD" #define MSG_SD "SD"
#define MSG_SD_INSERTED "\xb6\xb0\xc4\xde\x20\xbf\xb3\xc6\xad\xb3\xbb\xda\xcf\xbc\xc0" // "Card inserted" #define MSG_SD_INSERTED "\xb6\xb0\xc4\xde\x20\xbf\xb3\xc6\xad\xb3\xbb\xda\xcf\xbc\xc0" // "Card inserted"
#define MSG_SD_REMOVED "\xb6\xb0\xc4\xde\xb6xde\xb1\xd8\xcf\xbe\xdd" // "Card removed" #define MSG_SD_REMOVED "\xb6\xb0\xc4\xde\xb6\xde\xb1\xd8\xcf\xbe\xdd" // "Card removed"
#define MSG_MAIN "\xd2\xb2\xdd" // "Main" #define MSG_MAIN "\xd2\xb2\xdd" // "Main"
#define MSG_AUTOSTART "\xbc\xde\xc4\xde\xb3\xb6\xb2\xbc" // "Autostart" #define MSG_AUTOSTART "\xbc\xde\xc4\xde\xb3\xb6\xb2\xbc" // "Autostart"
#define MSG_DISABLE_STEPPERS "\xd3\xb0\xc0\xb0\xc3\xde\xdd\xb9\xde\xdd\x20\xb5\xcc" // "Disable steppers" #define MSG_DISABLE_STEPPERS "\xd3\xb0\xc0\xb0\xc3\xde\xdd\xb9\xde\xdd\x20\xb5\xcc" // "Disable steppers"
...@@ -36,23 +36,23 @@ ...@@ -36,23 +36,23 @@
#define MSG_ONFOR "On x:" #define MSG_ONFOR "On x:"
#define MSG_PWRCONSUMED "P.er:" #define MSG_PWRCONSUMED "P.er:"
#define MSG_FILCONSUMED "F:" #define MSG_FILCONSUMED "F:"
#define MSG_PREHEAT "Preheat" #define MSG_PREHEAT "\xd6\xc8\xc2" // "Preheat"
#define MSG_PREHEAT_PLA "PLA \xd6\xc8\xc2" #define MSG_PREHEAT_PLA "PLA \xd6\xc8\xc2" // "Preheat PLA"
#define MSG_PREHEAT_PLA_ALL MSG_PREHEAT_PLA " \xbd\xcd\xde\xc3" // " All" #define MSG_PREHEAT_PLA_ALL MSG_PREHEAT_PLA " \xbd\xcd\xde\xc3" // " All"
#define MSG_PREHEAT_PLA_BEDONLY MSG_PREHEAT_PLA " \xcd\xde\xaf\xc4\xde" // "Bed" #define MSG_PREHEAT_PLA_BEDONLY MSG_PREHEAT_PLA " \xcd\xde\xaf\xc4\xde" // "Bed"
#define MSG_PREHEAT_PLA_SETTINGS MSG_PREHEAT_PLA " \xbe\xaf\xc3\xb2" // "conf" #define MSG_PREHEAT_PLA_SETTINGS MSG_PREHEAT_PLA " \xbe\xaf\xc3\xb2" // "conf"
#define MSG_PREHEAT_ABS "ABS \xd6\xc8\xc2" #define MSG_PREHEAT_ABS "ABS \xd6\xc8\xc2" // "Preheat ABS"
#define MSG_PREHEAT_ABS_ALL MSG_PREHEAT_ABS " \xbd\xcd\xde\xc3" // " All" #define MSG_PREHEAT_ABS_ALL MSG_PREHEAT_ABS " \xbd\xcd\xde\xc3" // " All"
#define MSG_PREHEAT_ABS_BEDONLY MSG_PREHEAT_ABS " \xcd\xde\xaf\xc4\xde" // "Bed" #define MSG_PREHEAT_ABS_BEDONLY MSG_PREHEAT_ABS " \xcd\xde\xaf\xc4\xde" // "Bed"
#define MSG_PREHEAT_ABS_SETTINGS MSG_PREHEAT_ABS " \xbe\xaf\xc3\xb2" // "conf" #define MSG_PREHEAT_ABS_SETTINGS MSG_PREHEAT_ABS " \xbe\xaf\xc3\xb2" // "conf"
#define MSG_PREHEAT_GUM "Preheat GUM" #define MSG_PREHEAT_GUM "GUM \xd6\xc8\xc2" // "Preheat GUM"
#define MSG_PREHEAT_GUM_ALL "Preheat GUM All" #define MSG_PREHEAT_GUM_ALL MSG_PREHEAT_GUM " \xbd\xcd\xde\xc3" // " All"
#define MSG_PREHEAT_GUM_BEDONLY "Preheat GUM Bed" #define MSG_PREHEAT_GUM_BEDONLY MSG_PREHEAT_GUM " \xcd\xde\xaf\xc4\xde" // "Bed"
#define MSG_PREHEAT_GUM_SETTINGS "Preheat GUM conf" #define MSG_PREHEAT_GUM_SETTINGS MSG_PREHEAT_GUM " \xbe\xaf\xc3\xb2" // "conf"
#define MSG_TOO_COLD_FOR_FILAMENTCHANGE "Hotend too cold to change filament" #define MSG_TOO_COLD_FOR_FILAMENTCHANGE "Hotend too cold to change filament"
#define MSG_COOLDOWN "\xb6\xc8\xc2\xc3\xb2\xbc" // "Cooldown" #define MSG_COOLDOWN "\xb6\xc8\xc2\xc3\xb2\xbc" // "Cooldown"
#define MSG_SWITCH_PS_ON "\xc3\xde\xdd\xb9\xdd\xde\x20\xb5\xdd" // "Switch power on" #define MSG_SWITCH_PS_ON "\xc3\xde\xdd\xb9\xde\xdd\x20\xb5\xdd" // "Switch power on"
#define MSG_SWITCH_PS_OFF "\xc3\xde\xdd\xb9\xdd\xde\x20\xb5\xcc" // "Switch power off" #define MSG_SWITCH_PS_OFF "\xc3\xde\xdd\xb9\xde\xdd\x20\xb5\xcc" // "Switch power off"
#define MSG_EXTRUDE "\xb5\xbc\xc0\xde\xbc" // "Extrude" #define MSG_EXTRUDE "\xb5\xbc\xc0\xde\xbc" // "Extrude"
#define MSG_RETRACT "\xd8\xc4\xd7\xb8\xc4" // "Retract" #define MSG_RETRACT "\xd8\xc4\xd7\xb8\xc4" // "Retract"
#define MSG_PURGE "Purge" #define MSG_PURGE "Purge"
...@@ -87,7 +87,7 @@ ...@@ -87,7 +87,7 @@
#define MSG_Y "Y" #define MSG_Y "Y"
#define MSG_Z "Z" #define MSG_Z "Z"
#define MSG_E "E" #define MSG_E "E"
#define MSG_MOVE "Move" #define MSG_MOVE "\xb2\xc4\xde\xb3" // "Move"
#define MSG_MOVE_AXIS "\xbc\xde\xb8\xb2\xc4\xde\xb3" // "Move axis" #define MSG_MOVE_AXIS "\xbc\xde\xb8\xb2\xc4\xde\xb3" // "Move axis"
#define MSG_MOVE_X "X\xbc\xde\xb8\x20\xb2\xc4\xde\xb3" // "Move X" #define MSG_MOVE_X "X\xbc\xde\xb8\x20\xb2\xc4\xde\xb3" // "Move X"
#define MSG_MOVE_Y "Y\xbc\xde\xb8\x20\xb2\xc4\xde\xb3" // "Move Y" #define MSG_MOVE_Y "Y\xbc\xde\xb8\x20\xb2\xc4\xde\xb3" // "Move Y"
...@@ -115,7 +115,7 @@ ...@@ -115,7 +115,7 @@
#define MSG_FILAMENT_SIZE_EXTRUDER "Fil. Dia." #define MSG_FILAMENT_SIZE_EXTRUDER "Fil. Dia."
#define MSG_CONTRAST "LCD\xba\xdd\xc4\xd7\xbd\xc4" // "LCD contrast" #define MSG_CONTRAST "LCD\xba\xdd\xc4\xd7\xbd\xc4" // "LCD contrast"
#define MSG_STORE_EPROM "\xd2\xd3\xd8\xcd\xb6\xb8\xc9\xb3" // "Store memory" #define MSG_STORE_EPROM "\xd2\xd3\xd8\xcd\xb6\xb8\xc9\xb3" // "Store memory"
#define MSG_LOAD_EPROM "\xd2\xd3\xd8\xb6\xd7\xd6\xd0\ba\xd0" // "Load memory" #define MSG_LOAD_EPROM "\xd2\xd3\xd8\xb6\xd7\xd6\xd0\xba\xd0" // "Load memory"
#define MSG_RESTORE_FAILSAFE "\xbe\xaf\xc3\xb2\xd8\xbe\xaf\xc4" // "Restore failsafe" #define MSG_RESTORE_FAILSAFE "\xbe\xaf\xc3\xb2\xd8\xbe\xaf\xc4" // "Restore failsafe"
#define MSG_REFRESH "\xd8\xcc\xda\xaf\xbc\xad" // "Refresh" #define MSG_REFRESH "\xd8\xcc\xda\xaf\xbc\xad" // "Refresh"
#define MSG_WATCH "\xb2\xdd\xcc\xab" // "Info screen" #define MSG_WATCH "\xb2\xdd\xcc\xab" // "Info screen"
...@@ -147,7 +147,7 @@ ...@@ -147,7 +147,7 @@
#define MSG_ZPROBE_OUT "Z\xcc\xdf\xdb\xb0\xcc\xde \xcd\xde\xaf\xc4\xee\xb6\xde\xb2" // "Z probe out. bed" #define MSG_ZPROBE_OUT "Z\xcc\xdf\xdb\xb0\xcc\xde \xcd\xde\xaf\xc4\xee\xb6\xde\xb2" // "Z probe out. bed"
#define MSG_POSITION_UNKNOWN "\xb9\xde\xdd\xc3\xdd\xcaXY\xb2\xc4\xde\xb3\xba\xdeZ" // "Home X/Y before Z" #define MSG_POSITION_UNKNOWN "\xb9\xde\xdd\xc3\xdd\xcaXY\xb2\xc4\xde\xb3\xba\xdeZ" // "Home X/Y before Z"
#define MSG_ZPROBE_ZOFFSET "Z\xb5\xcc\xbe\xaf\xc4" // "Z Offset" #define MSG_ZPROBE_ZOFFSET "Z\xb5\xcc\xbe\xaf\xc4" // "Z Offset"
#define MSG_BABYSTEP ""\xcb\xde\xc4\xde\xb3" #define MSG_BABYSTEP "\xcb\xde\xc4\xde\xb3"
#define MSG_BABYSTEP_X MSG_BABYSTEP " " MSG_X #define MSG_BABYSTEP_X MSG_BABYSTEP " " MSG_X
#define MSG_BABYSTEP_Y MSG_BABYSTEP " " MSG_Y #define MSG_BABYSTEP_Y MSG_BABYSTEP " " MSG_Y
#define MSG_BABYSTEP_Z MSG_BABYSTEP " " MSG_Z #define MSG_BABYSTEP_Z MSG_BABYSTEP " " MSG_Z
......
...@@ -19,10 +19,10 @@ ...@@ -19,10 +19,10 @@
#define WELCOME_MSG MACHINE_NAME " ready." #define WELCOME_MSG MACHINE_NAME " ready."
#define MSG_SD "SD" #define MSG_SD "SD"
#define MSG_SD_INSERTED "セード ンウニユウアレマシタ" // "Card inserted" #define MSG_SD_INSERTED "カード ソウニュウサレマシタ" // "Card inserted"
#define MSG_SD_REMOVED "セードゼアリマセン" // "Card removed" #define MSG_SD_REMOVED "カードガアリマセン" // "Card removed"
#define MSG_MAIN "イン" // "Main" #define MSG_MAIN "イン" // "Main"
#define MSG_AUTOSTART "ヅドウセイシ" // "Autostart" #define MSG_AUTOSTART "ジドウカイシ" // "Autostart"
#define MSG_DISABLE_STEPPERS "モーターデンゲン オフ" // "Disable steppers" #define MSG_DISABLE_STEPPERS "モーターデンゲン オフ" // "Disable steppers"
#define MSG_AUTO_HOME "ゲンテンニイドウ" // "Auto home" #define MSG_AUTO_HOME "ゲンテンニイドウ" // "Auto home"
#define MSG_MBL_SETTING "Manual Bed Leveling" #define MSG_MBL_SETTING "Manual Bed Leveling"
...@@ -34,37 +34,37 @@ ...@@ -34,37 +34,37 @@
#define MSG_MBL_4 " Adjust fourth point" #define MSG_MBL_4 " Adjust fourth point"
#define MSG_MBL_5 " Is it ok? " #define MSG_MBL_5 " Is it ok? "
#define MSG_MBL_6 " BED leveled! " #define MSG_MBL_6 " BED leveled! "
#define MSG_SET_HOME_OFFSETS "キヅユンオフセツトセツテイ" // "Set home offsets" #define MSG_SET_HOME_OFFSETS "キジュンオフセットセッテイ" // "Set home offsets"
#define MSG_SET_ORIGIN "キヅユンセツト" // "Set origin" #define MSG_SET_ORIGIN "キジュンセット" // "Set origin"
#define MSG_ONFOR "On x:" #define MSG_ONFOR "On x:"
#define MSG_PWRCONSUMED "P.er:" #define MSG_PWRCONSUMED "P.er:"
#define MSG_FILCONSUMED "F:" #define MSG_FILCONSUMED "F:"
#define MSG_PREHEAT "Preheat" #define MSG_PREHEAT "Preheat"
#define MSG_PREHEAT_PLA "PLA ヨネ" // "Preheat PLA" #define MSG_PREHEAT_PLA "PLA ヨネ" // "Preheat PLA"
#define MSG_PREHEAT_PLA_ALL MSG_PREHEAT_PLA " スベテ" // " All" #define MSG_PREHEAT_PLA_ALL MSG_PREHEAT_PLA " スベテ" // " All"
#define MSG_PREHEAT_PLA_BEDONLY MSG_PREHEAT_PLA " ベド" // "Bed" #define MSG_PREHEAT_PLA_BEDONLY MSG_PREHEAT_PLA " ベド" // "Bed"
#define MSG_PREHEAT_PLA_SETTINGS MSG_PREHEAT_PLA " セテイ" // "conf" #define MSG_PREHEAT_PLA_SETTINGS MSG_PREHEAT_PLA " セテイ" // "conf"
#define MSG_PREHEAT_ABS "ABS ヨネ" // "Preheat ABS" #define MSG_PREHEAT_ABS "ABS ヨネ" // "Preheat ABS"
#define MSG_PREHEAT_ABS_ALL MSG_PREHEAT_ABS " スベテ" // " All" #define MSG_PREHEAT_ABS_ALL MSG_PREHEAT_ABS " スベテ" // " All"
#define MSG_PREHEAT_ABS_BEDONLY MSG_PREHEAT_ABS " ベド" // "Bed" #define MSG_PREHEAT_ABS_BEDONLY MSG_PREHEAT_ABS " ベド" // "Bed"
#define MSG_PREHEAT_ABS_SETTINGS MSG_PREHEAT_ABS " セテイ" // "conf" #define MSG_PREHEAT_ABS_SETTINGS MSG_PREHEAT_ABS " セテイ" // "conf"
#define MSG_PREHEAT_GUM MSG_PREHEAT " GUM" #define MSG_PREHEAT_GUM "GUM ヨネツ" // "Preheat GUM"
#define MSG_PREHEAT_GUM_ALL MSG_PREHEAT_GUM " All" #define MSG_PREHEAT_GUM_ALL MSG_PREHEAT_GUM " スベテ" // " All"
#define MSG_PREHEAT_GUM_BEDONLY MSG_PREHEAT_GUM " Bed" #define MSG_PREHEAT_GUM_BEDONLY MSG_PREHEAT_GUM " ベッド" // "Bed"
#define MSG_PREHEAT_GUM_SETTINGS "GUM conf." #define MSG_PREHEAT_GUM_SETTINGS MSG_PREHEAT_GUM " セッテイ" // "conf"
#define MSG_TOO_COLD_FOR_FILAMENTCHANGE "Hotend too cold to change filament" #define MSG_TOO_COLD_FOR_FILAMENTCHANGE "Hotend too cold to change filament"
#define MSG_COOLDOWN "セネシテイシ" // "Cooldown" #define MSG_COOLDOWN "カネツテイシ" // "Cooldown"
#define MSG_SWITCH_PS_ON "デンケゾ オン" // "Switch power on" #define MSG_SWITCH_PS_ON "デンゲン オン" // "Switch power on"
#define MSG_SWITCH_PS_OFF "デンケゾ オフ" // "Switch power off" #define MSG_SWITCH_PS_OFF "デンゲン オフ" // "Switch power off"
#define MSG_EXTRUDE "オシダシ" // "Extrude" #define MSG_EXTRUDE "オシダシ" // "Extrude"
#define MSG_RETRACT "リトラト" // "Retract" #define MSG_RETRACT "リトラト" // "Retract"
#define MSG_PURGE "Purge" #define MSG_PURGE "Purge"
#define MSG_LEVEL_BED "Level bed" #define MSG_LEVEL_BED "Level bed"
#define MSG_SPEED "スヒ゜ード" // "Speed" #define MSG_SPEED "スード" // "Speed"
#define MSG_NOZZLE "ノズル" // "Nozzle" #define MSG_NOZZLE "ノズル" // "Nozzle"
#define MSG_BED "ベド" // "Bed" #define MSG_BED "ベド" // "Bed"
#define MSG_FAN_SPEED "ファンンケド" // "Fan speed" #define MSG_FAN_SPEED "ファンソクド" // "Fan speed"
#define MSG_FLOW "オリリョウ" // "Flow" #define MSG_FLOW "オリリョウ" // "Flow"
#define MSG_CONTROL "コントロール" // "Control" #define MSG_CONTROL "コントロール" // "Control"
#define MSG_STATS "Statistics" #define MSG_STATS "Statistics"
#define MSG_FIX_LOSE_STEPS "Fix axis steps" #define MSG_FIX_LOSE_STEPS "Fix axis steps"
...@@ -72,7 +72,7 @@ ...@@ -72,7 +72,7 @@
#define MSG_MAX LCD_STR_THERMOMETER " Max" #define MSG_MAX LCD_STR_THERMOMETER " Max"
#define MSG_FACTOR LCD_STR_THERMOMETER " Fact" #define MSG_FACTOR LCD_STR_THERMOMETER " Fact"
#define MSG_IDLEOOZING "Anti oozing" #define MSG_IDLEOOZING "Anti oozing"
#define MSG_AUTOTEMP "ドウオンド" // "Autotemp" #define MSG_AUTOTEMP "ドウオンド" // "Autotemp"
#define MSG_ON "ON " #define MSG_ON "ON "
#define MSG_OFF "OFF" #define MSG_OFF "OFF"
#define MSG_PID_P "PID-P" #define MSG_PID_P "PID-P"
...@@ -81,7 +81,7 @@ ...@@ -81,7 +81,7 @@
#define MSG_H1 " H1" #define MSG_H1 " H1"
#define MSG_H2 " H2" #define MSG_H2 " H2"
#define MSG_H3 " H3" #define MSG_H3 " H3"
#define MSG_ACC "センケド" // "Accel" #define MSG_ACC "カソクド" // "Accel"
#define MSG_VXY_JERK "Vxy-jerk" #define MSG_VXY_JERK "Vxy-jerk"
#define MSG_VZ_JERK "Vz-jerk" #define MSG_VZ_JERK "Vz-jerk"
#define MSG_VE_JERK "Ve-jerk" #define MSG_VE_JERK "Ve-jerk"
...@@ -90,15 +90,15 @@ ...@@ -90,15 +90,15 @@
#define MSG_Y "Y" #define MSG_Y "Y"
#define MSG_Z "Z" #define MSG_Z "Z"
#define MSG_E "E" #define MSG_E "E"
#define MSG_MOVE "Move" #define MSG_MOVE "イドウ" // "Move"
#define MSG_MOVE_AXIS "ヅケイドウ" // "Move axis" #define MSG_MOVE_AXIS "ジクイドウ" // "Move axis"
#define MSG_MOVE_X "Xヅケ イドウ" // "Move X" #define MSG_MOVE_X "Xジク イドウ" // "Move X"
#define MSG_MOVE_Y "Yヅケ イドウ" // "Move Y" #define MSG_MOVE_Y "Yジク イドウ" // "Move Y"
#define MSG_MOVE_Z "Zヅケ イドウ" // "Move Z" #define MSG_MOVE_Z "Zジク イドウ" // "Move Z"
#define MSG_MOVE_01MM "0.1mm イドウ" // "Move 0.1mm" #define MSG_MOVE_01MM "0.1mm イドウ" // "Move 0.1mm"
#define MSG_MOVE_1MM " 1mm イドウ" // "Move 1mm" #define MSG_MOVE_1MM " 1mm イドウ" // "Move 1mm"
#define MSG_MOVE_10MM " 10mm イドウ" // "Move 10mm" #define MSG_MOVE_10MM " 10mm イドウ" // "Move 10mm"
#define MSG_MOVE_E "エストルーダー" // "Extruder" #define MSG_MOVE_E "エストルーダー" // "Extruder"
#define MSG_VMIN "Vmin" #define MSG_VMIN "Vmin"
#define MSG_VTRAV_MIN "VTrav min" #define MSG_VTRAV_MIN "VTrav min"
#define MSG_AMAX "Amax " #define MSG_AMAX "Amax "
...@@ -112,27 +112,27 @@ ...@@ -112,27 +112,27 @@
#define MSG_E2STEPS "E2steps/mm" #define MSG_E2STEPS "E2steps/mm"
#define MSG_E3STEPS "E3steps/mm" #define MSG_E3STEPS "E3steps/mm"
#define MSG_TEMPERATURE "オンド" // "Temperature" #define MSG_TEMPERATURE "オンド" // "Temperature"
#define MSG_MOTION "ウゴキセテイ" // "Motion" #define MSG_MOTION "ウゴキセテイ" // "Motion"
#define MSG_FILAMENT "フィラント" // "Filament" #define MSG_FILAMENT "フィラント" // "Filament"
#define MSG_VOLUMETRIC_ENABLED MSG_E " in mm3" #define MSG_VOLUMETRIC_ENABLED MSG_E " in mm3"
#define MSG_FILAMENT_SIZE_EXTRUDER "Fil. Dia." #define MSG_FILAMENT_SIZE_EXTRUDER "Fil. Dia."
#define MSG_CONTRAST "LCDコントラスト" // "LCD contrast" #define MSG_CONTRAST "LCDコントラスト" // "LCD contrast"
#define MSG_STORE_EPROM "ナモリヘセケノウ" // "Store memory" #define MSG_STORE_EPROM "メモリヘカクノウ" // "Store memory"
#define MSG_LOAD_EPROM "ナモリセラヨミbaミ" // "Load memory" #define MSG_LOAD_EPROM "メモリカラヨミコミ" // "Load memory"
#define MSG_RESTORE_FAILSAFE "セツテイリセツト" // "Restore failsafe" #define MSG_RESTORE_FAILSAFE "セッテイリセット" // "Restore failsafe"
#define MSG_REFRESH "リフレツシユ" // "Refresh" #define MSG_REFRESH "リフレッシュ" // "Refresh"
#define MSG_WATCH "インフォ" // "Info screen" #define MSG_WATCH "インフォ" // "Info screen"
#define MSG_PREPARE "ヅユンゼセツテイ" //"Prepare" #define MSG_PREPARE "ジュンビセッテイ" //"Prepare"
#define MSG_TUNE "チョウセイ" // "Tune" #define MSG_TUNE "チョウセイ" // "Tune"
#define MSG_PAUSE_PRINT "イチテイシ" // "Pause print" #define MSG_PAUSE_PRINT "イチテイシ" // "Pause print"
#define MSG_RESUME_PRINT "プリントアイセイ" // "Resume print" #define MSG_RESUME_PRINT "プリントサイカイ" // "Resume print"
#define MSG_STOP_PRINT "プリントテイシ" // "Stop print" #define MSG_STOP_PRINT "プリントテイシ" // "Stop print"
#define MSG_CARD_MENU "SDセードセラプリント" // "Print from SD" #define MSG_CARD_MENU "SDカードカラプリント" // "Print from SD"
#define MSG_NO_CARD "SDセードゼアリマセン" // "No SD card" #define MSG_NO_CARD "SDカードガアリマセン" // "No SD card"
#define MSG_DWELL "スリープ" // "Sleep..." #define MSG_DWELL "スリープ" // "Sleep..."
#define MSG_USERWAIT "シバラケオマチケダアイ" // "Wait for user..." #define MSG_USERWAIT "シバラクオマチクダサイ" // "Wait for user..."
#define MSG_RESUMING "プリントアイセイ" // "Resuming print" #define MSG_RESUMING "プリントサイカイ" // "Resuming print"
#define MSG_PRINT_ABORTED "プリントチユウシアレマシタ" // "Print aborted" #define MSG_PRINT_ABORTED "プリントチュウシサレマシタ" // "Print aborted"
#define MSG_NO_MOVE "ウゴキマセン" // "No move." #define MSG_NO_MOVE "ウゴキマセン" // "No move."
#define MSG_KILLED "ショウキョ" // "KILLED. " #define MSG_KILLED "ショウキョ" // "KILLED. "
#define MSG_STOPPED "テイシシマシタ" // "STOPPED. " #define MSG_STOPPED "テイシシマシタ" // "STOPPED. "
...@@ -144,16 +144,16 @@ ...@@ -144,16 +144,16 @@
#define MSG_CONTROL_RETRACT_RECOVER_SWAP "S UnRet+mm" #define MSG_CONTROL_RETRACT_RECOVER_SWAP "S UnRet+mm"
#define MSG_CONTROL_RETRACT_RECOVERF "UnRet F" #define MSG_CONTROL_RETRACT_RECOVERF "UnRet F"
#define MSG_AUTORETRACT "AutoRetr." #define MSG_AUTORETRACT "AutoRetr."
#define MSG_FILAMENTCHANGE "フィラナントコウセン" // "Change filament" #define MSG_FILAMENTCHANGE "フィラメントコウカン" // "Change filament"
#define MSG_INIT_SDCARD "SDセードアイヨミコミ" // "Init. SD card" #define MSG_INIT_SDCARD "SDカードサイヨミコミ" // "Init. SD card"
#define MSG_CNG_SDCARD "SDセードコウセン" // "Change SD card" #define MSG_CNG_SDCARD "SDカードコウカン" // "Change SD card"
#define MSG_ZPROBE_OUT "Zプローブ ベツトnゼイ" // "Z probe out. bed" #define MSG_ZPROBE_OUT "Zプローブ ベッドガイ" // "Z probe out. bed"
#define MSG_POSITION_UNKNOWN "ゲンテンハXYイドウゴZ" // "Home X/Y before Z" #define MSG_POSITION_UNKNOWN "ゲンテンハXYイドウゴZ" // "Home X/Y before Z"
#define MSG_ZPROBE_ZOFFSET "Zオフセト" // "Z Offset" #define MSG_ZPROBE_ZOFFSET "Zオフセト" // "Z Offset"
#define MSG_BABYSTEP "Babystep" #define MSG_BABYSTEP "ビドウ"
#define MSG_BABYSTEP_X "ドウ X" // "Babystep X" #define MSG_BABYSTEP_X "ドウ X" // "Babystep X"
#define MSG_BABYSTEP_Y "ドウ Y" // "Babystep Y" #define MSG_BABYSTEP_Y "ドウ Y" // "Babystep Y"
#define MSG_BABYSTEP_Z "ドウ Z" // "Babystep Z" #define MSG_BABYSTEP_Z "ドウ Z" // "Babystep Z"
#define MSG_ENDSTOP_ABORT "Endstop abort" #define MSG_ENDSTOP_ABORT "Endstop abort"
#define MSG_HEATING_FAILED_LCD "Heating failed" #define MSG_HEATING_FAILED_LCD "Heating failed"
#define MSG_ERR_REDUNDANT_TEMP "REDUNDANT TEMP ERROR" #define MSG_ERR_REDUNDANT_TEMP "REDUNDANT TEMP ERROR"
......
...@@ -744,7 +744,7 @@ ISR(TIMER1_COMPA_vect) { ...@@ -744,7 +744,7 @@ ISR(TIMER1_COMPA_vect) {
#endif #endif
#if ENABLED(STEPPER_HIGH_LOW) && STEPPER_HIGH_LOW_DELAY > 0 #if ENABLED(STEPPER_HIGH_LOW) && STEPPER_HIGH_LOW_DELAY > 0
delayMicroseconds(STEPPER_HIGH_LOW_DELAY); HAL::delayMicroseconds(STEPPER_HIGH_LOW_DELAY);
#endif #endif
#define STEP_END(axis, AXIS) \ #define STEP_END(axis, AXIS) \
...@@ -1319,7 +1319,7 @@ void quickStop() { ...@@ -1319,7 +1319,7 @@ void quickStop() {
X_STEP_WRITE(!INVERT_X_STEP_PIN); X_STEP_WRITE(!INVERT_X_STEP_PIN);
Y_STEP_WRITE(!INVERT_Y_STEP_PIN); Y_STEP_WRITE(!INVERT_Y_STEP_PIN);
Z_STEP_WRITE(!INVERT_Z_STEP_PIN); Z_STEP_WRITE(!INVERT_Z_STEP_PIN);
delayMicroseconds(2); HAL::delayMicroseconds(1U);
X_STEP_WRITE(INVERT_X_STEP_PIN); X_STEP_WRITE(INVERT_X_STEP_PIN);
Y_STEP_WRITE(INVERT_Y_STEP_PIN); Y_STEP_WRITE(INVERT_Y_STEP_PIN);
Z_STEP_WRITE(INVERT_Z_STEP_PIN); Z_STEP_WRITE(INVERT_Z_STEP_PIN);
...@@ -1345,7 +1345,7 @@ void digitalPotWrite(int address, int value) { ...@@ -1345,7 +1345,7 @@ void digitalPotWrite(int address, int value) {
SPI.transfer(address); // send in the address and value via SPI: SPI.transfer(address); // send in the address and value via SPI:
SPI.transfer(value); SPI.transfer(value);
digitalWrite(DIGIPOTSS_PIN, HIGH); // take the SS pin high to de-select the chip: digitalWrite(DIGIPOTSS_PIN, HIGH); // take the SS pin high to de-select the chip:
//delay(10); //HAL::delayMilliseconds(10);
#else #else
UNUSED(address); UNUSED(address);
UNUSED(value); UNUSED(value);
......
...@@ -236,14 +236,14 @@ bool nexInit(void) ...@@ -236,14 +236,14 @@ bool nexInit(void)
if (ret1 && ret2) { if (ret1 && ret2) {
sendCommand("baud=57600"); sendCommand("baud=57600");
nexSerial.end(); nexSerial.end();
delay(1000); HAL::delayMilliseconds(1000);
nexSerial.begin(57600); nexSerial.begin(57600);
return ret1 && ret2; return ret1 && ret2;
// Else try to 57600 baudrate // Else try to 57600 baudrate
} else { } else {
nexSerial.end(); nexSerial.end();
delay(1000); HAL::delayMilliseconds(1000);
nexSerial.begin(57600); nexSerial.begin(57600);
sendCommand(""); sendCommand("");
sendCommand("bkcmd=1"); sendCommand("bkcmd=1");
...@@ -263,7 +263,7 @@ void nexLoop(NexTouch *nex_listen_list[]) ...@@ -263,7 +263,7 @@ void nexLoop(NexTouch *nex_listen_list[])
while (nexSerial.available() > 0) while (nexSerial.available() > 0)
{ {
delay(10); HAL::delayMilliseconds(10);
c = nexSerial.read(); c = nexSerial.read();
if (NEX_RET_EVENT_TOUCH_HEAD == c) if (NEX_RET_EVENT_TOUCH_HEAD == c)
...@@ -306,7 +306,7 @@ bool sendCurrentPageId(uint8_t* pageId) ...@@ -306,7 +306,7 @@ bool sendCurrentPageId(uint8_t* pageId)
goto __return; goto __return;
} }
sendCommand("sendme"); sendCommand("sendme");
delay(50); HAL::delayMilliseconds(50);
nexSerial.setTimeout(100); nexSerial.setTimeout(100);
if (sizeof(temp) != nexSerial.readBytes((char *)temp, sizeof(temp))) if (sizeof(temp) != nexSerial.readBytes((char *)temp, sizeof(temp)))
{ {
...@@ -356,7 +356,7 @@ bool setCurrentBrightness(uint8_t dimValue) ...@@ -356,7 +356,7 @@ bool setCurrentBrightness(uint8_t dimValue)
cmd += "dim="; cmd += "dim=";
cmd += buf; cmd += buf;
sendCommand(cmd.c_str()); sendCommand(cmd.c_str());
delay(10); HAL::delayMilliseconds(10);
if(recvRetCommandFinished()) if(recvRetCommandFinished())
{ {
...@@ -391,7 +391,7 @@ bool setDefaultBaudrate(uint32_t defaultBaudrate) ...@@ -391,7 +391,7 @@ bool setDefaultBaudrate(uint32_t defaultBaudrate)
cmd += "bauds="; cmd += "bauds=";
cmd += buf; cmd += buf;
sendCommand(cmd.c_str()); sendCommand(cmd.c_str());
delay(10); HAL::delayMilliseconds(10);
if(recvRetCommandFinished()) if(recvRetCommandFinished())
{ {
......
...@@ -230,7 +230,8 @@ ...@@ -230,7 +230,8 @@
#error DEPENDENCY ERROR: Missing setting THERMAL_PROTECTION_BED_HYSTERESIS #error DEPENDENCY ERROR: Missing setting THERMAL_PROTECTION_BED_HYSTERESIS
#endif #endif
#endif #endif
//fan
// Fan
#if DISABLED(SOFT_PWM_SCALE) #if DISABLED(SOFT_PWM_SCALE)
#error DEPENDENCY ERROR: Missing setting SOFT_PWM_SCALE #error DEPENDENCY ERROR: Missing setting SOFT_PWM_SCALE
#endif #endif
...@@ -259,7 +260,7 @@ ...@@ -259,7 +260,7 @@
#endif #endif
#endif #endif
//extruder // Extruder
#if ENABLED(PREVENT_DANGEROUS_EXTRUDE) #if ENABLED(PREVENT_DANGEROUS_EXTRUDE)
#if DISABLED(EXTRUDE_MINTEMP) #if DISABLED(EXTRUDE_MINTEMP)
#error DEPENDENCY ERROR: Missing setting EXTRUDE_MINTEMP #error DEPENDENCY ERROR: Missing setting EXTRUDE_MINTEMP
...@@ -374,9 +375,6 @@ ...@@ -374,9 +375,6 @@
#if DISABLED(D_FILAMENT) #if DISABLED(D_FILAMENT)
#error DEPENDENCY ERROR: Missing setting D_FILAMENT #error DEPENDENCY ERROR: Missing setting D_FILAMENT
#endif #endif
#if DISABLED(STEPS_MM_E)
#error DEPENDENCY ERROR: Missing setting STEPS_MM_E
#endif
#endif #endif
#if ENABLED(FILAMENTCHANGEENABLE) #if ENABLED(FILAMENTCHANGEENABLE)
......
...@@ -3094,7 +3094,7 @@ uint8_t Sd2Card::cardCommand(uint8_t cmd, uint32_t arg) { ...@@ -3094,7 +3094,7 @@ uint8_t Sd2Card::cardCommand(uint8_t cmd, uint32_t arg) {
spiSend(cmd == CMD0 ? 0X95 : 0X87); spiSend(cmd == CMD0 ? 0X95 : 0X87);
#endif // USE_SD_CRC #endif // USE_SD_CRC
// additional delay for CMD0 // additional delay for CMD0
if (cmd == CMD0) delay(100); if (cmd == CMD0) HAL::delayMilliseconds(100);
// skip stuff byte for stop read // skip stuff byte for stop read
if (cmd == CMD12) spiRec(); if (cmd == CMD12) spiRec();
...@@ -4272,28 +4272,6 @@ void SdFile::writeln_P(PGM_P str) { ...@@ -4272,28 +4272,6 @@ void SdFile::writeln_P(PGM_P str) {
// ================ SdFatUtil.cpp =================== // ================ SdFatUtil.cpp ===================
//------------------------------------------------------------------------------
/** Amount of free RAM
* \return The number of free bytes.
*/
int SdFatUtil::FreeRam() {
extern int __bss_end;
extern int* __brkval;
int free_memory;
if (reinterpret_cast<int>(__brkval) == 0) {
// if no heap use from end of bss section
free_memory = reinterpret_cast<int>(&free_memory)
- reinterpret_cast<int>(&__bss_end);
}
else {
// use from top of stack to heap
free_memory = reinterpret_cast<int>(&free_memory)
- reinterpret_cast<int>(__brkval);
}
return free_memory;
}
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
/** %Print a string in flash memory to Serial. /** %Print a string in flash memory to Serial.
* *
......
...@@ -2011,7 +2011,6 @@ class SdFile : public SdBaseFile { ...@@ -2011,7 +2011,6 @@ class SdFile : public SdBaseFile {
}; };
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
namespace SdFatUtil { namespace SdFatUtil {
int FreeRam();
void SerialPrint_P(PGM_P str); void SerialPrint_P(PGM_P str);
void SerialPrintln_P(PGM_P str); void SerialPrintln_P(PGM_P str);
} }
......
...@@ -27,6 +27,6 @@ ...@@ -27,6 +27,6 @@
kill(PSTR("ERR:Please Reset")); //kill blocks //16 characters so it fits on a 16x2 display kill(PSTR("ERR:Please Reset")); //kill blocks //16 characters so it fits on a 16x2 display
while (1); //wait for user or serial reset while (1); //wait for user or serial reset
} }
#endif //WATCHDOG_RESET_MANUAL #endif // WATCHDOG_RESET_MANUAL
#endif //USE_WATCHDOG #endif // USE_WATCHDOG
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment