aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/templates
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal/templates')
-rw-r--r--os/hal/templates/adc_lld.c4
-rw-r--r--os/hal/templates/adc_lld.h4
-rw-r--r--os/hal/templates/can_lld.c4
-rw-r--r--os/hal/templates/can_lld.h4
-rw-r--r--os/hal/templates/halconf.h40
-rw-r--r--os/hal/templates/i2c_lld.c4
-rw-r--r--os/hal/templates/i2c_lld.h4
-rw-r--r--os/hal/templates/mac_lld.c4
-rw-r--r--os/hal/templates/mac_lld.h4
-rw-r--r--os/hal/templates/meta/driver.c4
-rw-r--r--os/hal/templates/meta/driver.h4
-rw-r--r--os/hal/templates/meta/driver_lld.c4
-rw-r--r--os/hal/templates/meta/driver_lld.h4
-rw-r--r--os/hal/templates/pal_lld.c4
-rw-r--r--os/hal/templates/pal_lld.h4
-rw-r--r--os/hal/templates/pwm_lld.c4
-rw-r--r--os/hal/templates/pwm_lld.h4
-rw-r--r--os/hal/templates/serial_lld.c4
-rw-r--r--os/hal/templates/serial_lld.h4
-rw-r--r--os/hal/templates/spi_lld.c4
-rw-r--r--os/hal/templates/spi_lld.h4
-rw-r--r--os/hal/templates/uart_lld.c4
-rw-r--r--os/hal/templates/uart_lld.h8
23 files changed, 70 insertions, 62 deletions
diff --git a/os/hal/templates/adc_lld.c b/os/hal/templates/adc_lld.c
index 5ea8e9585..54622beb7 100644
--- a/os/hal/templates/adc_lld.c
+++ b/os/hal/templates/adc_lld.c
@@ -28,7 +28,7 @@
#include "ch.h"
#include "hal.h"
-#if CH_HAL_USE_ADC || defined(__DOXYGEN__)
+#if HAL_USE_ADC || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver exported variables. */
@@ -107,6 +107,6 @@ void adc_lld_stop_conversion(ADCDriver *adcp) {
}
-#endif /* CH_HAL_USE_ADC */
+#endif /* HAL_USE_ADC */
/** @} */
diff --git a/os/hal/templates/adc_lld.h b/os/hal/templates/adc_lld.h
index dc2c76f07..c85a1bd77 100644
--- a/os/hal/templates/adc_lld.h
+++ b/os/hal/templates/adc_lld.h
@@ -28,7 +28,7 @@
#ifndef _ADC_LLD_H_
#define _ADC_LLD_H_
-#if CH_HAL_USE_ADC || defined(__DOXYGEN__)
+#if HAL_USE_ADC || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver constants. */
@@ -179,7 +179,7 @@ extern "C" {
}
#endif
-#endif /* CH_HAL_USE_ADC */
+#endif /* HAL_USE_ADC */
#endif /* _ADC_LLD_H_ */
diff --git a/os/hal/templates/can_lld.c b/os/hal/templates/can_lld.c
index ae5fab9d7..2dc92f169 100644
--- a/os/hal/templates/can_lld.c
+++ b/os/hal/templates/can_lld.c
@@ -28,7 +28,7 @@
#include "ch.h"
#include "hal.h"
-#if CH_HAL_USE_CAN || defined(__DOXYGEN__)
+#if HAL_USE_CAN || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver exported variables. */
@@ -164,6 +164,6 @@ void can_lld_wakeup(CANDriver *canp) {
}
#endif /* CAN_USE_SLEEP_MODE */
-#endif /* CH_HAL_USE_CAN */
+#endif /* HAL_USE_CAN */
/** @} */
diff --git a/os/hal/templates/can_lld.h b/os/hal/templates/can_lld.h
index 312a664f6..37ce7f157 100644
--- a/os/hal/templates/can_lld.h
+++ b/os/hal/templates/can_lld.h
@@ -28,7 +28,7 @@
#ifndef _CAN_LLD_H_
#define _CAN_LLD_H_
-#if CH_HAL_USE_CAN || defined(__DOXYGEN__)
+#if HAL_USE_CAN || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver constants. */
@@ -229,7 +229,7 @@ extern "C" {
}
#endif
-#endif /* CH_HAL_USE_CAN */
+#endif /* HAL_USE_CAN */
#endif /* _CAN_LLD_H_ */
diff --git a/os/hal/templates/halconf.h b/os/hal/templates/halconf.h
index 74234dfa0..71f21c206 100644
--- a/os/hal/templates/halconf.h
+++ b/os/hal/templates/halconf.h
@@ -40,71 +40,71 @@
/**
* @brief Enables the PAL subsystem.
*/
-#if !defined(CH_HAL_USE_PAL) || defined(__DOXYGEN__)
-#define CH_HAL_USE_PAL TRUE
+#if !defined(HAL_USE_PAL) || defined(__DOXYGEN__)
+#define HAL_USE_PAL TRUE
#endif
/**
* @brief Enables the ADC subsystem.
*/
-#if !defined(CH_HAL_USE_ADC) || defined(__DOXYGEN__)
-#define CH_HAL_USE_ADC TRUE
+#if !defined(HAL_USE_ADC) || defined(__DOXYGEN__)
+#define HAL_USE_ADC TRUE
#endif
/**
* @brief Enables the CAN subsystem.
*/
-#if !defined(CH_HAL_USE_CAN) || defined(__DOXYGEN__)
-#define CH_HAL_USE_CAN TRUE
+#if !defined(HAL_USE_CAN) || defined(__DOXYGEN__)
+#define HAL_USE_CAN TRUE
#endif
/**
* @brief Enables the I2C subsystem.
*/
-#if !defined(CH_HAL_USE_I2C) || defined(__DOXYGEN__)
-#define CH_HAL_USE_I2C FALSE
+#if !defined(HAL_USE_I2C) || defined(__DOXYGEN__)
+#define HAL_USE_I2C FALSE
#endif
/**
* @brief Enables the MAC subsystem.
*/
-#if !defined(CH_HAL_USE_MAC) || defined(__DOXYGEN__)
-#define CH_HAL_USE_MAC TRUE
+#if !defined(HAL_USE_MAC) || defined(__DOXYGEN__)
+#define HAL_USE_MAC TRUE
#endif
/**
* @brief Enables the MMC_SPI subsystem.
*/
-#if !defined(CH_HAL_USE_MMC_SPI) || defined(__DOXYGEN__)
-#define CH_HAL_USE_MMC_SPI TRUE
+#if !defined(HAL_USE_MMC_SPI) || defined(__DOXYGEN__)
+#define HAL_USE_MMC_SPI TRUE
#endif
/**
* @brief Enables the PWM subsystem.
*/
-#if !defined(CH_HAL_USE_PWM) || defined(__DOXYGEN__)
-#define CH_HAL_USE_PWM TRUE
+#if !defined(HAL_USE_PWM) || defined(__DOXYGEN__)
+#define HAL_USE_PWM TRUE
#endif
/**
* @brief Enables the SERIAL subsystem.
*/
-#if !defined(CH_HAL_USE_SERIAL) || defined(__DOXYGEN__)
-#define CH_HAL_USE_SERIAL TRUE
+#if !defined(HAL_USE_SERIAL) || defined(__DOXYGEN__)
+#define HAL_USE_SERIAL TRUE
#endif
/**
* @brief Enables the SPI subsystem.
*/
-#if !defined(CH_HAL_USE_SPI) || defined(__DOXYGEN__)
-#define CH_HAL_USE_SPI TRUE
+#if !defined(HAL_USE_SPI) || defined(__DOXYGEN__)
+#define HAL_USE_SPI TRUE
#endif
/**
* @brief Enables the UART subsystem.
*/
-#if !defined(CH_HAL_USE_UART) || defined(__DOXYGEN__)
-#define CH_HAL_USE_UART TRUE
+#if !defined(HAL_USE_UART) || defined(__DOXYGEN__)
+#define HAL_USE_UART TRUE
#endif
/*===========================================================================*/
diff --git a/os/hal/templates/i2c_lld.c b/os/hal/templates/i2c_lld.c
index 8c8e47b76..d41f693ab 100644
--- a/os/hal/templates/i2c_lld.c
+++ b/os/hal/templates/i2c_lld.c
@@ -28,7 +28,7 @@
#include "ch.h"
#include "hal.h"
-#if CH_HAL_USE_I2C || defined(__DOXYGEN__)
+#if HAL_USE_I2C || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver exported variables. */
@@ -149,6 +149,6 @@ void i2c_lld_master_receive(I2CDriver *i2cp, size_t n, uint8_t *rxbuf) {
}
-#endif /* CH_HAL_USE_I2C */
+#endif /* HAL_USE_I2C */
/** @} */
diff --git a/os/hal/templates/i2c_lld.h b/os/hal/templates/i2c_lld.h
index 29914705d..ea2b1a61e 100644
--- a/os/hal/templates/i2c_lld.h
+++ b/os/hal/templates/i2c_lld.h
@@ -28,7 +28,7 @@
#ifndef _I2C_LLD_H_
#define _I2C_LLD_H_
-#if CH_HAL_USE_I2C || defined(__DOXYGEN__)
+#if HAL_USE_I2C || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver constants. */
@@ -113,7 +113,7 @@ extern "C" {
}
#endif
-#endif /* CH_HAL_USE_I2C */
+#endif /* HAL_USE_I2C */
#endif /* _I2C_LLD_H_ */
diff --git a/os/hal/templates/mac_lld.c b/os/hal/templates/mac_lld.c
index b1fb040e6..8049f29ec 100644
--- a/os/hal/templates/mac_lld.c
+++ b/os/hal/templates/mac_lld.c
@@ -28,7 +28,7 @@
#include "ch.h"
#include "hal.h"
-#if CH_HAL_USE_MAC || defined(__DOXYGEN__)
+#if HAL_USE_MAC || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver exported variables. */
@@ -189,6 +189,6 @@ bool_t mac_lld_poll_link_status(MACDriver *macp) {
return FALSE;
}
-#endif /* CH_HAL_USE_MAC */
+#endif /* HAL_USE_MAC */
/** @} */
diff --git a/os/hal/templates/mac_lld.h b/os/hal/templates/mac_lld.h
index 0d3a68696..869fa5db8 100644
--- a/os/hal/templates/mac_lld.h
+++ b/os/hal/templates/mac_lld.h
@@ -28,7 +28,7 @@
#ifndef _MAC_LLD_H_
#define _MAC_LLD_H_
-#if CH_HAL_USE_MAC || defined(__DOXYGEN__)
+#if HAL_USE_MAC || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver constants. */
@@ -133,7 +133,7 @@ extern "C" {
}
#endif
-#endif /* CH_HAL_USE_MAC */
+#endif /* HAL_USE_MAC */
#endif /* _MAC_LLD_H_ */
diff --git a/os/hal/templates/meta/driver.c b/os/hal/templates/meta/driver.c
index d006d0fda..234f70e09 100644
--- a/os/hal/templates/meta/driver.c
+++ b/os/hal/templates/meta/driver.c
@@ -28,7 +28,7 @@
#include "ch.h"
#include "hal.h"
-#if CH_HAL_USE_XXX || defined(__DOXYGEN__)
+#if HAL_USE_XXX || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver exported variables. */
@@ -111,6 +111,6 @@ void xxxStop(XXXDriver *xxxp) {
chSysUnlock();
}
-#endif /* CH_HAL_USE_XXX */
+#endif /* HAL_USE_XXX */
/** @} */
diff --git a/os/hal/templates/meta/driver.h b/os/hal/templates/meta/driver.h
index a19406719..1014e871c 100644
--- a/os/hal/templates/meta/driver.h
+++ b/os/hal/templates/meta/driver.h
@@ -28,7 +28,7 @@
#ifndef _XXX_H_
#define _XXX_H_
-#if CH_HAL_USE_XXX || defined(__DOXYGEN__)
+#if HAL_USE_XXX || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver constants. */
@@ -76,7 +76,7 @@ extern "C" {
}
#endif
-#endif /* CH_HAL_USE_XXX */
+#endif /* HAL_USE_XXX */
#endif /* _XXX_H_ */
diff --git a/os/hal/templates/meta/driver_lld.c b/os/hal/templates/meta/driver_lld.c
index bbac5511e..051dfac03 100644
--- a/os/hal/templates/meta/driver_lld.c
+++ b/os/hal/templates/meta/driver_lld.c
@@ -28,7 +28,7 @@
#include "ch.h"
#include "hal.h"
-#if CH_HAL_USE_XXX || defined(__DOXYGEN__)
+#if HAL_USE_XXX || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver exported variables. */
@@ -85,6 +85,6 @@ void xxx_lld_stop(XXXDriver *xxxp) {
}
-#endif /* CH_HAL_USE_XXX */
+#endif /* HAL_USE_XXX */
/** @} */
diff --git a/os/hal/templates/meta/driver_lld.h b/os/hal/templates/meta/driver_lld.h
index 1392954a5..7d75bbaea 100644
--- a/os/hal/templates/meta/driver_lld.h
+++ b/os/hal/templates/meta/driver_lld.h
@@ -28,7 +28,7 @@
#ifndef _XXX_LLD_H_
#define _XXX_LLD_H_
-#if CH_HAL_USE_XXX || defined(__DOXYGEN__)
+#if HAL_USE_XXX || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver constants. */
@@ -93,7 +93,7 @@ extern "C" {
}
#endif
-#endif /* CH_HAL_USE_XXX */
+#endif /* HAL_USE_XXX */
#endif /* _XXX_LLD_H_ */
diff --git a/os/hal/templates/pal_lld.c b/os/hal/templates/pal_lld.c
index 2b2d17459..583b39236 100644
--- a/os/hal/templates/pal_lld.c
+++ b/os/hal/templates/pal_lld.c
@@ -28,7 +28,7 @@
#include "ch.h"
#include "hal.h"
-#if CH_HAL_USE_PAL || defined(__DOXYGEN__)
+#if HAL_USE_PAL || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver exported variables. */
@@ -50,6 +50,6 @@
/* Driver exported functions. */
/*===========================================================================*/
-#endif /* CH_HAL_USE_PAL */
+#endif /* HAL_USE_PAL */
/** @} */
diff --git a/os/hal/templates/pal_lld.h b/os/hal/templates/pal_lld.h
index 38990ddd9..d2e151018 100644
--- a/os/hal/templates/pal_lld.h
+++ b/os/hal/templates/pal_lld.h
@@ -28,7 +28,7 @@
#ifndef _PAL_LLD_H_
#define _PAL_LLD_H_
-#if CH_HAL_USE_PAL || defined(__DOXYGEN__)
+#if HAL_USE_PAL || defined(__DOXYGEN__)
/*===========================================================================*/
/* Unsupported modes and specific modes */
@@ -332,7 +332,7 @@ typedef uint32_t ioportid_t;
*/
#define pal_lld_setpadmode(port, pad, mode)
-#endif /* CH_HAL_USE_PAL */
+#endif /* HAL_USE_PAL */
#endif /* _PAL_LLD_H_ */
diff --git a/os/hal/templates/pwm_lld.c b/os/hal/templates/pwm_lld.c
index 2fa907ec1..02de6b17c 100644
--- a/os/hal/templates/pwm_lld.c
+++ b/os/hal/templates/pwm_lld.c
@@ -28,6 +28,8 @@
#include "ch.h"
#include "hal.h"
+#if HAL_USE_PWM || defined(__DOXYGEN__)
+
/*===========================================================================*/
/* Driver exported variables. */
/*===========================================================================*/
@@ -144,4 +146,6 @@ void pwm_lld_disable_channel(PWMDriver *pwmp, pwmchannel_t channel) {
}
+#endif /* HAL_USE_PWM */
+
/** @} */
diff --git a/os/hal/templates/pwm_lld.h b/os/hal/templates/pwm_lld.h
index 499d6e11c..1b0b38f75 100644
--- a/os/hal/templates/pwm_lld.h
+++ b/os/hal/templates/pwm_lld.h
@@ -28,6 +28,8 @@
#ifndef _PWM_LLD_H_
#define _PWM_LLD_H_
+#if HAL_USE_PWM || defined(__DOXYGEN__)
+
/*===========================================================================*/
/* Driver constants. */
/*===========================================================================*/
@@ -184,6 +186,8 @@ extern "C" {
}
#endif
+#endif /* HAL_USE_PWM */
+
#endif /* _PWM_LLD_H_ */
/** @} */
diff --git a/os/hal/templates/serial_lld.c b/os/hal/templates/serial_lld.c
index 6bb863362..406235767 100644
--- a/os/hal/templates/serial_lld.c
+++ b/os/hal/templates/serial_lld.c
@@ -28,7 +28,7 @@
#include "ch.h"
#include "hal.h"
-#if CH_HAL_USE_SERIAL || defined(__DOXYGEN__)
+#if HAL_USE_SERIAL || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver exported variables. */
@@ -95,6 +95,6 @@ void sd_lld_stop(SerialDriver *sdp) {
}
-#endif /* CH_HAL_USE_SERIAL */
+#endif /* HAL_USE_SERIAL */
/** @} */
diff --git a/os/hal/templates/serial_lld.h b/os/hal/templates/serial_lld.h
index 5e225f962..f33c2062b 100644
--- a/os/hal/templates/serial_lld.h
+++ b/os/hal/templates/serial_lld.h
@@ -28,7 +28,7 @@
#ifndef _SERIAL_LLD_H_
#define _SERIAL_LLD_H_
-#if CH_HAL_USE_SERIAL || defined(__DOXYGEN__)
+#if HAL_USE_SERIAL || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver constants. */
@@ -101,7 +101,7 @@ extern "C" {
}
#endif
-#endif /* CH_HAL_USE_SERIAL */
+#endif /* HAL_USE_SERIAL */
#endif /* _SERIAL_LLD_H_ */
diff --git a/os/hal/templates/spi_lld.c b/os/hal/templates/spi_lld.c
index f3053f725..5b76e3bdf 100644
--- a/os/hal/templates/spi_lld.c
+++ b/os/hal/templates/spi_lld.c
@@ -28,7 +28,7 @@
#include "ch.h"
#include "hal.h"
-#if CH_HAL_USE_SPI || defined(__DOXYGEN__)
+#if HAL_USE_SPI || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver exported variables. */
@@ -193,6 +193,6 @@ uint16_t spi_lld_polled_exchange(SPIDriver *spip, uint16_t frame) {
}
-#endif /* CH_HAL_USE_SPI */
+#endif /* HAL_USE_SPI */
/** @} */
diff --git a/os/hal/templates/spi_lld.h b/os/hal/templates/spi_lld.h
index acc6a699f..4e7d7b81b 100644
--- a/os/hal/templates/spi_lld.h
+++ b/os/hal/templates/spi_lld.h
@@ -28,7 +28,7 @@
#ifndef _SPI_LLD_H_
#define _SPI_LLD_H_
-#if CH_HAL_USE_SPI || defined(__DOXYGEN__)
+#if HAL_USE_SPI || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver constants. */
@@ -137,7 +137,7 @@ extern "C" {
}
#endif
-#endif /* CH_HAL_USE_SPI */
+#endif /* HAL_USE_SPI */
#endif /* _SPI_LLD_H_ */
diff --git a/os/hal/templates/uart_lld.c b/os/hal/templates/uart_lld.c
index 2c317b677..264446369 100644
--- a/os/hal/templates/uart_lld.c
+++ b/os/hal/templates/uart_lld.c
@@ -28,7 +28,7 @@
#include "ch.h"
#include "hal.h"
-#if CH_HAL_USE_UART || defined(__DOXYGEN__)
+#if HAL_USE_UART || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver exported variables. */
@@ -145,6 +145,6 @@ size_t uart_lld_stop_receive(UARTDriver *uartp) {
}
-#endif /* CH_HAL_USE_UART */
+#endif /* HAL_USE_UART */
/** @} */
diff --git a/os/hal/templates/uart_lld.h b/os/hal/templates/uart_lld.h
index 617c56166..531e7f3ab 100644
--- a/os/hal/templates/uart_lld.h
+++ b/os/hal/templates/uart_lld.h
@@ -28,7 +28,7 @@
#ifndef _UART_LLD_H_
#define _UART_LLD_H_
-#if CH_HAL_USE_UART || defined(__DOXYGEN__)
+#if HAL_USE_UART || defined(__DOXYGEN__)
/*===========================================================================*/
/* Driver constants. */
@@ -102,11 +102,11 @@ typedef struct {
/**
* @brief Character received while out if the @p UART_RECEIVE state.
*/
- uartcb_t uc_rxchar;
+ uartccb_t uc_rxchar;
/**
* @brief Receive error callback.
*/
- uartcb_t uc_rxerr;
+ uartecb_t uc_rxerr;
/* End of the mandatory fields.*/
} UARTConfig;
@@ -160,7 +160,7 @@ extern "C" {
}
#endif
-#endif /* CH_HAL_USE_UART */
+#endif /* HAL_USE_UART */
#endif /* _UART_LLD_H_ */