[boards] add an optional board_init() function

and call it at the end of mcu_init

This should be used to init board functions like killing other processes on the Parrot drones
or initializing other onboard peripherals like the cmos cam chips.

So we use this instead of killing progs in electrical_init.

Replaces #1251 and is related to #1252
This commit is contained in:
Felix Ruess
2015-07-22 18:24:15 +02:00
parent 978954a294
commit 4565c8ba16
8 changed files with 72 additions and 25 deletions
+1 -3
View File
@@ -123,7 +123,7 @@ $(TARGET).srcs += $(SRC_ARCH)/mcu_periph/i2c_arch.c
#
$(TARGET).CFLAGS += -DUSE_ADC
$(TARGET).srcs += $(SRC_ARCH)/mcu_periph/adc_arch.c
ifneq ($(ARCH), linux)
ifneq ($(BOARD), ardrone)
$(TARGET).srcs += subsystems/electrical.c
endif
@@ -139,8 +139,6 @@ ns_CFLAGS += -DUSE_DAC
ns_srcs += $(SRC_ARCH)/mcu_periph/dac_arch.c
else ifeq ($(BOARD), ardrone)
ns_srcs += $(SRC_BOARD)/electrical.c
else ifeq ($(BOARD), bebop)
ns_srcs += $(SRC_BOARD)/electrical.c
endif
#