aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/platforms/STM32/can_lld.h
diff options
context:
space:
mode:
authorgdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2013-05-11 10:49:57 +0000
committergdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2013-05-11 10:49:57 +0000
commitc52a2b3f1a10b117bd7e3fb02f9828739ba77c4d (patch)
treeac7273e039d064ba0f2f9c4baf05dbf2b7e83614 /os/hal/platforms/STM32/can_lld.h
parent75628f0e79fd2bacd3e1eb0f31cd4eb6a3a32450 (diff)
downloadChibiOS-c52a2b3f1a10b117bd7e3fb02f9828739ba77c4d.tar.gz
ChibiOS-c52a2b3f1a10b117bd7e3fb02f9828739ba77c4d.tar.bz2
ChibiOS-c52a2b3f1a10b117bd7e3fb02f9828739ba77c4d.zip
STM32 CAN driver, added assertions and checks.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@5710 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/platforms/STM32/can_lld.h')
-rw-r--r--os/hal/platforms/STM32/can_lld.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/os/hal/platforms/STM32/can_lld.h b/os/hal/platforms/STM32/can_lld.h
index 44906b7ed..c339c01e7 100644
--- a/os/hal/platforms/STM32/can_lld.h
+++ b/os/hal/platforms/STM32/can_lld.h
@@ -128,6 +128,10 @@
#error "CAN driver activated but no CAN peripheral assigned"
#endif
+#if !STM32_CAN_USE_CAN1 && STM32_CAN_USE_CAN2
+#error "CAN2 requires CAN1, it cannot operate independently"
+#endif
+
#if CAN_USE_SLEEP_MODE && !CAN_SUPPORTS_SLEEP
#error "CAN sleep mode not supported in this architecture"
#endif