Browse Source

Tweaks for M43

Scott Lahteine 7 years ago
parent
commit
5ef1e5ef60
2 changed files with 15 additions and 11 deletions
  1. 11
    11
      Marlin/Marlin_main.cpp
  2. 4
    0
      Marlin/fastio_AT90USB.h

+ 11
- 11
Marlin/Marlin_main.cpp View File

6474
       else {
6474
       else {
6475
         report_pin_state_extended(pin, I_flag, true, "Pulsing   ");
6475
         report_pin_state_extended(pin, I_flag, true, "Pulsing   ");
6476
         #if AVR_AT90USB1286_FAMILY // Teensy IDEs don't know about these pins so must use FASTIO
6476
         #if AVR_AT90USB1286_FAMILY // Teensy IDEs don't know about these pins so must use FASTIO
6477
-          if (pin == 46) {
6478
-            SET_OUTPUT(46);
6477
+          if (pin == TEENSY_E2) {
6478
+            SET_OUTPUT(TEENSY_E2);
6479
             for (int16_t j = 0; j < repeat; j++) {
6479
             for (int16_t j = 0; j < repeat; j++) {
6480
-              WRITE(46, 0); safe_delay(wait);
6481
-              WRITE(46, 1); safe_delay(wait);
6482
-              WRITE(46, 0); safe_delay(wait);
6480
+              WRITE(TEENSY_E2, LOW);  safe_delay(wait);
6481
+              WRITE(TEENSY_E2, HIGH); safe_delay(wait);
6482
+              WRITE(TEENSY_E2, LOW);  safe_delay(wait);
6483
             }
6483
             }
6484
           }
6484
           }
6485
-          else if (pin == 47) {
6486
-            SET_OUTPUT(47);
6485
+          else if (pin == TEENSY_E3) {
6486
+            SET_OUTPUT(TEENSY_E3);
6487
             for (int16_t j = 0; j < repeat; j++) {
6487
             for (int16_t j = 0; j < repeat; j++) {
6488
-              WRITE(47, 0); safe_delay(wait);
6489
-              WRITE(47, 1); safe_delay(wait);
6490
-              WRITE(47, 0); safe_delay(wait);
6488
+              WRITE(TEENSY_E3, LOW);  safe_delay(wait);
6489
+              WRITE(TEENSY_E3, HIGH); safe_delay(wait);
6490
+              WRITE(TEENSY_E3, LOW);  safe_delay(wait);
6491
             }
6491
             }
6492
           }
6492
           }
6493
           else
6493
           else
6671
     if (parser.seen('E')) {
6671
     if (parser.seen('E')) {
6672
       endstop_monitor_flag = parser.value_bool();
6672
       endstop_monitor_flag = parser.value_bool();
6673
       SERIAL_PROTOCOLPGM("endstop monitor ");
6673
       SERIAL_PROTOCOLPGM("endstop monitor ");
6674
-      SERIAL_PROTOCOL(endstop_monitor_flag ? "en" : "dis");
6674
+      serialprintPGM(endstop_monitor_flag ? PSTR("en") : PSTR("dis"));
6675
       SERIAL_PROTOCOLLNPGM("abled");
6675
       SERIAL_PROTOCOLLNPGM("abled");
6676
       return;
6676
       return;
6677
     }
6677
     }

+ 4
- 0
Marlin/fastio_AT90USB.h View File

382
 #define DIO47_WPORT PORTE
382
 #define DIO47_WPORT PORTE
383
 #define DIO47_PWM   NULL
383
 #define DIO47_PWM   NULL
384
 #define DIO47_DDR   DDRE
384
 #define DIO47_DDR   DDRE
385
+
386
+#define TEENSY_E2   46
387
+#define TEENSY_E3   47
388
+
385
 //-- end not supported by Teensyduino
389
 //-- end not supported by Teensyduino
386
 
390
 
387
 #undef PA0
391
 #undef PA0

Loading…
Cancel
Save