diff --git a/os/common/ports/ARM/chcore_timer.h b/os/common/ports/ARM/chcore_timer.h index 76161602b..3da4bb01e 100644 --- a/os/common/ports/ARM/chcore_timer.h +++ b/os/common/ports/ARM/chcore_timer.h @@ -29,7 +29,7 @@ #define _CHCORE_TIMER_H_ /* This is the only header in the HAL designed to be include-able alone.*/ -#include "st.h" +#include "hal_st.h" /*===========================================================================*/ /* Module constants. */ diff --git a/os/common/ports/ARMCMx/chcore_timer.h b/os/common/ports/ARMCMx/chcore_timer.h index 1fb16888b..eec7dcf79 100644 --- a/os/common/ports/ARMCMx/chcore_timer.h +++ b/os/common/ports/ARMCMx/chcore_timer.h @@ -29,7 +29,7 @@ #define _CHCORE_TIMER_H_ /* This is the only header in the HAL designed to be include-able alone.*/ -#include "st.h" +#include "hal_st.h" /*===========================================================================*/ /* Module constants. */ diff --git a/os/common/ports/AVR/chcore_timer.h b/os/common/ports/AVR/chcore_timer.h index 3e719da90..3d99af347 100644 --- a/os/common/ports/AVR/chcore_timer.h +++ b/os/common/ports/AVR/chcore_timer.h @@ -29,7 +29,7 @@ #define _CHCORE_TIMER_H_ /* This is the only header in the HAL designed to be include-able alone.*/ -#include "st.h" +#include "hal_st.h" /*===========================================================================*/ /* Module constants. */ diff --git a/os/hal/hal.mk b/os/hal/hal.mk index ed2ac4d03..dd6f4af84 100644 --- a/os/hal/hal.mk +++ b/os/hal/hal.mk @@ -3,97 +3,97 @@ ifeq ($(USE_SMART_BUILD),yes) HALCONF := $(strip $(shell cat halconf.h | egrep -e "define")) -HALSRC := $(CHIBIOS)/os/hal/src/hal.c \ - $(CHIBIOS)/os/hal/src/st.c \ +HALSRC := $(CHIBIOS)/os/hal/src/hal_hal.c \ + $(CHIBIOS)/os/hal/src/hal_st.c \ $(CHIBIOS)/os/hal/src/hal_buffers.c \ $(CHIBIOS)/os/hal/src/hal_queues.c \ $(CHIBIOS)/os/hal/src/hal_mmcsd.c ifneq ($(findstring HAL_USE_ADC TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/adc.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_adc.c endif ifneq ($(findstring HAL_USE_CAN TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/can.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_can.c endif ifneq ($(findstring HAL_USE_DAC TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/dac.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_dac.c endif ifneq ($(findstring HAL_USE_EXT TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/ext.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_ext.c endif ifneq ($(findstring HAL_USE_GPT TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/gpt.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_gpt.c endif ifneq ($(findstring HAL_USE_I2C TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/i2c.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_i2c.c endif ifneq ($(findstring HAL_USE_I2S TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/i2s.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_i2s.c endif ifneq ($(findstring HAL_USE_ICU TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/icu.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_icu.c endif ifneq ($(findstring HAL_USE_MAC TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/mac.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_mac.c endif ifneq ($(findstring HAL_USE_MMC_SPI TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/mmc_spi.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_mmc_spi.c endif ifneq ($(findstring HAL_USE_PAL TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/pal.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_pal.c endif ifneq ($(findstring HAL_USE_PWM TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/pwm.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_pwm.c endif ifneq ($(findstring HAL_USE_RTC TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/rtc.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_rtc.c endif ifneq ($(findstring HAL_USE_SDC TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/sdc.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_sdc.c endif ifneq ($(findstring HAL_USE_SERIAL TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/serial.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_serial.c endif ifneq ($(findstring HAL_USE_SERIAL_USB TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/serial_usb.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_serial_usb.c endif ifneq ($(findstring HAL_USE_SPI TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/spi.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_spi.c endif ifneq ($(findstring HAL_USE_UART TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/uart.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_uart.c endif ifneq ($(findstring HAL_USE_USB TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/usb.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_usb.c endif ifneq ($(findstring HAL_USE_WDG TRUE,$(HALCONF)),) -HALSRC += $(CHIBIOS)/os/hal/src/wdg.c +HALSRC += $(CHIBIOS)/os/hal/src/hal_wdg.c endif else HALSRC = $(CHIBIOS)/os/hal/src/hal.c \ $(CHIBIOS)/os/hal/src/hal_buffers.c \ $(CHIBIOS)/os/hal/src/hal_queues.c \ $(CHIBIOS)/os/hal/src/hal_mmcsd.c \ - $(CHIBIOS)/os/hal/src/adc.c \ - $(CHIBIOS)/os/hal/src/can.c \ - $(CHIBIOS)/os/hal/src/dac.c \ - $(CHIBIOS)/os/hal/src/ext.c \ - $(CHIBIOS)/os/hal/src/gpt.c \ - $(CHIBIOS)/os/hal/src/i2c.c \ - $(CHIBIOS)/os/hal/src/i2s.c \ - $(CHIBIOS)/os/hal/src/icu.c \ - $(CHIBIOS)/os/hal/src/mac.c \ - $(CHIBIOS)/os/hal/src/mmc_spi.c \ - $(CHIBIOS)/os/hal/src/pal.c \ - $(CHIBIOS)/os/hal/src/pwm.c \ - $(CHIBIOS)/os/hal/src/rtc.c \ - $(CHIBIOS)/os/hal/src/sdc.c \ - $(CHIBIOS)/os/hal/src/serial.c \ - $(CHIBIOS)/os/hal/src/serial_usb.c \ - $(CHIBIOS)/os/hal/src/spi.c \ - $(CHIBIOS)/os/hal/src/st.c \ - $(CHIBIOS)/os/hal/src/uart.c \ - $(CHIBIOS)/os/hal/src/usb.c \ - $(CHIBIOS)/os/hal/src/wdg.c + $(CHIBIOS)/os/hal/src/hal_adc.c \ + $(CHIBIOS)/os/hal/src/hal_can.c \ + $(CHIBIOS)/os/hal/src/hal_dac.c \ + $(CHIBIOS)/os/hal/src/hal_ext.c \ + $(CHIBIOS)/os/hal/src/hal_gpt.c \ + $(CHIBIOS)/os/hal/src/hal_i2c.c \ + $(CHIBIOS)/os/hal/src/hal_i2s.c \ + $(CHIBIOS)/os/hal/src/hal_icu.c \ + $(CHIBIOS)/os/hal/src/hal_mac.c \ + $(CHIBIOS)/os/hal/src/hal_mmc_spi.c \ + $(CHIBIOS)/os/hal/src/hal_pal.c \ + $(CHIBIOS)/os/hal/src/hal_pwm.c \ + $(CHIBIOS)/os/hal/src/hal_rtc.c \ + $(CHIBIOS)/os/hal/src/hal_sdc.c \ + $(CHIBIOS)/os/hal/src/hal_serial.c \ + $(CHIBIOS)/os/hal/src/hal_serial_usb.c \ + $(CHIBIOS)/os/hal/src/hal_spi.c \ + $(CHIBIOS)/os/hal/src/hal_st.c \ + $(CHIBIOS)/os/hal/src/hal_uart.c \ + $(CHIBIOS)/os/hal/src/hal_usb.c \ + $(CHIBIOS)/os/hal/src/hal_wdg.c endif # Required include directories diff --git a/os/hal/include/hal.h b/os/hal/include/hal.h index 2ffd9ab0d..ba7c2c591 100644 --- a/os/hal/include/hal.h +++ b/os/hal/include/hal.h @@ -43,37 +43,36 @@ #include "hal_queues.h" /* Normal drivers.*/ -#include "pal.h" -#include "adc.h" -#include "can.h" -#include "dac.h" -#include "ext.h" -#include "gpt.h" -#include "i2c.h" -#include "i2s.h" -#include "icu.h" -#include "mac.h" -#include "mii.h" -#include "pwm.h" -#include "rtc.h" -#include "serial.h" -#include "sdc.h" -#include "spi.h" -#include "uart.h" -#include "usb.h" -#include "wdg.h" +#include "hal_pal.h" +#include "hal_adc.h" +#include "hal_can.h" +#include "hal_dac.h" +#include "hal_ext.h" +#include "hal_gpt.h" +#include "hal_i2c.h" +#include "hal_i2s.h" +#include "hal_icu.h" +#include "hal_mac.h" +#include "hal_pwm.h" +#include "hal_rtc.h" +#include "hal_serial.h" +#include "hal_sdc.h" +#include "hal_spi.h" +#include "hal_uart.h" +#include "hal_usb.h" +#include "hal_wdg.h" /* * The ST driver is a special case, it is only included if the OSAL is * configured to require it. */ #if OSAL_ST_MODE != OSAL_ST_MODE_NONE -#include "st.h" +#include "hal_st.h" #endif /* Complex drivers.*/ -#include "mmc_spi.h" -#include "serial_usb.h" +#include "hal_mmc_spi.h" +#include "hal_serial_usb.h" /* Community drivers.*/ #if defined(HAL_USE_COMMUNITY) || defined(__DOXYGEN__) @@ -103,17 +102,17 @@ /** * @brief HAL version string. */ -#define HAL_VERSION "4.1.0" +#define HAL_VERSION "5.0.0" /** * @brief HAL version major number. */ -#define CH_HAL_MAJOR 4 +#define CH_HAL_MAJOR 5 /** * @brief HAL version minor number. */ -#define CH_HAL_MINOR 1 +#define CH_HAL_MINOR 0 /** * @brief HAL version patch number. diff --git a/os/hal/include/adc.h b/os/hal/include/hal_adc.h similarity index 100% rename from os/hal/include/adc.h rename to os/hal/include/hal_adc.h diff --git a/os/hal/include/can.h b/os/hal/include/hal_can.h similarity index 100% rename from os/hal/include/can.h rename to os/hal/include/hal_can.h diff --git a/os/hal/include/dac.h b/os/hal/include/hal_dac.h similarity index 100% rename from os/hal/include/dac.h rename to os/hal/include/hal_dac.h diff --git a/os/hal/include/ext.h b/os/hal/include/hal_ext.h similarity index 100% rename from os/hal/include/ext.h rename to os/hal/include/hal_ext.h diff --git a/os/hal/include/gpt.h b/os/hal/include/hal_gpt.h similarity index 100% rename from os/hal/include/gpt.h rename to os/hal/include/hal_gpt.h diff --git a/os/hal/include/i2c.h b/os/hal/include/hal_i2c.h similarity index 100% rename from os/hal/include/i2c.h rename to os/hal/include/hal_i2c.h diff --git a/os/hal/include/i2s.h b/os/hal/include/hal_i2s.h similarity index 100% rename from os/hal/include/i2s.h rename to os/hal/include/hal_i2s.h diff --git a/os/hal/include/icu.h b/os/hal/include/hal_icu.h similarity index 100% rename from os/hal/include/icu.h rename to os/hal/include/hal_icu.h diff --git a/os/hal/include/mac.h b/os/hal/include/hal_mac.h similarity index 97% rename from os/hal/include/mac.h rename to os/hal/include/hal_mac.h index 44bfcafab..b5c49d01c 100644 --- a/os/hal/include/mac.h +++ b/os/hal/include/hal_mac.h @@ -26,6 +26,8 @@ #if (HAL_USE_MAC == TRUE) || defined(__DOXYGEN__) +#include "mii.h" + /*===========================================================================*/ /* Driver constants. */ /*===========================================================================*/ diff --git a/os/hal/include/mmc_spi.h b/os/hal/include/hal_mmc_spi.h similarity index 100% rename from os/hal/include/mmc_spi.h rename to os/hal/include/hal_mmc_spi.h diff --git a/os/hal/include/pal.h b/os/hal/include/hal_pal.h similarity index 100% rename from os/hal/include/pal.h rename to os/hal/include/hal_pal.h diff --git a/os/hal/include/pwm.h b/os/hal/include/hal_pwm.h similarity index 100% rename from os/hal/include/pwm.h rename to os/hal/include/hal_pwm.h diff --git a/os/hal/include/rtc.h b/os/hal/include/hal_rtc.h similarity index 100% rename from os/hal/include/rtc.h rename to os/hal/include/hal_rtc.h diff --git a/os/hal/include/sdc.h b/os/hal/include/hal_sdc.h similarity index 100% rename from os/hal/include/sdc.h rename to os/hal/include/hal_sdc.h diff --git a/os/hal/include/serial.h b/os/hal/include/hal_serial.h similarity index 100% rename from os/hal/include/serial.h rename to os/hal/include/hal_serial.h diff --git a/os/hal/include/serial_usb.h b/os/hal/include/hal_serial_usb.h similarity index 100% rename from os/hal/include/serial_usb.h rename to os/hal/include/hal_serial_usb.h diff --git a/os/hal/include/spi.h b/os/hal/include/hal_spi.h similarity index 100% rename from os/hal/include/spi.h rename to os/hal/include/hal_spi.h diff --git a/os/hal/include/st.h b/os/hal/include/hal_st.h similarity index 100% rename from os/hal/include/st.h rename to os/hal/include/hal_st.h diff --git a/os/hal/include/uart.h b/os/hal/include/hal_uart.h similarity index 100% rename from os/hal/include/uart.h rename to os/hal/include/hal_uart.h diff --git a/os/hal/include/usb.h b/os/hal/include/hal_usb.h similarity index 100% rename from os/hal/include/usb.h rename to os/hal/include/hal_usb.h diff --git a/os/hal/include/wdg.h b/os/hal/include/hal_wdg.h similarity index 100% rename from os/hal/include/wdg.h rename to os/hal/include/hal_wdg.h diff --git a/os/hal/src/adc.c b/os/hal/src/hal_adc.c similarity index 100% rename from os/hal/src/adc.c rename to os/hal/src/hal_adc.c diff --git a/os/hal/src/can.c b/os/hal/src/hal_can.c similarity index 100% rename from os/hal/src/can.c rename to os/hal/src/hal_can.c diff --git a/os/hal/src/dac.c b/os/hal/src/hal_dac.c similarity index 100% rename from os/hal/src/dac.c rename to os/hal/src/hal_dac.c diff --git a/os/hal/src/ext.c b/os/hal/src/hal_ext.c similarity index 100% rename from os/hal/src/ext.c rename to os/hal/src/hal_ext.c diff --git a/os/hal/src/gpt.c b/os/hal/src/hal_gpt.c similarity index 100% rename from os/hal/src/gpt.c rename to os/hal/src/hal_gpt.c diff --git a/os/hal/src/hal.c b/os/hal/src/hal_hal.c similarity index 100% rename from os/hal/src/hal.c rename to os/hal/src/hal_hal.c diff --git a/os/hal/src/i2c.c b/os/hal/src/hal_i2c.c similarity index 100% rename from os/hal/src/i2c.c rename to os/hal/src/hal_i2c.c diff --git a/os/hal/src/i2s.c b/os/hal/src/hal_i2s.c similarity index 100% rename from os/hal/src/i2s.c rename to os/hal/src/hal_i2s.c diff --git a/os/hal/src/icu.c b/os/hal/src/hal_icu.c similarity index 100% rename from os/hal/src/icu.c rename to os/hal/src/hal_icu.c diff --git a/os/hal/src/mac.c b/os/hal/src/hal_mac.c similarity index 100% rename from os/hal/src/mac.c rename to os/hal/src/hal_mac.c diff --git a/os/hal/src/mmc_spi.c b/os/hal/src/hal_mmc_spi.c similarity index 100% rename from os/hal/src/mmc_spi.c rename to os/hal/src/hal_mmc_spi.c diff --git a/os/hal/src/pal.c b/os/hal/src/hal_pal.c similarity index 100% rename from os/hal/src/pal.c rename to os/hal/src/hal_pal.c diff --git a/os/hal/src/pwm.c b/os/hal/src/hal_pwm.c similarity index 100% rename from os/hal/src/pwm.c rename to os/hal/src/hal_pwm.c diff --git a/os/hal/src/rtc.c b/os/hal/src/hal_rtc.c similarity index 100% rename from os/hal/src/rtc.c rename to os/hal/src/hal_rtc.c diff --git a/os/hal/src/sdc.c b/os/hal/src/hal_sdc.c similarity index 100% rename from os/hal/src/sdc.c rename to os/hal/src/hal_sdc.c diff --git a/os/hal/src/serial.c b/os/hal/src/hal_serial.c similarity index 100% rename from os/hal/src/serial.c rename to os/hal/src/hal_serial.c diff --git a/os/hal/src/serial_usb.c b/os/hal/src/hal_serial_usb.c similarity index 100% rename from os/hal/src/serial_usb.c rename to os/hal/src/hal_serial_usb.c diff --git a/os/hal/src/spi.c b/os/hal/src/hal_spi.c similarity index 100% rename from os/hal/src/spi.c rename to os/hal/src/hal_spi.c diff --git a/os/hal/src/st.c b/os/hal/src/hal_st.c similarity index 100% rename from os/hal/src/st.c rename to os/hal/src/hal_st.c diff --git a/os/hal/src/uart.c b/os/hal/src/hal_uart.c similarity index 100% rename from os/hal/src/uart.c rename to os/hal/src/hal_uart.c diff --git a/os/hal/src/usb.c b/os/hal/src/hal_usb.c similarity index 100% rename from os/hal/src/usb.c rename to os/hal/src/hal_usb.c diff --git a/os/hal/src/wdg.c b/os/hal/src/hal_wdg.c similarity index 100% rename from os/hal/src/wdg.c rename to os/hal/src/hal_wdg.c diff --git a/readme.txt b/readme.txt index 0febf1b46..048499a4e 100644 --- a/readme.txt +++ b/readme.txt @@ -79,6 +79,9 @@ ***************************************************************************** *** Next *** +- HAL: All high level file names have been renamed and prefixed with "hal_" + in order to minimize the risk of name conflicts when integrating + external libraries. - LIB: Added Guarded Memory Pools to RT and NIL. - NIL: Updated the NIL test suite by generating the code using the new system. - RT: Removed I/O Queues and Streams interface, now those exists (much