Skip to content

Commit b51beed

Browse files
author
Toni Klopfenstein
committed
Merge branch 'patch-1' of https://github.com/MusicalCreeper01/Edison_OLED_Block into MusicalCreeper01-patch-1
2 parents 95a49c3 + db6254e commit b51beed

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Firmware/pong/oled/Edison_OLED.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -439,14 +439,14 @@ void edOLED::line(unsigned char x0, unsigned char y0, unsigned char x1, unsigned
439439
unsigned char steep = abs(y1 - y0) > abs(x1 - x0);
440440
if (steep)
441441
{
442-
swap(x0, y0);
443-
swap(x1, y1);
442+
swapOLED(x0, y0);
443+
swapOLED(x1, y1);
444444
}
445445

446446
if (x0 > x1)
447447
{
448-
swap(x0, x1);
449-
swap(y0, y1);
448+
swapOLED(x0, x1);
449+
swapOLED(y0, y1);
450450
}
451451

452452
unsigned char dx, dy;

Firmware/pong/oled/Edison_OLED.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
#ifndef EDISON_OLED_H
2727
#define EDISON_OLED_H
2828

29-
#define swap(a, b) { unsigned char t = a; a = b; b = t; }
29+
#define swapOLED(a, b) { unsigned char t = a; a = b; b = t; }
3030

3131
#define BLACK 0
3232
#define WHITE 1

0 commit comments

Comments
 (0)