1
0
mirror of git://projects.qi-hardware.com/f32xbase.git synced 2025-04-21 12:27:27 +03:00

Use config.h as the main source of configuration data. Fixed some boot.c

glitches.

- fw/boot/boot.c, fw/boot/dfu.c: include config.h for platform defines
- fw/common/Makefile.common: add $(F32XBASE)/fw/common to include search
  path
- fw/boot/boot.c: define dummy for uart_init if no debugging is enabled
- fw/boot/boot.c (PLATFORM_EXIT): typo PLAYFORM_EXIT
- fw/boot/boot.c (run_payload): rename BOOT_SETUP to PLATFORM_SETUP
- fw/boot/dfu.c (device_descriptor): use USB_PRODUCT instead of
  USB_PRODUCT_IDBG_DFU
- fw/boot/config.h: removed for now. Might bring it back later as template.
- fw/boot/version.h: moved to fw/common/
- fw/common/Makefile.system: remove serial setup
This commit is contained in:
Werner Almesberger
2010-08-19 01:01:08 -03:00
parent fcfaec399a
commit 3f5ec8aa9e
6 changed files with 15 additions and 48 deletions

View File

@@ -12,7 +12,7 @@
CC=sdcc
CFLAGS=--std-c99 -I. -I../common \
CFLAGS=--std-c99 -I. -I$(F32XBASE)/fw/common \
-DPAYLOAD_START=$(PAYLOAD_START) -DPAYLOAD_SIZE=$(PAYLOAD_SIZE)
LDFLAGS=--xram-size 1024

View File

@@ -10,10 +10,6 @@
# (at your option) any later version.
#
#
# @@@ This is a template for now. Needs more work.
#
#
# For now, we keep an 8k/7.5k division such that there's plenty of space for
# debugging the boot loader. Later, we should move to something like 4k/11.5k.
@@ -25,21 +21,3 @@
PAYLOAD_START=0x1000
PAYLOAD_SIZE=0x2c00
#
# Set the serial speed, depending on target type
#
ifneq (../.target,$(wildcard ../.target))
$(error Please create ../.target first)
endif
ifeq ($(shell cat ../.target),GTA)
DEFINE_UART_SPEED=-DUART_115200_BPS
else ifeq ($(shell cat ../.target),BEN_V1)
DEFINE_UART_SPEED=-DUART_57600_BPS
else ifeq ($(shell cat ../.target),BEN_V2)
DEFINE_UART_SPEED=-DUART_57600_BPS
else
DEFINE_UART_SPEED=
endif

26
fw/common/version.h Normal file
View File

@@ -0,0 +1,26 @@
/*
* boot/version.h - Automatically generated version string
*
* Written 2008 by Werner Almesberger
* Copyright 2008 Werner Almesberger
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*/
#ifndef VERSION_H
#define VERSION_H
#include <stdint.h>
/*
* Oddly, sdcc seems to insist on the "extern" to mean "declaration".
*/
extern const char *build_date;
extern const uint16_t build_number;
#endif /* !VERSION_H */