Browse Source

Fix broken TOGGLE macro in fastio.h

Scott Lahteine 7 years ago
parent
commit
4542282f5e
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      Marlin/fastio.h

+ 1
- 1
Marlin/fastio.h View File

66
 #define _WRITE(IO, v)  do {  if (&(DIO ##  IO ## _RPORT) >= (uint8_t *)0x100) {_WRITE_C(IO, v); } else {_WRITE_NC(IO, v); }; } while (0)
66
 #define _WRITE(IO, v)  do {  if (&(DIO ##  IO ## _RPORT) >= (uint8_t *)0x100) {_WRITE_C(IO, v); } else {_WRITE_NC(IO, v); }; } while (0)
67
 
67
 
68
 /// toggle a pin
68
 /// toggle a pin
69
-#define _TOGGLE(IO)  do {DIO ##  IO ## _RPORT = MASK(DIO ## IO ## _PIN); } while (0)
69
+#define _TOGGLE(IO)  do {DIO ##  IO ## _RPORT ^= MASK(DIO ## IO ## _PIN); } while (0)
70
 
70
 
71
 /// set pin as input
71
 /// set pin as input
72
 #define _SET_INPUT(IO) do {DIO ##  IO ## _DDR &= ~MASK(DIO ## IO ## _PIN); } while (0)
72
 #define _SET_INPUT(IO) do {DIO ##  IO ## _DDR &= ~MASK(DIO ## IO ## _PIN); } while (0)

Loading…
Cancel
Save