Commit 7b68380c authored by Federico Vaga's avatar Federico Vaga

bootloader: blink before run bootloader

two slow run before jump into bootloader code
two fast run before running bootloaer code
Signed-off-by: 's avatarFederico Vaga <federico.vaga@gmail.com>
parent 985a0095
......@@ -38,11 +38,15 @@
const
#include "bootld.h"
#include <freewatch/freewatch_utils.h>
/**************************************************************************//**
* The main entry point.
*****************************************************************************/
int main(void)
{
supercar_blink(200, 4);
__set_MSP( ( 0x20000000 + sizeof( bootloader ) + 0x400 ) & 0xFFFFFFF0 );
/* Load the entire bootloader into SRAM. */
......
......@@ -44,6 +44,8 @@
#include "bootldio.h"
#include "retargetdebug.h"
#include <freewatch/freewatch_utils.h>
/*** Typedef's and defines. ***/
#define BULK_EP_SIZE 64 /* This is the max. ep size. */
......@@ -100,6 +102,8 @@ int main(void)
{
int msElapsed, i;
supercar_blink(50, 4);
/* Set new vector table pointer */
SCB->VTOR = 0x20000000;
......
......@@ -137,17 +137,19 @@ INCLUDEPATHS += \
# Files #
####################################################################
C_SRC_COMMON = \
$(COMMONSW)/emlib/src/em_system.c \
$(COMMONSW)/emlib/src/em_cmu.c \
$(COMMONSW)/emlib/src/em_assert.c \
$(COMMONSW)/emlib/src/em_gpio.c \
$(COMMONSW)/freewatch/freewatch_utils.c
C_SRC_MAIN += \
C_SRC_MAIN += $(C_SRC_COMMON) \
$(COMMONSW)/Device/EnergyMicro/EFM32GG/Source/system_efm32gg.c \
$(COMMONSW)/emlib/src/em_system.c \
$(COMMONSW)/emlib/src/em_cmu.c \
$(COMMONSW)/emlib/src/em_emu.c \
$(COMMONSW)/emlib/src/em_dma.c \
$(COMMONSW)/emlib/src/em_rtc.c \
$(COMMONSW)/emlib/src/em_assert.c \
$(COMMONSW)/emlib/src/em_gpio.c \
$(COMMONSW)/emlib/src/em_prs.c \
$(COMMONSW)/emlib/src/em_int.c \
$(COMMONSW)/emlib/src/em_timer.c \
......@@ -169,10 +171,11 @@ $(COMMONSW)/usb/src/em_usbtimer.c \
../retargetdebug.c \
../xmodem.c
C_SRC_LOADER += \
C_SRC += $(C_SRC_COMMON) \
$(COMMONSW)/Device/EnergyMicro/EFM32GG/Source/system_efm32gg.c \
../boot.c \
../loader.c
../loader.c \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment