From d264541a3e7fe756695f811136d7a89e8e7ec478 Mon Sep 17 00:00:00 2001 From: Leo C Date: Thu, 23 Apr 2015 02:28:53 +0200 Subject: loadi seems to work now. --- include/common.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include/common.h') diff --git a/include/common.h b/include/common.h index cfbbae5..10c4417 100644 --- a/include/common.h +++ b/include/common.h @@ -52,6 +52,12 @@ struct bits { #define FSTR(X) ((const FLASH char[]) { X } ) #define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0])) +#define MIN(a,b) ({ typeof (a) _a = (a); \ + typeof (b) _b = (b); \ + _a < _b ? _a : _b; }) +#define MAX(a,b) ({ typeof (a) _a = (a); \ + typeof (b) _b = (b); \ + _a > _b ? _a : _b; }) #ifdef __AVR__ #define Stat GPIOR0 -- cgit v1.2.3