| … | … | @@ -23,6 +23,9 @@ |
| 23 | 23 | */ |
| 24 | 24 | #include "SC.h" |
| 25 | 25 | |
| 26 | #define MAX(x, y) (((x) > (y)) ? (x) : (y)) |
| 27 | #define MIN(x, y) (((x) < (y)) ? (x) : (y)) |
| 28 | |
| 26 | 29 | /** |
| 27 | 30 | * Constructor makes sure some things are set. |
| 28 | 31 | */ |
| … | … | @@ -146,7 +149,7 @@ void SerialCommand::handleChar(char inChar) { |
| 146 | 149 | } |
| 147 | 150 | |
| 148 | 151 | void SerialCommand::enterBinaryMode(int numBytes, void (*function)(char*, int)) { |
| 149 | | numBinaryBytes = min(sizeof(buffer), numBytes); |
| 152 | numBinaryBytes = MIN(sizeof(buffer), numBytes); |
| 150 | 153 | binaryDone = function; |
| 151 | 154 | clearBuffer(); |
| 152 | 155 | } |