Skip to content

Commit

Permalink
Allow compiling against MP <= 1.12
Browse files Browse the repository at this point in the history
  • Loading branch information
devbis committed Jun 25, 2020
1 parent 1243fa0 commit 4707890
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions st7789/st7789.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,11 @@

#include "st7789.h"

// allow compiling against MP <=1.12
#ifndef MP_ERROR_TEXT
#define MP_ERROR_TEXT(a) a
#endif

#define _swap_int16_t(a, b) { int16_t t = a; a = b; b = t; }
#define ABS(N) (((N)<0)?(-(N)):(N))
#define mp_hal_delay_ms(delay) (mp_hal_delay_us(delay * 1000))
Expand Down

0 comments on commit 4707890

Please sign in to comment.