Move files

This commit is contained in:
NIIBE Yutaka
2016-06-02 11:01:11 +09:00
parent a756987d2a
commit 78718e57df
9 changed files with 26 additions and 3 deletions

View File

@@ -1,3 +1,18 @@
2016-06-02 Niibe Yutaka <gniibe@fsij.org>
* contrib/adc-mkl27z.c: Move from mcu.
* contrib/adc-stm32f103.c: Move from mcu.
* example-led/Makefile (CHIP): Define as stm32f0.
* mcu/sys-stm32f0.h: Rename from sys-stm32f030.h,
as we share it among STM32F030 and STM32F050.
* mcu/sys-stm32f0.c: Likewise.
* board/board-stm32f0-discovery.h (MCU_STM32F0): Define.
* sys.h: Support STM32F0.
2016-06-01 NIIBE Yutaka <gniibe@fsij.org>
* chopstx.h (chx_fatal): Remove weak attribute from declaration.

View File

@@ -1,6 +1,8 @@
#define BOARD_NAME "STM32F0 Discovery"
#define BOARD_ID 0xde4b4bc1
#define MCU_STM32F0 1
/*
* Running at 48MHz with HSI as clock source.
*

View File

@@ -10,7 +10,7 @@ LDSCRIPT= sample.ld
### LDSCRIPT= sample.ld.m3
CSRC = sample.c
CHIP=stm32f030
CHIP=stm32f0
USE_SYS = yes
###################################

View File

@@ -16,8 +16,12 @@
#endif
extern const uint8_t sys_version[8];
#if defined(USE_SYS3) || defined(USE_SYS_BOARD_ID)
extern const uint32_t sys_board_id;
extern const uint8_t sys_board_name[];
#else
# define SYS_BOARD_ID BOARD_ID
#endif
typedef void (*handler)(void);
extern handler vector[16];

View File

@@ -13,7 +13,7 @@ ifneq ($(USE_USB),)
CSRC += $(CHOPSTX)/mcu/usb-$(CHIP).c
endif
ifneq ($(USE_ADC),)
CSRC += $(CHOPSTX)/mcu/adc-$(CHIP).c
CSRC += $(CHOPSTX)/contrib/adc-$(CHIP).c
endif
INCDIR += $(CHOPSTX)

4
sys.h
View File

@@ -1,5 +1,7 @@
#ifdef MCU_KINETIS_L
#if defined(MCU_KINETIS_L)
#include "mcu/sys-mkl27z.h"
#elif defined(MCU_STM32F0)
#include "mcu/sys-stm32f0.h"
#else
#include "mcu/sys-stm32f103.h"
#endif