aboutsummaryrefslogtreecommitdiffstats
path: root/demos
diff options
context:
space:
mode:
authorgdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2011-08-13 15:40:57 +0000
committergdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2011-08-13 15:40:57 +0000
commit5cee2c08d787d1b14c62d5595b72644a773fe443 (patch)
tree50032e24ab9522de3a828493a8a69681fab1f2ae /demos
parent978e34eed2ed391f57b25e007b63f2938f8af0f6 (diff)
downloadChibiOS-5cee2c08d787d1b14c62d5595b72644a773fe443.tar.gz
ChibiOS-5cee2c08d787d1b14c62d5595b72644a773fe443.tar.bz2
ChibiOS-5cee2c08d787d1b14c62d5595b72644a773fe443.zip
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@3226 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'demos')
-rw-r--r--demos/ARM7-AT91SAM7S-FATFS-GCC/chconf.h10
-rw-r--r--demos/ARM7-AT91SAM7S-GCC/chconf.h10
-rw-r--r--demos/ARM7-AT91SAM7X-FATFS-GCC/chconf.h10
-rw-r--r--demos/ARM7-AT91SAM7X-GCC/chconf.h10
-rw-r--r--demos/ARM7-AT91SAM7X-LWIP-GCC/chconf.h10
-rw-r--r--demos/ARM7-AT91SAM7X-UIP-GCC/chconf.h10
-rw-r--r--demos/ARM7-LPC214x-FATFS-GCC/chconf.h10
-rw-r--r--demos/ARM7-LPC214x-G++/chconf.h10
-rw-r--r--demos/ARM7-LPC214x-GCC/chconf.h10
-rw-r--r--demos/ARMCM0-LPC1114-LPCXPRESSO/chconf.h10
-rw-r--r--demos/ARMCM3-LPC1343-LPCXPRESSO/chconf.h10
-rw-r--r--demos/ARMCM3-STM32F100-DISCOVERY/chconf.h10
-rw-r--r--demos/ARMCM3-STM32F103-FATFS/chconf.h10
-rw-r--r--demos/ARMCM3-STM32F103-G++/chconf.h10
-rw-r--r--demos/ARMCM3-STM32F103/chconf.h10
-rw-r--r--demos/ARMCM3-STM32F103ZG-FATFS/chconf.h10
-rw-r--r--demos/ARMCM3-STM32F107/chconf.h10
-rw-r--r--demos/ARMCM3-STM32L152-DISCOVERY/chconf.h10
-rw-r--r--demos/AVR-AT90CANx-GCC/chconf.h10
-rw-r--r--demos/AVR-ATmega128-GCC/chconf.h10
-rw-r--r--demos/MSP430-MSP430x1611-GCC/chconf.h10
-rw-r--r--demos/PPC-SPC563-GCC/chconf.h10
-rw-r--r--demos/Posix-GCC/chconf.h11
-rw-r--r--demos/STM8L-STM8L152-DISCOVERY-STVD/demo/chconf.h10
-rw-r--r--demos/STM8S-STM8S105-DISCOVERY-STVD/demo/chconf.h10
-rw-r--r--demos/STM8S-STM8S208-RC/chconf.h10
-rw-r--r--demos/Win32-MinGW/chconf.h11
27 files changed, 272 insertions, 0 deletions
diff --git a/demos/ARM7-AT91SAM7S-FATFS-GCC/chconf.h b/demos/ARM7-AT91SAM7S-FATFS-GCC/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARM7-AT91SAM7S-FATFS-GCC/chconf.h
+++ b/demos/ARM7-AT91SAM7S-FATFS-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARM7-AT91SAM7S-GCC/chconf.h b/demos/ARM7-AT91SAM7S-GCC/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARM7-AT91SAM7S-GCC/chconf.h
+++ b/demos/ARM7-AT91SAM7S-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARM7-AT91SAM7X-FATFS-GCC/chconf.h b/demos/ARM7-AT91SAM7X-FATFS-GCC/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARM7-AT91SAM7X-FATFS-GCC/chconf.h
+++ b/demos/ARM7-AT91SAM7X-FATFS-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARM7-AT91SAM7X-GCC/chconf.h b/demos/ARM7-AT91SAM7X-GCC/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARM7-AT91SAM7X-GCC/chconf.h
+++ b/demos/ARM7-AT91SAM7X-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARM7-AT91SAM7X-LWIP-GCC/chconf.h b/demos/ARM7-AT91SAM7X-LWIP-GCC/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARM7-AT91SAM7X-LWIP-GCC/chconf.h
+++ b/demos/ARM7-AT91SAM7X-LWIP-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARM7-AT91SAM7X-UIP-GCC/chconf.h b/demos/ARM7-AT91SAM7X-UIP-GCC/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARM7-AT91SAM7X-UIP-GCC/chconf.h
+++ b/demos/ARM7-AT91SAM7X-UIP-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARM7-LPC214x-FATFS-GCC/chconf.h b/demos/ARM7-LPC214x-FATFS-GCC/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARM7-LPC214x-FATFS-GCC/chconf.h
+++ b/demos/ARM7-LPC214x-FATFS-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARM7-LPC214x-G++/chconf.h b/demos/ARM7-LPC214x-G++/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARM7-LPC214x-G++/chconf.h
+++ b/demos/ARM7-LPC214x-G++/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARM7-LPC214x-GCC/chconf.h b/demos/ARM7-LPC214x-GCC/chconf.h
index eb4087969..a5d129956 100644
--- a/demos/ARM7-LPC214x-GCC/chconf.h
+++ b/demos/ARM7-LPC214x-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARMCM0-LPC1114-LPCXPRESSO/chconf.h b/demos/ARMCM0-LPC1114-LPCXPRESSO/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARMCM0-LPC1114-LPCXPRESSO/chconf.h
+++ b/demos/ARMCM0-LPC1114-LPCXPRESSO/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARMCM3-LPC1343-LPCXPRESSO/chconf.h b/demos/ARMCM3-LPC1343-LPCXPRESSO/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARMCM3-LPC1343-LPCXPRESSO/chconf.h
+++ b/demos/ARMCM3-LPC1343-LPCXPRESSO/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARMCM3-STM32F100-DISCOVERY/chconf.h b/demos/ARMCM3-STM32F100-DISCOVERY/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARMCM3-STM32F100-DISCOVERY/chconf.h
+++ b/demos/ARMCM3-STM32F100-DISCOVERY/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARMCM3-STM32F103-FATFS/chconf.h b/demos/ARMCM3-STM32F103-FATFS/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARMCM3-STM32F103-FATFS/chconf.h
+++ b/demos/ARMCM3-STM32F103-FATFS/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARMCM3-STM32F103-G++/chconf.h b/demos/ARMCM3-STM32F103-G++/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARMCM3-STM32F103-G++/chconf.h
+++ b/demos/ARMCM3-STM32F103-G++/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARMCM3-STM32F103/chconf.h b/demos/ARMCM3-STM32F103/chconf.h
index eb4087969..a5d129956 100644
--- a/demos/ARMCM3-STM32F103/chconf.h
+++ b/demos/ARMCM3-STM32F103/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARMCM3-STM32F103ZG-FATFS/chconf.h b/demos/ARMCM3-STM32F103ZG-FATFS/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARMCM3-STM32F103ZG-FATFS/chconf.h
+++ b/demos/ARMCM3-STM32F103ZG-FATFS/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARMCM3-STM32F107/chconf.h b/demos/ARMCM3-STM32F107/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARMCM3-STM32F107/chconf.h
+++ b/demos/ARMCM3-STM32F107/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/ARMCM3-STM32L152-DISCOVERY/chconf.h b/demos/ARMCM3-STM32L152-DISCOVERY/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/ARMCM3-STM32L152-DISCOVERY/chconf.h
+++ b/demos/ARMCM3-STM32L152-DISCOVERY/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/AVR-AT90CANx-GCC/chconf.h b/demos/AVR-AT90CANx-GCC/chconf.h
index cb22265a2..7a50c5b5a 100644
--- a/demos/AVR-AT90CANx-GCC/chconf.h
+++ b/demos/AVR-AT90CANx-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/AVR-ATmega128-GCC/chconf.h b/demos/AVR-ATmega128-GCC/chconf.h
index cb22265a2..7a50c5b5a 100644
--- a/demos/AVR-ATmega128-GCC/chconf.h
+++ b/demos/AVR-ATmega128-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/MSP430-MSP430x1611-GCC/chconf.h b/demos/MSP430-MSP430x1611-GCC/chconf.h
index 51b833cc2..058dd1cb3 100644
--- a/demos/MSP430-MSP430x1611-GCC/chconf.h
+++ b/demos/MSP430-MSP430x1611-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/PPC-SPC563-GCC/chconf.h b/demos/PPC-SPC563-GCC/chconf.h
index 6a365d96a..9dd831c96 100644
--- a/demos/PPC-SPC563-GCC/chconf.h
+++ b/demos/PPC-SPC563-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/Posix-GCC/chconf.h b/demos/Posix-GCC/chconf.h
index 4572090b0..fa22f7210 100644
--- a/demos/Posix-GCC/chconf.h
+++ b/demos/Posix-GCC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
@@ -503,6 +513,7 @@
}
#endif
+
/**
* @brief System halt hook.
* @details This hook is invoked in case to a system halting error before
diff --git a/demos/STM8L-STM8L152-DISCOVERY-STVD/demo/chconf.h b/demos/STM8L-STM8L152-DISCOVERY-STVD/demo/chconf.h
index d7a106c5b..c004cf310 100644
--- a/demos/STM8L-STM8L152-DISCOVERY-STVD/demo/chconf.h
+++ b/demos/STM8L-STM8L152-DISCOVERY-STVD/demo/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/STM8S-STM8S105-DISCOVERY-STVD/demo/chconf.h b/demos/STM8S-STM8S105-DISCOVERY-STVD/demo/chconf.h
index d7a106c5b..c004cf310 100644
--- a/demos/STM8S-STM8S105-DISCOVERY-STVD/demo/chconf.h
+++ b/demos/STM8S-STM8S105-DISCOVERY-STVD/demo/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/STM8S-STM8S208-RC/chconf.h b/demos/STM8S-STM8S208-RC/chconf.h
index d7a106c5b..c004cf310 100644
--- a/demos/STM8S-STM8S208-RC/chconf.h
+++ b/demos/STM8S-STM8S208-RC/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
diff --git a/demos/Win32-MinGW/chconf.h b/demos/Win32-MinGW/chconf.h
index 4572090b0..fa22f7210 100644
--- a/demos/Win32-MinGW/chconf.h
+++ b/demos/Win32-MinGW/chconf.h
@@ -483,6 +483,16 @@
#endif
/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#if !defined(THREAD_CONTEXT_SWITCH_HOOK) || defined(__DOXYGEN__)
+#define THREAD_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* System halt code here.*/ \
+}
+#endif
+
+/**
* @brief Idle Loop hook.
* @details This hook is continuously invoked by the idle thread loop.
*/
@@ -503,6 +513,7 @@
}
#endif
+
/**
* @brief System halt hook.
* @details This hook is invoked in case to a system halting error before