summaryrefslogtreecommitdiff
path: root/hw/bsp
diff options
context:
space:
mode:
authorhathach <[email protected]>2023-01-18 10:31:00 +0700
committerhathach <[email protected]>2023-01-18 10:31:00 +0700
commitecfd57e6f12b16c1d7f8cfe2ff6b70e387b38119 (patch)
tree59ccf79055ade5c52da116b314770330f11de177 /hw/bsp
parent8df2fd1916d5e69cfaad7516399a8d7da5060f57 (diff)
get most examples build with iar
Diffstat (limited to 'hw/bsp')
-rw-r--r--hw/bsp/board.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/hw/bsp/board.c b/hw/bsp/board.c
index 7e96735bd..14858c2b6 100644
--- a/hw/bsp/board.c
+++ b/hw/bsp/board.c
@@ -77,8 +77,10 @@ void board_led_task(void)
//--------------------------------------------------------------------+
// newlib read()/write() retarget
//--------------------------------------------------------------------+
-
-#if defined(__MSP430__) || defined(__RX__)
+#ifdef __ICCARM__
+ #define sys_write __write
+ #define sys_read __read
+#elif defined(__MSP430__) || defined(__RX__)
#define sys_write write
#define sys_read read
#else