Configuration to build USBCAN converter on LMC1 board added.
authorPavel Pisa <pisa@cmp.felk.cvut.cz>
Sat, 1 Oct 2011 12:31:17 +0000 (14:31 +0200)
committerPavel Pisa <pisa@cmp.felk.cvut.cz>
Sat, 1 Oct 2011 12:31:17 +0000 (14:31 +0200)
Signed-off-by: Pavel Pisa <pisa@cmp.felk.cvut.cz>
embedded/board/arm/lpc17xx-common/config/config.usbcan [new file with mode: 0644]

diff --git a/embedded/board/arm/lpc17xx-common/config/config.usbcan b/embedded/board/arm/lpc17xx-common/config/config.usbcan
new file mode 100644 (file)
index 0000000..ec976db
--- /dev/null
@@ -0,0 +1,71 @@
+# -*- makefile -*-
+
+LN_HEADERS=y
+
+ARCH=arm
+MACH=lpc17xx
+BOARD=lpc17xx-common
+LD_SCRIPT=lpc1768
+
+CONFIG_BOARD_VARIANT=lmc1
+
+link_VARIANTS ?= app
+
+CONFIG_KEYVAL=y
+CONFIG_USB_BASE=y
+CONFIG_USB_MORE=y
+CONFIG_USB_LPCUSB=y
+
+CONFIG_APP_USBCAN=y
+#CONFIG_APP_USBLED=y
+
+CONFIG_OC_UL_DRV_SYSLESS=n
+CONFIG_ULAN_DY=n
+CONFIG_ULOI_LT=n
+#CONFIG_APP_USBBOOT=y
+#CONFIG_ULBOOT=y
+
+CONFIG_STDIO_COM_PORT=0
+
+CROSS_COMPILE = arm-elf-
+TARGET_ARCH = -mthumb -mcpu=cortex-m3
+
+# Set default C flags. If theese are set elsewhere (e.g. on a command
+# line), these default flags are not used.
+DEBUG ?= -ggdb
+#OPTIMIZE ?= -O2
+
+# Set default C flags. If theese are set elsewhere (e.g. on a command
+# line), these default flags are not used.
+#DEBUG ?= -g
+OPTIMIZE ?= -Os -ffunction-sections -fdata-sections -Wl,--gc-section
+LDFLAGS += -Wl,--cref 
+LDFLAGS += -Wl,--gc-section
+
+LPC21ISP=lpc21isp-179
+LPC_BAUD = 38400
+LPC_TTY = /dev/ttyUSB0
+CPU_SYS_KHZ=12000
+
+LOAD_CMD-boot = load() { $(LPC21ISP) -bin $$1 $(LPC_TTY) $(LPC_BAUD) $(CPU_SYS_KHZ); }; load
+
+PROG_BASE=0x09000
+PROG_SIZE=0x37000
+
+OUTPUT_FORMATS = bin
+
+LOAD_EXTENSION-app = .bin
+
+USB_SENDHEX ?= usb_sendhex
+USB_APP_VID ?= 0x1669
+USB_APP_PID ?= 0x1001
+USB_BOOT_VID ?= 0xdead
+USB_BOOT_PID ?= 0x2263
+
+LOAD_CMD-app = \
+     $(USB_SENDHEX) -d $(USB_APP_VID):$(USB_APP_PID) -r ; \
+     $(USB_SENDHEX) -w -d $(USB_BOOT_VID):$(USB_BOOT_PID) -s $(PROG_BASE) -l $(PROG_SIZE) -e; sleep 2 ; \
+     $(USB_SENDHEX) -d $(USB_BOOT_VID):$(USB_BOOT_PID) -s $(PROG_BASE) -f binary
+
+RUN_CMD-app = \
+     $(USB_SENDHEX) -d $(USB_BOOT_VID):$(USB_BOOT_PID) -r