aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/platforms/SPC563Mxx/hal_lld.h
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal/platforms/SPC563Mxx/hal_lld.h')
-rw-r--r--os/hal/platforms/SPC563Mxx/hal_lld.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/os/hal/platforms/SPC563Mxx/hal_lld.h b/os/hal/platforms/SPC563Mxx/hal_lld.h
index eec53fd5a..705b94201 100644
--- a/os/hal/platforms/SPC563Mxx/hal_lld.h
+++ b/os/hal/platforms/SPC563Mxx/hal_lld.h
@@ -169,6 +169,13 @@
BIUCR_BFEN)
#endif
+/**
+ * @brief eMIOS global prescaler value.
+ */
+#if !defined(SPC5_EMIOS_GPRE_VALUE) || defined(__DOXYGEN__)
+#define SPC5_EMIOS_GPRE_VALUE 20
+#endif
+
/*===========================================================================*/
/* Derived constants and error checks. */
/*===========================================================================*/
@@ -193,6 +200,10 @@
#error "invalid SPC5_CLK_RFD value specified"
#endif
+#if (SPC5_EMIOS_GPRE_VALUE < 1) || (SPC5_EMIOS_GPRE_VALUE > 256)
+#error "invalid SPC5_EMIOS_GPRE_VALUE value specified"
+#endif
+
/**
* @brief PLL input divider.
*/
@@ -239,6 +250,11 @@
#define SPC5_FLASH_WS (BIUCR_APC_3 | BIUCR_RWSC_3 | BIUCR_WWSC_1)
#endif
+/**
+ * @brief eMIOS global prescaler setting.
+ */
+#define SPC5_EMIOS_GPRE (SPC5_EMIOS_GPRE_VALUE << 8)
+
/*===========================================================================*/
/* Driver data structures and types. */
/*===========================================================================*/