]> rtime.felk.cvut.cz Git - pes-rpp/rpp-lib.git/commitdiff
Allow compilation without Ethernet
authorMichal Sojka <sojkam1@fel.cvut.cz>
Thu, 17 Jul 2014 07:29:43 +0000 (09:29 +0200)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Mon, 21 Jul 2014 15:23:05 +0000 (17:23 +0200)
This saves about 60 kB in flash.

Now it is possible to define rppCONFIG_INCLUDE_ETH as 0 in RppConfig.h and
everything can compiles without problems.

rpp/src/sys/notification.c
rpp/src/sys/sys_startup.c

index a56e465d86ae8d3aaa7fc18bd8a490f41323535a..497bc4789bf0b9c0474a355033165482a75e4154 100644 (file)
@@ -26,6 +26,7 @@
 //#include "os_semphr.h"
 //#include "os_task.h"
 
+#include "rpp/RppConfig.h"
 #include "sys/sys.h"
 #include "rpp/eth.h"
 
@@ -261,6 +262,7 @@ void linNotification(linBASE_t *lin, uint32_t flags)
     }
 }
 
+#if rppCONFIG_INCLUDE_ETH
 extern boolean_t HostPendErrHandler(void);
 #if PHY_LINK_MONITOR_INT
 extern boolean_t LinkIntHandler(void);
@@ -308,6 +310,7 @@ void EMACCore0TxIsr(void)
     }
     */
 }
+#endif
 
 /* USER CODE BEGIN (38) */
 /* USER CODE END */
index 0aa89bb8391c580a702494af8bc9bc4497fe5f78..adee2b2f352386faaf343f0fa2c5dd60845360cf 100644 (file)
 #include "sys/sys_core.h"
 #include "sys/sys_selftest.h"
 #include "sys/ti_drv_esm.h"
+#include "rpp/RppConfig.h"
 
+#if !rppCONFIG_INCLUDE_ETH
+#define MDIOMiscInt    phantomInterrupt
+#define EMACCore0RxIsr phantomInterrupt
+#define EMACCore0TxIsr phantomInterrupt
+#endif
 
 /* USER CODE BEGIN (1) */
 /* USER CODE END */