mirror of
https://github.com/pvvx/RTL00_AT.git
synced 2024-11-21 17:44:15 +00:00
update
This commit is contained in:
parent
2e877d1e6f
commit
5b3f9d6067
26 changed files with 50 additions and 1022 deletions
|
@ -1,7 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
cd flasher
|
|
||||||
openocd -f interface/cmsis-dap.cfg -c "adapter_khz 1000" -f rtl8710.ocd -f cortex.ocd -c "init" -c "reset halt" -c "load_ram_binary RTL00Console_ROM.bin 0x10000BA8" -c "exit"
|
|
||||||
rem -c "shutdown"
|
|
||||||
|
|
||||||
|
|
|
@ -1,7 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
cd flasher
|
|
||||||
openocd -f interface/cmsis-dap.cfg -c "adapter_khz 1000" -f rtl8710.ocd -f cortex.ocd -c "init" -c "reset halt" -c "rtl8710_flash_read_id" -c "adapter_khz 5000" -c "rtl8710_flash_read ../fullflash.bin 0 1048576" -c "shutdown"
|
|
||||||
echo flash read fullflash.bin
|
|
||||||
pause
|
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
@cd flasher
|
|
||||||
openocd -f interface/cmsis-dap.cfg -c "adapter_khz 1000" -f rtl8710.ocd -f cortex.ocd -c "init" -c "reset halt" -c "restart_from_falsh" -c "shutdown"
|
|
||||||
rem
|
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
cd flasher
|
|
||||||
openocd -f interface/cmsis-dap.cfg -c "adapter_khz 3500" -f rtl8710.ocd -f cortex.ocd -c "init" -c "reset halt" -c "rtl8710_flash_read_id" -c "rtl8710_flash_auto_erase 1" -c "rtl8710_flash_auto_verify 1" -c "rtl8710_flash_write fullflash.bin 0" -c "shutdown"
|
|
||||||
pause
|
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
start JLinkGDBServer.exe -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
|
||||||
arm-none-eabi-gdb.exe -x flasher/gdb_rdflash.jlink
|
|
||||||
taskkill /F /IM JLinkGDBServer.exe
|
|
||||||
|
|
|
@ -1,15 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
@if exist build\obj\build.axf goto run
|
|
||||||
echo File 'build\obj\build.axf' not found!
|
|
||||||
echo Build project...
|
|
||||||
mingw32-make.exe -f Makefile all
|
|
||||||
@if not exist build\obj\build.axf goto err
|
|
||||||
:run
|
|
||||||
start JLinkGDBServer.exe -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
|
||||||
arm-none-eabi-gdb.exe -x flasher/gdb_run_ram.jlink
|
|
||||||
taskkill /F /IM JLinkGDBServer.exe
|
|
||||||
goto end
|
|
||||||
:err
|
|
||||||
echo Error!
|
|
||||||
:end
|
|
|
@ -1,21 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
@if %1x==x goto xxx
|
|
||||||
set img_file=%1
|
|
||||||
goto run
|
|
||||||
:xxx
|
|
||||||
set img_file=build/bin/ram_all.bin
|
|
||||||
:run
|
|
||||||
echo define call1>flasher/flash_file.jlink
|
|
||||||
echo SetFirwareSize %img_file%>>flasher/flash_file.jlink
|
|
||||||
echo end>>flasher/flash_file.jlink
|
|
||||||
echo define call2>>flasher/flash_file.jlink
|
|
||||||
echo FlasherWrite %img_file% 0 $Image1Size>>flasher/flash_file.jlink
|
|
||||||
echo end>>flasher/flash_file.jlink
|
|
||||||
echo define call3>>flasher/flash_file.jlink
|
|
||||||
echo FlasherWrite %img_file% $Image2Addr $Image2Size>>flasher/flash_file.jlink
|
|
||||||
echo end>>flasher/flash_file.jlink
|
|
||||||
start JLinkGDBServer.exe -device Cortex-M3 -if SWD -ir -endian little -speed 3500
|
|
||||||
arm-none-eabi-gdb.exe -x flasher/gdb_wrflash.jlink
|
|
||||||
taskkill /F /IM JLinkGDBServer.exe
|
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
start JLinkGDBServer.exe -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
|
||||||
arm-none-eabi-gdb.exe -x flasher/gdb_init.jlink
|
|
||||||
taskkill /F /IM JLinkGDBServer.exe
|
|
||||||
|
|
|
@ -1,15 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
@if exist build\bin\ota.bin goto run
|
|
||||||
echo File 'build\obj\ota.bin' not found!
|
|
||||||
echo Build project...
|
|
||||||
mingw32-make.exe -f Makefile all
|
|
||||||
@if not exist build\bin\ota.bin goto err
|
|
||||||
:run
|
|
||||||
start start JLinkGDBServer.exe -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
|
||||||
arm-none-eabi-gdb.exe -x flasher/gdb_ota.jlink
|
|
||||||
taskkill /F /IM JLinkGDBServer.exe
|
|
||||||
goto end
|
|
||||||
:err
|
|
||||||
echo Error!
|
|
||||||
:end
|
|
|
@ -1,7 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
cd flasher
|
|
||||||
openocd -f interface/Jlink.cfg -c "adapter_khz 3500" -f rtl8710.ocd -f cortex.ocd -c "init" -c "reset halt" -c "rtl8710_flash_read_id" -c "adapter_khz 3900" -c "rtl8710_flash_read ../fullflash.bin 0 1048576" -c "shutdown"
|
|
||||||
echo flash read fullflash.bin
|
|
||||||
pause
|
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
openocd -f interface/Jlink.cfg -c "adapter_khz 1000" -f rtl8710.ocd -f cortex.ocd -c "init" -c "reset halt" -c "adapter_khz 3500" -c "rtl8710_flash_read_id" -c "rtl8710_flash_read ../fullflash.bin 0 1048576" -c "shutdown"
|
|
||||||
echo flash read fullflash.bin
|
|
||||||
pause
|
|
||||||
|
|
|
@ -1,4 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
taskkill /F /IM openocd.exe
|
|
||||||
start openocd -f interface\Jlink.cfg -f flasher\ameba1.cfg
|
|
40
Makefile
40
Makefile
|
@ -1,53 +1,39 @@
|
||||||
|
include userset.mk
|
||||||
|
|
||||||
all: ram_all
|
all: ram_all
|
||||||
mp: ram_all_mp
|
mp: ram_all_mp
|
||||||
|
|
||||||
.PHONY: ram_all
|
.PHONY: ram_all
|
||||||
ram_all:
|
ram_all:
|
||||||
@$(MAKE) -f sdkbuild.mk
|
@$(MAKE) -f $(SDK_PATH)sdkbuild.mk
|
||||||
@$(MAKE) -f flasher.mk genbin1 genbin23
|
@$(MAKE) -f $(SDK_PATH)flasher.mk genbin1 genbin23
|
||||||
|
|
||||||
.PHONY: ram_all_mp
|
.PHONY: ram_all_mp
|
||||||
ram_all_mp:
|
ram_all_mp:
|
||||||
@$(MAKE) -f sdkbuild.mk mp
|
@$(MAKE) -f $(SDK_PATH)sdkbuild.mk mp
|
||||||
@$(MAKE) -f flasher.mk mp
|
@$(MAKE) -f $(SDK_PATH)flasher.mk mp
|
||||||
|
|
||||||
.PHONY: clean clean_all
|
.PHONY: clean clean_all
|
||||||
clean:
|
clean:
|
||||||
@$(MAKE) -f sdkbuild.mk clean
|
@$(MAKE) -f $(SDK_PATH)sdkbuild.mk clean
|
||||||
|
|
||||||
clean_all:
|
clean_all:
|
||||||
@$(MAKE) -f sdkbuild.mk clean_all
|
@$(MAKE) -f $(SDK_PATH)sdkbuild.mk clean_all
|
||||||
|
|
||||||
.PHONY: flashburn runram reset test readfullflash flashwebfs
|
.PHONY: flashburn runram reset test readfullflash flashwebfs
|
||||||
flashburn:
|
flashburn:
|
||||||
#JLinkGDB-WrFlash.bat
|
@$(MAKE) -f $(SDK_PATH)flasher.mk flashburn
|
||||||
@$(MAKE) -f flasher.mk flashburn
|
|
||||||
|
|
||||||
flash_OTA:
|
flash_OTA:
|
||||||
@$(MAKE) -f flasher.mk flash_OTA
|
@$(MAKE) -f $(SDK_PATH)flasher.mk flash_OTA
|
||||||
|
|
||||||
flashwebfs:
|
|
||||||
@$(MAKE) -f flasher.mk flashwebfs
|
|
||||||
#JLinkGDB-WrWebFs.bat
|
|
||||||
|
|
||||||
runram:
|
runram:
|
||||||
#JLink-RunRAM.bat
|
@$(MAKE) --f $(SDK_PATH)flasher.mk runram
|
||||||
@$(MAKE) --f flasher.mk runram
|
|
||||||
|
|
||||||
reset:
|
reset:
|
||||||
#JLink-Reset.bat
|
@$(MAKE) -f $(SDK_PATH)flasher.mk reset
|
||||||
@$(MAKE) -f flasher.mk reset
|
|
||||||
|
|
||||||
test:
|
|
||||||
JLink-RTL00ConsoleROM.bat
|
|
||||||
#@make -f flasher.mk test
|
|
||||||
|
|
||||||
readfullflash:
|
readfullflash:
|
||||||
#JLink-RdFullFlash.bat
|
@$(MAKE) -f $(SDK_PATH)flasher.mk readfullflash
|
||||||
@$(MAKE) -f flasher.mk readfullflash
|
|
||||||
|
|
||||||
.PHONY: prerequirement
|
|
||||||
prerequirement:
|
|
||||||
@$(file >DEPENDENCY_LIST.txt,$(DEPENDENCY_LIST))
|
|
||||||
|
|
|
@ -1,7 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
cd flasher
|
|
||||||
openocd -f interface/stlink-v2.cfg -c "adapter_khz 1000" -f rtl8710.ocd -f cortex.ocd -c "init" -c "reset halt" -c "rtl8710_flash_read_id" -c "adapter_khz 5000" -c "rtl8710_flash_read ../fullflash.bin 0 1048576" -c "shutdown"
|
|
||||||
echo flash read fullflash.bin
|
|
||||||
pause
|
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
@echo off
|
|
||||||
call paths.bat
|
|
||||||
@cd flasher
|
|
||||||
openocd -f interface/stlink-v2.cfg -c "adapter_khz 1000" -f rtl8710.ocd -f cortex.ocd -c "init" -c "reset halt" -c "cortex_reboot" -c "shutdown"
|
|
||||||
rem
|
|
||||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
307
flasher.mk
307
flasher.mk
|
@ -1,307 +0,0 @@
|
||||||
# RTL8710 Flasher v0.0.alfa
|
|
||||||
# pvvx 21.09.2016
|
|
||||||
-include paths.mk
|
|
||||||
#---------------------------
|
|
||||||
#FLASHER = stlink-v2-1
|
|
||||||
#FLASHER = stlink-v2
|
|
||||||
FLASHER ?= Jlink
|
|
||||||
JLINK_PATH ?= D:/MCU/SEGGER/JLink_V612i/
|
|
||||||
#---------------------------
|
|
||||||
# Default
|
|
||||||
#---------------------------
|
|
||||||
# TARGET dirs
|
|
||||||
TARGET ?= build
|
|
||||||
OBJ_DIR ?= build/obj
|
|
||||||
BIN_DIR ?= build/bin
|
|
||||||
ELFFILE ?= $(OBJ_DIR)/$(TARGET).axf
|
|
||||||
#---------------------------
|
|
||||||
# Compilation tools
|
|
||||||
CROSS_COMPILE ?= $(GCC_PATH)arm-none-eabi-
|
|
||||||
AR ?= $(CROSS_COMPILE)ar
|
|
||||||
CC ?= $(CROSS_COMPILE)gcc
|
|
||||||
AS ?= $(CROSS_COMPILE)as
|
|
||||||
NM ?= $(CROSS_COMPILE)nm
|
|
||||||
LD ?= $(CROSS_COMPILE)gcc
|
|
||||||
GDB ?= $(CROSS_COMPILE)gdb
|
|
||||||
SIZE ?= $(CROSS_COMPILE)size
|
|
||||||
OBJCOPY ?= $(CROSS_COMPILE)objcopy
|
|
||||||
OBJDUMP ?= $(CROSS_COMPILE)objdump
|
|
||||||
|
|
||||||
# Make bunary tools
|
|
||||||
TOOLS_PATH ?= component/soc/realtek/8195a/misc/iar_utility/common/tools/
|
|
||||||
ifneq ($(shell uname), Linux)
|
|
||||||
EXE = .exe
|
|
||||||
endif
|
|
||||||
PICK = $(TOOLS_PATH)pick$(EXE)
|
|
||||||
PADDING = $(TOOLS_PATH)padding$(EXE)
|
|
||||||
CHCKSUM = $(TOOLS_PATH)checksum$(EXE)
|
|
||||||
|
|
||||||
# openocd tools
|
|
||||||
OPENOCD = $(OPENOCD_PATH)openocd
|
|
||||||
|
|
||||||
JLINK_GDB ?= JLinkGDBServer.exe
|
|
||||||
JLINK_EXE ?= JLink.exe
|
|
||||||
|
|
||||||
ifeq ($(FLASHER), Jlink)
|
|
||||||
# Jlink FLASHER_SPEED ..4000 kHz
|
|
||||||
FLASHER_SPEED = 3500
|
|
||||||
else
|
|
||||||
ifeq ($(FLASHER),stlink-v2)
|
|
||||||
# stlink-v2 FLASHER_SPEED ..1800 kHz
|
|
||||||
FLASHER_SPEED = 1800
|
|
||||||
else
|
|
||||||
# over FLASHER_SPEED ..500 kHz ?
|
|
||||||
FLASHER_SPEED = 500
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
# COMPILED_BOOT if defined -> extract image1, boot head in elf
|
|
||||||
COMPILED_BOOT=1
|
|
||||||
# COMPILED_BOOT_BIN if !defined -> use source startup boot
|
|
||||||
#COMPILED_BOOT_BIN=1
|
|
||||||
# PADDINGSIZE defined -> image2 OTA
|
|
||||||
PADDINGSIZE =44k
|
|
||||||
|
|
||||||
NMAPFILE = $(OBJ_DIR)/$(TARGET).nmap
|
|
||||||
|
|
||||||
#FLASHER_PATH ?= flasher/
|
|
||||||
|
|
||||||
#RAM_IMAGE?= $(BIN_DIR)/ram.bin
|
|
||||||
|
|
||||||
RAM1_IMAGE ?= $(BIN_DIR)/ram_1.bin
|
|
||||||
RAM1P_IMAGE ?= $(BIN_DIR)/ram_1.p.bin
|
|
||||||
RAM1R_IMAGE ?= $(BIN_DIR)/ram_1.r.bin
|
|
||||||
|
|
||||||
RAM2_IMAGE = $(BIN_DIR)/ram_2.bin
|
|
||||||
RAM2P_IMAGE = $(BIN_DIR)/ram_2.p.bin
|
|
||||||
RAM2NS_IMAGE = $(BIN_DIR)/ram_2.ns.bin
|
|
||||||
|
|
||||||
RAM3_IMAGE = $(BIN_DIR)/sdram.bin
|
|
||||||
RAM3P_IMAGE = $(BIN_DIR)/sdram.p.bin
|
|
||||||
|
|
||||||
FLASH_IMAGE = $(BIN_DIR)/ram_all.bin
|
|
||||||
OTA_IMAGE = $(BIN_DIR)/ota.bin
|
|
||||||
|
|
||||||
#all: FLASH_IMAGE = $(BIN_DIR)/ram_all.bin
|
|
||||||
#all: OTA_IMAGE = $(BIN_DIR)/ota.bin
|
|
||||||
mp: FLASH_IMAGE = $(BIN_DIR)/ram_all_mp.bin
|
|
||||||
mp: OTA_IMAGE = $(BIN_DIR)/ota_mp.bin
|
|
||||||
|
|
||||||
TST_IMAGE = $(BIN_DIR)/ram_2.bin
|
|
||||||
|
|
||||||
.PHONY: genbin1 genbin23 flashburn reset test readfullflash flashwebfs flash_OTA
|
|
||||||
.NOTPARALLEL: all mp genbin1 genbin23 flashburn reset test readfullflash _endgenbin flashwebfs flash_OTA
|
|
||||||
|
|
||||||
all: $(ELFFILE) $(OTA_IMAGE) $(FLASH_IMAGE) _endgenbin
|
|
||||||
mp: $(ELFFILE) $(OTA_IMAGE) $(FLASH_IMAGE) _endgenbin
|
|
||||||
|
|
||||||
genbin1: $(ELFFILE) $(RAM1P_IMAGE)
|
|
||||||
|
|
||||||
genbin23: $(ELFFILE) $(OTA_IMAGE) $(FLASH_IMAGE) _endgenbin
|
|
||||||
|
|
||||||
|
|
||||||
_endgenbin:
|
|
||||||
@echo "-----------------------------------------------------------"
|
|
||||||
@echo "Image ($(OTA_IMAGE)) size $(shell printf '%d\n' $$(( $$(stat --printf="%s" $(OTA_IMAGE)) )) ) bytes"
|
|
||||||
@echo "Image ($(FLASH_IMAGE)) size $(shell printf '%d\n' $$(( $$(stat --printf="%s" $(FLASH_IMAGE)) )) ) bytes"
|
|
||||||
@echo "==========================================================="
|
|
||||||
|
|
||||||
ifeq ($(FLASHER_TYPE), Jlink)
|
|
||||||
|
|
||||||
reset:
|
|
||||||
@$(JLINK_PATH)$(JLINK_EXE) -Device CORTEX-M3 -If SWD -Speed 1000 $(FLASHER_PATH)RTL_Reset.JLinkScript
|
|
||||||
|
|
||||||
runram:
|
|
||||||
@$(JLINK_PATH)$(JLINK_EXE) -Device CORTEX-M3 -If SWD -Speed 1000 $(FLASHER_PATH)RTL_RunRAM.JLinkScript
|
|
||||||
|
|
||||||
readfullflash:
|
|
||||||
@$(JLINK_PATH)$(JLINK_EXE) -Device CORTEX-M3 -If SWD -Speed 1000 $(FLASHER_PATH)RTL_FFlash.JLinkScript
|
|
||||||
|
|
||||||
|
|
||||||
flashburn:
|
|
||||||
@echo define call1>$(FLASHER_PATH)flash_file.jlink
|
|
||||||
@echo SetFirwareSize build/bin/ram_all.bin>>$(FLASHER_PATH)flash_file.jlink
|
|
||||||
@echo end>>$(FLASHER_PATH)flash_file.jlink
|
|
||||||
@echo define call2>>$(FLASHER_PATH)flash_file.jlink
|
|
||||||
@echo FlasherWrite build/bin/ram_all.bin 0 '$$'Image1Size>>$(FLASHER_PATH)flash_file.jlink
|
|
||||||
@echo end>>$(FLASHER_PATH)flash_file.jlink
|
|
||||||
@echo define call3>>$(FLASHER_PATH)flash_file.jlink
|
|
||||||
@echo FlasherWrite build/bin/ram_all.bin '$$'Image2Addr '$$'Image2Size>>$(FLASHER_PATH)flash_file.jlink
|
|
||||||
@echo end>>$(FLASHER_PATH)flash_file.jlink
|
|
||||||
@cmd /K start $(JLINK_PATH)$(JLINK_GDBSRV) -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
|
||||||
@$(GDB) -x $(FLASHER_PATH)gdb_wrflash.jlink
|
|
||||||
#@taskkill /F /IM $(JLINK_GDBSRV)
|
|
||||||
|
|
||||||
flashwebfs:
|
|
||||||
@echo define call1>$(FLASHER_PATH)file_info.jlink
|
|
||||||
@echo set '$$'ImageSize = $(shell printf '0x%X\n' $$(stat --printf="%s" $(BIN_DIR)/webpages.espfs))>>$(FLASHER_PATH)file_info.jlink
|
|
||||||
@echo set '$$'ImageAddr = 0x0D0000>>$(FLASHER_PATH)file_info.jlink
|
|
||||||
@echo end>>$(FLASHER_PATH)file_info.jlink
|
|
||||||
@echo define call2>>$(FLASHER_PATH)file_info.jlink
|
|
||||||
@echo FlasherWrite $(BIN_DIR)/webpages.espfs '$$'ImageAddr '$$'ImageSize>>$(FLASHER_PATH)file_info.jlink
|
|
||||||
@echo end>>$(FLASHER_PATH)file_info.jlink
|
|
||||||
@cmd /K start $(JLINK_PATH)$(JLINK_GDBSRV) -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
|
||||||
@$(GDB) -x $(FLASHER_PATH)gdb_wrfile.jlink
|
|
||||||
#@taskkill /F /IM $(JLINK_GDBSRV)
|
|
||||||
|
|
||||||
flash_OTA:
|
|
||||||
@cmd /K start $(JLINK_PATH)$(JLINK_GDBSRV) -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
|
||||||
@$(GDB) -x $(FLASHER_PATH)gdb_ota.jlink
|
|
||||||
#@taskkill /F /IM $(JLINK_GDBSRV)
|
|
||||||
|
|
||||||
else
|
|
||||||
|
|
||||||
flashburn:
|
|
||||||
@$(OPENOCD) -f interface/$(FLASHER).cfg -c "transport select swd" -f $(FLASHER_PATH)rtl8710.ocd -c "init" -c "adapter_khz $(FLASHER_SPEED)" -c "reset halt" \
|
|
||||||
-c "rtl8710_flash_auto_erase 1" -c "rtl8710_flash_auto_verify 1" \
|
|
||||||
-c "rtl8710_flash_write $(RAM1P_IMAGE) 0" \
|
|
||||||
-c "rtl8710_flash_write $(RAM2P_IMAGE) 0xb000" \
|
|
||||||
-c "rtl8710_reboot" -c "reset run" -c shutdown
|
|
||||||
|
|
||||||
flashimage2p:
|
|
||||||
@$(OPENOCD) -f interface/$(FLASHER).cfg -c "transport select swd" -f $(FLASHER_PATH)rtl8710.ocd -c "init" -c "adapter_khz $(FLASHER_SPEED)" -c "reset halt" \
|
|
||||||
-c "rtl8710_flash_auto_erase 1" -c "rtl8710_flash_auto_verify 1" \
|
|
||||||
-c "rtl8710_flash_write $(RAM2P_IMAGE) 0xb000" \
|
|
||||||
-c "rtl8710_reboot" -c "reset run" -c shutdown
|
|
||||||
|
|
||||||
flashwebfs:
|
|
||||||
@$(OPENOCD) -f interface/$(FLASHER).cfg -c "transport select swd" -f $(FLASHER_PATH)rtl8710.ocd -c "init" -c "adapter_khz $(FLASHER_SPEED)" -c "reset halt" \
|
|
||||||
-c "rtl8710_flash_auto_erase 1" -c "rtl8710_flash_auto_verify 1" \
|
|
||||||
-c "rtl8710_flash_write $(BIN_DIR)/webpages.espfs 0xd0000" \
|
|
||||||
-c "rtl8710_reboot" -c "reset run" -c shutdown
|
|
||||||
|
|
||||||
|
|
||||||
reset:
|
|
||||||
# @$(JLINK_PATH)$(JLINK_EXE) -Device CORTEX-M3 -If SWD -Speed $(FLASHER_SPEED) flasher/RTLreset.JLinkScript
|
|
||||||
@$(OPENOCD) -f interface/$(FLASHER).cfg -c "transport select swd" -f $(FLASHER_PATH)rtl8710.ocd -c "init" -c "adapter_khz $(FLASHER_SPEED)" -c "reset halt" \
|
|
||||||
-c "rtl8710_reboot" -c shutdown
|
|
||||||
|
|
||||||
runram:
|
|
||||||
# @$(JLINK_PATH)$(JLINK_GDB) -device Cortex-M3 -if SWD -ir -endian little -speed $(FLASHER_SPEED)
|
|
||||||
# @$(GDB) -x flasher/gdb_run_ram.jlink
|
|
||||||
# @taskkill.exe -F -IM $(JLINK_GDB)
|
|
||||||
@$(OPENOCD) -f interface/$(FLASHER).cfg -c "transport select swd" -f $(FLASHER_PATH)rtl8710.ocd -c "init" -c "adapter_khz $(FLASHER_SPEED)" -c "reset halt" \
|
|
||||||
-c "load_image $(RAM1R_IMAGE) 0x10000bc8 bin" \
|
|
||||||
-c "load_image $(RAM2_IMAGE) 0x10006000 bin" \
|
|
||||||
-c "mww 0x40000210 0x20200113" \
|
|
||||||
-c "reset run" -c shutdown
|
|
||||||
|
|
||||||
endif
|
|
||||||
|
|
||||||
$(NMAPFILE): $(ELFFILE)
|
|
||||||
@echo "==========================================================="
|
|
||||||
@echo "Build names map file"
|
|
||||||
@echo $@
|
|
||||||
@$(NM) $< | sort > $@
|
|
||||||
# @echo "==========================================================="
|
|
||||||
|
|
||||||
$(FLASH_IMAGE): $(RAM1P_IMAGE) $(RAM2P_IMAGE) $(RAM3P_IMAGE)
|
|
||||||
@echo "==========================================================="
|
|
||||||
@echo "Make Flash image ($(FLASH_IMAGE))"
|
|
||||||
# @echo "==========================================================="
|
|
||||||
@mkdir -p $(BIN_DIR)
|
|
||||||
@rm -f $(FLASH_IMAGE)
|
|
||||||
@cat $(RAM1P_IMAGE) > $(FLASH_IMAGE)
|
|
||||||
# @chmod 777 $(FLASH_IMAGE)
|
|
||||||
ifdef PADDINGSIZE
|
|
||||||
@$(PADDING) $(PADDINGSIZE) 0xFF $(FLASH_IMAGE)
|
|
||||||
endif
|
|
||||||
@cat $(RAM2P_IMAGE) >> $(FLASH_IMAGE)
|
|
||||||
@cat $(RAM3P_IMAGE) >> $(FLASH_IMAGE)
|
|
||||||
# @echo "Image ($(FLASH_IMAGE)) size $(shell printf '%d\n' $$(( $$(stat --printf="%s" $(FLASH_IMAGE)) )) ) bytes"
|
|
||||||
# @echo "==========================================================="
|
|
||||||
# @rm $(BIN_DIR)/ram_*.p.bin
|
|
||||||
|
|
||||||
$(OTA_IMAGE): $(RAM2NS_IMAGE) $(RAM3_IMAGE)
|
|
||||||
@echo "==========================================================="
|
|
||||||
@echo "Make OTA image ($(OTA_IMAGE))"
|
|
||||||
@rm -f $(OTA_IMAGE)
|
|
||||||
@cat $(RAM2NS_IMAGE) > $(OTA_IMAGE)
|
|
||||||
@cat $(RAM3P_IMAGE) >> $(OTA_IMAGE)
|
|
||||||
# @chmod 777 $(OTA_IMAGE)
|
|
||||||
@$(CHCKSUM) $(OTA_IMAGE) || true
|
|
||||||
# @echo "==========================================================="
|
|
||||||
|
|
||||||
$(RAM1P_IMAGE): $(ELFFILE) $(NMAPFILE)
|
|
||||||
@echo "==========================================================="
|
|
||||||
@echo "Create image1r ($(RAM1R_IMAGE))"
|
|
||||||
# @echo "===========================================================" .bootloader
|
|
||||||
ifdef COMPILED_BOOT
|
|
||||||
@mkdir -p $(BIN_DIR)
|
|
||||||
@rm -f $(RAM1_IMAGE) $(RAM1R_IMAGE)
|
|
||||||
ifdef COMPILED_BOOT_BIN
|
|
||||||
@$(eval RAM1_START_ADDR := $(shell grep _binary_build_bin_ram_1_r_bin_start $(NMAPFILE) | awk '{print $$1}'))
|
|
||||||
@$(eval RAM1_END_ADDR := $(shell grep _binary_build_bin_ram_1_r_bin_end $(NMAPFILE) | awk '{print $$1}'))
|
|
||||||
else
|
|
||||||
@$(eval RAM1_START_ADDR := $(shell grep __ram_image1_text_start__ $(NMAPFILE) | awk '{print $$1}'))
|
|
||||||
@$(eval RAM1_END_ADDR := $(shell grep __ram_image1_text_end__ $(NMAPFILE) | awk '{print $$1}'))
|
|
||||||
endif
|
|
||||||
$(if $(RAM1_START_ADDR),,$(error "Not found __ram_image1_text_start__!"))
|
|
||||||
$(if $(RAM1_END_ADDR),,$(error "Not found __ram_image1_text_end__!"))
|
|
||||||
ifeq ($(RAM1_START_ADDR),$(RAM1_END_ADDR))
|
|
||||||
ifdef COMPILED_BOOT_BIN
|
|
||||||
$(OBJCOPY) --change-section-address .boot.head=0x10000ba8 -j .boot.head -j .bootloader -Obinary $(ELFFILE) $(RAM1P_IMAGE)
|
|
||||||
else
|
|
||||||
# $(OBJCOPY) -j .rom_ram -Obinary $(ELFFILE) $(RAM_IMAGE)
|
|
||||||
$(OBJCOPY) -j .ram.start.table -j .ram_image1.text -Obinary $(ELFFILE) $(RAM1R_IMAGE)
|
|
||||||
$(PICK) 0x$(RAM1_START_ADDR) 0x$(RAM1_END_ADDR) $(RAM1R_IMAGE) $(RAM1P_IMAGE) head+reset_offset 0x0B000
|
|
||||||
endif
|
|
||||||
else
|
|
||||||
$(error "BOOT-image size = 0")
|
|
||||||
# $(error Flasher: COMPILE_BOOT = No)
|
|
||||||
endif
|
|
||||||
else
|
|
||||||
@if [ -s $(RAM1R_IMAGE) ]; then echo "Use external $(RAM1R_IMAGE)!"; fi
|
|
||||||
endif
|
|
||||||
|
|
||||||
$(RAM2P_IMAGE): $(ELFFILE) $(NMAPFILE)
|
|
||||||
@echo "==========================================================="
|
|
||||||
@echo "Create image2p ($(RAM2P_IMAGE))"
|
|
||||||
# @echo "==========================================================="
|
|
||||||
@mkdir -p $(BIN_DIR)
|
|
||||||
@rm -f $(RAM2_IMAGE) $(RAM2P_IMAGE)
|
|
||||||
@$(eval RAM2_START_ADDR = $(shell grep __ram_image2_text $(NMAPFILE) | grep _start__ | awk '{print $$1}'))
|
|
||||||
@$(eval RAM2_END_ADDR = $(shell grep __ram_image2_text $(NMAPFILE) | grep _end__ | awk '{print $$1}'))
|
|
||||||
$(if $(RAM2_START_ADDR),,$(error "Not found __ram_image2_text_start__!"))
|
|
||||||
$(if $(RAM2_END_ADDR),,$(error "Not found __ram_image2_text_end__!"))
|
|
||||||
@$(OBJCOPY) -j .image2.start.table -j .ram_image2.text -j .ram_image2.rodata -j .ram.data -Obinary $(ELFFILE) $(RAM2_IMAGE)
|
|
||||||
@$(PICK) 0x$(RAM2_START_ADDR) 0x$(RAM2_END_ADDR) $(RAM2_IMAGE) $(RAM2P_IMAGE) body+reset_offset+sig
|
|
||||||
|
|
||||||
$(RAM2NS_IMAGE):$(ELFFILE) $(NMAPFILE)
|
|
||||||
@echo "==========================================================="
|
|
||||||
@echo "Create image2ns ($(RAM2NS_IMAGE))"
|
|
||||||
# @echo "==========================================================="
|
|
||||||
mkdir -p $(BIN_DIR)
|
|
||||||
rm -f $(RAM2_IMAGE) $(RAM2NS_IMAGE)
|
|
||||||
$(eval RAM2_START_ADDR = $(shell grep __ram_image2_text $(NMAPFILE) | grep _start__ | awk '{print $$1}'))
|
|
||||||
$(eval RAM2_END_ADDR = $(shell grep __ram_image2_text $(NMAPFILE) | grep _end__ | awk '{print $$1}'))
|
|
||||||
$(if $(RAM2_START_ADDR),,$(error "Not found __ram_image2_text_start__!"))
|
|
||||||
$(if $(RAM2_END_ADDR),,$(error "Not found __ram_image2_text_end__!"))
|
|
||||||
$(OBJCOPY) -j .image2.start.table -j .ram_image2.text -j .ram_image2.rodata -j .ram.data -Obinary $(ELFFILE) $(RAM2_IMAGE)
|
|
||||||
$(PICK) 0x$(RAM2_START_ADDR) 0x$(RAM2_END_ADDR) $(RAM2_IMAGE) $(RAM2NS_IMAGE) body+reset_offset
|
|
||||||
|
|
||||||
$(RAM3_IMAGE): $(ELFFILE) $(NMAPFILE)
|
|
||||||
@echo "==========================================================="
|
|
||||||
@echo "Create image3 (SDRAM, $(RAM3P_IMAGE))"
|
|
||||||
# @echo "==========================================================="
|
|
||||||
@mkdir -p $(BIN_DIR)
|
|
||||||
@rm -f $(RAM3_IMAGE) $(RAM3P_IMAGE)
|
|
||||||
@$(eval RAM3_START_ADDR = $(shell grep __sdram_data_ $(NMAPFILE) | grep _start__ | awk '{print $$1}'))
|
|
||||||
@$(eval RAM3_END_ADDR = $(shell grep __sdram_data_ $(NMAPFILE) | grep _end__ | awk '{print $$1}'))
|
|
||||||
$(if $(RAM3_START_ADDR),,$(error "Not found __sdram_data_start__!"))
|
|
||||||
$(if $(RAM3_END_ADDR),,$(error "Not found __sdram_data_end__!"))
|
|
||||||
#ifneq ($(RAM3_START_ADDR),$(RAM3_END_ADDR))
|
|
||||||
@echo $(RAM3_START_ADDR) $(RAM3_END_ADDR)
|
|
||||||
@$(OBJCOPY) -j .image3 -j .sdr_text -j .sdr_rodata -j .sdr_data -Obinary $(ELFFILE) $(RAM3_IMAGE)
|
|
||||||
$(PICK) 0x$(RAM3_START_ADDR) 0x$(RAM3_END_ADDR) $(RAM3_IMAGE) $(RAM3P_IMAGE) body+reset_offset
|
|
||||||
#else
|
|
||||||
# @rm -f $(RAM3_IMAGE) $(RAM3P_IMAGE)
|
|
||||||
# @echo "SDRAM not used (size = 0)"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
$(ELFFILE):
|
|
||||||
$(error Falsher: file $@ not found)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
@rm -f $(BIN_DIR)/*.bin
|
|
||||||
|
|
44
paths.mk
44
paths.mk
|
@ -1,44 +0,0 @@
|
||||||
#---------------------------
|
|
||||||
# User defined
|
|
||||||
#---------------------------
|
|
||||||
SDK_PATH = ../RTL00MP3/RTL00_SDKV35a/
|
|
||||||
#GCC_PATH = d:/MCU/GNU_Tools_ARM_Embedded/5.2_2015q4/bin/# + or set in PATH
|
|
||||||
#OPENOCD_PATH = d:/MCU/OpenOCD/bin/# + or set in PATH
|
|
||||||
TOOLS_PATH ?= $(SDK_PATH)component/soc/realtek/8195a/misc/iar_utility/common/tools/
|
|
||||||
FLASHER_TYPE ?= Jlink
|
|
||||||
#FLASHER_TYPE ?= OCD
|
|
||||||
FLASHER_PATH ?= flasher/
|
|
||||||
JLINK_PATH ?= D:/MCU/SEGGER/JLink_V612i/
|
|
||||||
JLINK_GDBSRV ?= JLinkGDBServer.exe
|
|
||||||
#---------------------------
|
|
||||||
# Default
|
|
||||||
#---------------------------
|
|
||||||
# Compilation tools
|
|
||||||
CROSS_COMPILE = $(GCC_PATH)arm-none-eabi-
|
|
||||||
AR = $(CROSS_COMPILE)ar
|
|
||||||
CC = $(CROSS_COMPILE)gcc
|
|
||||||
AS = $(CROSS_COMPILE)as
|
|
||||||
NM = $(CROSS_COMPILE)nm
|
|
||||||
LD = $(CROSS_COMPILE)gcc
|
|
||||||
GDB = $(CROSS_COMPILE)gdb
|
|
||||||
SIZE = $(CROSS_COMPILE)size
|
|
||||||
OBJCOPY = $(CROSS_COMPILE)objcopy
|
|
||||||
OBJDUMP = $(CROSS_COMPILE)objdump
|
|
||||||
|
|
||||||
# TARGET dirs
|
|
||||||
TARGET ?= build
|
|
||||||
OBJ_DIR ?= $(TARGET)/obj
|
|
||||||
BIN_DIR ?= $(TARGET)/bin
|
|
||||||
ELFFILE ?= $(OBJ_DIR)/$(TARGET).axf
|
|
||||||
|
|
||||||
# Make bunary tools
|
|
||||||
ifneq ($(shell uname), Linux)
|
|
||||||
EXE = .exe
|
|
||||||
endif
|
|
||||||
PICK = $(TOOLS_PATH)pick$(EXE)
|
|
||||||
PADDING = $(TOOLS_PATH)padding$(EXE)
|
|
||||||
CHCKSUM = $(TOOLS_PATH)checksum$(EXE)
|
|
||||||
|
|
||||||
# openocd tools
|
|
||||||
OPENOCD = $(OPENOCD_PATH)openocd
|
|
||||||
|
|
25
project.mk
Normal file
25
project.mk
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
#=============================================
|
||||||
|
# SDK CONFIG
|
||||||
|
#=============================================
|
||||||
|
#USE_FATFS = 1
|
||||||
|
#USE_SDIOH = 1
|
||||||
|
#USE_POLARSSL = 1
|
||||||
|
#USE_P2P_WPS = 1
|
||||||
|
#USE_GCC_LIB = 1
|
||||||
|
USE_AT = 1
|
||||||
|
USE_MBED = 1
|
||||||
|
|
||||||
|
ifndef USE_AT
|
||||||
|
USE_NEWCONSOLE = 1
|
||||||
|
USE_WIFI_API = 1
|
||||||
|
endif
|
||||||
|
|
||||||
|
#RTOSDIR=freertos_v8.1.2
|
||||||
|
RTOSDIR=freertos_v9.0.0
|
||||||
|
LWIPDIR=lwip_v1.4.1
|
||||||
|
include $(SDK_PATH)sdkset.mk
|
||||||
|
#=============================================
|
||||||
|
# User Files
|
||||||
|
#=============================================
|
||||||
|
#user main
|
||||||
|
ADD_SRC_C += project/src/user/main.c
|
93
sdkbuild.mk
93
sdkbuild.mk
|
@ -1,93 +0,0 @@
|
||||||
|
|
||||||
include sdkset.mk
|
|
||||||
include paths.mk
|
|
||||||
|
|
||||||
INCFLAGS = $(patsubst %,-I%,$(patsubst sdk/%,$(SDK_PATH)%,$(INCLUDES)))
|
|
||||||
|
|
||||||
LIBFLAGS = $(addprefix -L,$(patsubst sdk/%,$(SDK_PATH)%,$(PATHLIBS))) $(addprefix -l,$(LIBS))
|
|
||||||
|
|
||||||
LFLAGS += -Wl,-Map=$(OBJ_DIR)/$(TARGET).map
|
|
||||||
|
|
||||||
CFLAGS += $(INCFLAGS)
|
|
||||||
|
|
||||||
SRC_O = $(patsubst %.c,%.o,$(patsubst sdk/%,$(SDK_PATH)%,$(ADD_SRC_C))) $(patsubst %.c,%.o,$(patsubst sdk/%,$(SDK_PATH)%,$(SRC_C)))
|
|
||||||
DRAM_O = $(patsubst %.c,%.o,$(patsubst sdk/%,$(SDK_PATH)%,$(DRAM_C)))
|
|
||||||
BOOT_O = $(patsubst %.c,%.o,$(patsubst sdk/%,$(SDK_PATH)%,$(BOOT_C)))
|
|
||||||
|
|
||||||
SRC_C_LIST = $(patsubst sdk/%,$(SDK_PATH)%,$(ADD_SRC_C)) $(patsubst sdk/%,$(SDK_PATH)%,$(SRC_C)) $(patsubst sdk/%,$(SDK_PATH)%,$(DRAM_C)) $(patsubst sdk/%,$(SDK_PATH)%,$(BOOT_C))
|
|
||||||
OBJ_LIST = $(addprefix $(OBJ_DIR)/,$(patsubst %.c,%.o,$(SRC_C_LIST)))
|
|
||||||
DEPENDENCY_LIST = $(patsubst %.c,$(OBJ_DIR)/%.d,$(SRC_C_LIST))
|
|
||||||
|
|
||||||
TARGET ?= build
|
|
||||||
OBJ_DIR ?= $(TARGET)/obj
|
|
||||||
BIN_DIR ?= $(TARGET)/bin
|
|
||||||
ELFFILE ?= $(OBJ_DIR)/$(TARGET).axf
|
|
||||||
|
|
||||||
all: prerequirement application
|
|
||||||
mp: prerequirement application
|
|
||||||
|
|
||||||
.PHONY: build_info
|
|
||||||
build_info:
|
|
||||||
@echo \#define UTS_VERSION \"`date +%Y/%m/%d-%T`\" > .ver
|
|
||||||
@echo \#define RTL8195AFW_COMPILE_TIME \"`date +%Y/%m/%d-%T`\" >> .ver
|
|
||||||
@echo \#define RTL8195AFW_COMPILE_DATE \"`date +%Y%m%d`\" >> .ver
|
|
||||||
@echo \#define RTL8195AFW_COMPILE_BY \"`id -u -n`\" >> .ver
|
|
||||||
@echo \#define RTL8195AFW_COMPILE_HOST \"`$(HOSTNAME_APP)`\" >> .ver
|
|
||||||
@if [ -x /bin/dnsdomainname ]; then \
|
|
||||||
echo \#define RTL8195AFW_COMPILE_DOMAIN \"`dnsdomainname`\"; \
|
|
||||||
elif [ -x /bin/domainname ]; then \
|
|
||||||
echo \#define RTL8195AFW_COMPILE_DOMAIN \"`domainname`\"; \
|
|
||||||
else \
|
|
||||||
echo \#define RTL8195AFW_COMPILE_DOMAIN ; \
|
|
||||||
fi >> .ver
|
|
||||||
@echo \#define RTL195AFW_COMPILER \"gcc `$(CC) $(CFLAGS) -dumpversion | tr --delete '\r'`\" >> .ver
|
|
||||||
@mv -f .ver project/inc/$@.h
|
|
||||||
|
|
||||||
.PHONY: application
|
|
||||||
application: build_info $(SRC_O) $(DRAM_O) $(BOOT_O)
|
|
||||||
@echo "==========================================================="
|
|
||||||
@echo "Link ($(TARGET))"
|
|
||||||
# @echo "==========================================================="
|
|
||||||
@mkdir -p $(BIN_DIR) $(OBJ_DIR)
|
|
||||||
@$(file > $(OBJ_DIR)/obj_list.lst,$(OBJ_LIST))
|
|
||||||
@$(LD) $(LFLAGS) -o $(ELFFILE) @$(OBJ_DIR)/obj_list.lst $(LIBFLAGS) -T$(LDFILE)
|
|
||||||
@$(OBJDUMP) -d $(ELFFILE) > $(OBJ_DIR)/$(TARGET).asm
|
|
||||||
|
|
||||||
.PHONY: prerequirement
|
|
||||||
#.NOTPARALLEL: prerequirement
|
|
||||||
prerequirement:
|
|
||||||
# @$(file >DEPENDENCY_LIST.txt,$(DEPENDENCY_LIST))
|
|
||||||
@echo "==========================================================="
|
|
||||||
@echo "Compile ($(TARGET))"
|
|
||||||
# @echo "==========================================================="
|
|
||||||
@mkdir -p $(OBJ_DIR)
|
|
||||||
|
|
||||||
$(SRC_O): %.o : %.c
|
|
||||||
@echo $<
|
|
||||||
@mkdir -p $(OBJ_DIR)/$(dir $@)
|
|
||||||
@$(CC) $(CFLAGS) $(INCFLAGS) -c $< -o $(OBJ_DIR)/$@
|
|
||||||
@$(CC) -MM $(CFLAGS) $(INCFLAGS) $< -MT $@ -MF $(OBJ_DIR)/$(patsubst %.o,%.d,$@)
|
|
||||||
|
|
||||||
$(DRAM_O): %.o : %.c
|
|
||||||
@echo $<
|
|
||||||
@mkdir -p $(OBJ_DIR)/$(dir $@)
|
|
||||||
@$(CC) $(CFLAGS) $(INCFLAGS) -c $< -o $(OBJ_DIR)/$@
|
|
||||||
@$(OBJCOPY) --prefix-alloc-sections .sdram $(OBJ_DIR)/$@
|
|
||||||
@$(CC) -MM $(CFLAGS) $(INCFLAGS) $< -MT $@ -MF $(OBJ_DIR)/$(patsubst %.o,%.d,$@)
|
|
||||||
|
|
||||||
$(BOOT_O): %.o : %.c
|
|
||||||
@echo $<
|
|
||||||
@mkdir -p $(OBJ_DIR)/$(dir $@)
|
|
||||||
@$(CC) $(CFLAGS) $(INCFLAGS) -c $< -o $(OBJ_DIR)/$@
|
|
||||||
@$(OBJCOPY) --prefix-alloc-sections .boot $(OBJ_DIR)/$@
|
|
||||||
@$(CC) -MM $(CFLAGS) $(INCFLAGS) $< -MT $@ -MF $(OBJ_DIR)/$(patsubst %.o,%.d,$@)
|
|
||||||
|
|
||||||
-include $(DEPENDENCY_LIST)
|
|
||||||
|
|
||||||
VPATH:=$(OBJ_DIR) $(SDK_PATH)
|
|
||||||
|
|
||||||
#.PHONY: clean
|
|
||||||
clean:
|
|
||||||
rm -rf $(OBJ_DIR) $(BIN_DIR) $(OBJ_DIR)/$(SDK_PATH)
|
|
||||||
|
|
||||||
|
|
432
sdkset.mk
432
sdkset.mk
|
@ -1,432 +0,0 @@
|
||||||
USE_AT = 1
|
|
||||||
#USE_FATFS = 1
|
|
||||||
#USE_SDIOH = 1
|
|
||||||
#USE_POLARSSL = 1
|
|
||||||
#USE_P2P_WPS = 1
|
|
||||||
ifndef USE_AT
|
|
||||||
USE_NEWCONSOLE = 1
|
|
||||||
USE_WIFI_API = 1
|
|
||||||
endif
|
|
||||||
USE_MBED = 1
|
|
||||||
|
|
||||||
#RTOSDIR=freertos_v8.1.2
|
|
||||||
RTOSDIR=freertos_v9.0.0
|
|
||||||
LWIPDIR=lwip_v1.4.1
|
|
||||||
|
|
||||||
# FLAGS
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
CFLAGS = -DM3 -DCONFIG_PLATFORM_8195A -DGCC_ARMCM3 -DARDUINO_SDK -DF_CPU=166666666L -DNDEBUG
|
|
||||||
CFLAGS += -mcpu=cortex-m3 -mthumb -g2 -Os -std=gnu99 -Wall -Werror
|
|
||||||
CFLAGS += -fno-common -fmessage-length=0 -ffunction-sections -fdata-sections -fomit-frame-pointer -fno-short-enums -fsigned-char
|
|
||||||
CFLAGS += -w -Wno-pointer-sign
|
|
||||||
LFLAGS = -mcpu=cortex-m3 -mthumb -g -Os -nostartfiles -nostdlib
|
|
||||||
#--specs=nano.specs
|
|
||||||
LFLAGS += -Wl,--gc-sections -Wl,--cref -Wl,--entry=Reset_Handler -Wl,--no-enum-size-warning -Wl,--no-wchar-size-warning -Wl,-nostdlib
|
|
||||||
|
|
||||||
# LIBS
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
LIBS =
|
|
||||||
all: LIBS +=_platform_new _wlan _p2p _wps _websocket _sdcard _xmodem _mdns
|
|
||||||
# m c nosys gcc
|
|
||||||
mp: LIBS +=_platform_new _wlan_mp _wps _p2p _websocket _sdcard _xmodem _mdns
|
|
||||||
PATHLIBS = sdk/component/soc/realtek/8195a/misc/bsp/lib/common/gcc
|
|
||||||
LDFILE = rlx8195A-symbol-v04-img2.ld
|
|
||||||
BOOTS = sdk/component/soc/realtek/8195a/misc/bsp/image
|
|
||||||
|
|
||||||
# Include folder list
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
INCLUDES = ../inc
|
|
||||||
INCLUDES += project/inc
|
|
||||||
INCLUDES += sdk/component/soc/realtek/common/bsp
|
|
||||||
INCLUDES += sdk/component/os/freertos
|
|
||||||
INCLUDES += sdk/component/os/freertos/$(RTOSDIR)/Source/include
|
|
||||||
INCLUDES += sdk/component/os/freertos/$(RTOSDIR)/Source/portable/GCC/ARM_CM3
|
|
||||||
INCLUDES += sdk/component/os/os_dep/include sdk/component/soc/realtek/8195a/misc/driver
|
|
||||||
INCLUDES += sdk/component/common/api/network/include
|
|
||||||
INCLUDES += sdk/component/common/api
|
|
||||||
INCLUDES += sdk/component/common/api/platform
|
|
||||||
INCLUDES += sdk/component/common/api/wifi
|
|
||||||
INCLUDES += sdk/component/common/api/wifi/rtw_wpa_supplicant/src
|
|
||||||
INCLUDES += sdk/component/common/network
|
|
||||||
INCLUDES += sdk/component/common/network/lwip/$(LWIPDIR)/port/realtek/freertos
|
|
||||||
INCLUDES += sdk/component/common/network/lwip/$(LWIPDIR)/src/include
|
|
||||||
INCLUDES += sdk/component/common/network/lwip/$(LWIPDIR)/src/include/lwip
|
|
||||||
INCLUDES += sdk/component/common/network/lwip/$(LWIPDIR)/src/include/ipv4
|
|
||||||
INCLUDES += sdk/component/common/network/lwip/$(LWIPDIR)/port/realtek
|
|
||||||
INCLUDES += sdk/component/common/test
|
|
||||||
INCLUDES += sdk/component/soc/realtek/8195a/cmsis
|
|
||||||
INCLUDES += sdk/component/soc/realtek/8195a/cmsis/device
|
|
||||||
INCLUDES += sdk/component/soc/realtek/8195a/fwlib
|
|
||||||
INCLUDES += sdk/component/soc/realtek/8195a/fwlib/rtl8195a
|
|
||||||
INCLUDES += sdk/component/soc/realtek/8195a/misc/rtl_std_lib/
|
|
||||||
INCLUDES += sdk/component/soc/realtek/8195a/misc/rtl_std_lib/include
|
|
||||||
INCLUDES += sdk/component/common/drivers
|
|
||||||
INCLUDES += sdk/component/common/drivers/i2s
|
|
||||||
INCLUDES += sdk/component/common/drivers/wlan/realtek/include
|
|
||||||
INCLUDES += sdk/component/common/drivers/wlan/realtek/src/osdep
|
|
||||||
INCLUDES += sdk/component/common/drivers/wlan/realtek/src/hci
|
|
||||||
INCLUDES += sdk/component/common/drivers/wlan/realtek/src/hal
|
|
||||||
INCLUDES += sdk/component/common/drivers/wlan/realtek/src/hal/OUTSRC
|
|
||||||
INCLUDES += sdk/component/common/drivers/sdio/realtek/sdio_host/inc
|
|
||||||
INCLUDES += sdk/component/soc/realtek/8195a/fwlib/ram_lib/wlan/realtek/wlan_ram_map/rom
|
|
||||||
INCLUDES += sdk/component/common/network/ssl/ssl_ram_map/rom
|
|
||||||
#INCLUDES += sdk/component/common/media/codec
|
|
||||||
#INCLUDES += sdk/component/common/drivers/usb_class/host/uvc/inc
|
|
||||||
#INCLUDES += sdk/component/common/drivers/usb_class/device
|
|
||||||
#INCLUDES += sdk/component/common/drivers/usb_class/device/class
|
|
||||||
#INCLUDES += sdk/component/soc/realtek/8195a/fwlib/ram_lib/usb_otg/include
|
|
||||||
|
|
||||||
# Source file list
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
SRC_C =
|
|
||||||
DRAM_C =
|
|
||||||
BOOT_C =
|
|
||||||
|
|
||||||
#bootloader
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/ram_lib/rtl_bios_data.c
|
|
||||||
BOOT_C += sdk/component/soc/realtek/8195a/fwlib/ram_lib/rtl_boot.c
|
|
||||||
|
|
||||||
#cmsis
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/cmsis/device/system_8195a.c
|
|
||||||
|
|
||||||
#console new/old
|
|
||||||
ifdef USE_NEWCONSOLE
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/misc/driver/rtl_console_new.c
|
|
||||||
else
|
|
||||||
SRC_C += sdk/component/common/api/at_cmd/log_service.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/misc/driver/rtl_consol.c
|
|
||||||
endif
|
|
||||||
ifdef USE_AT
|
|
||||||
DRAM_C += sdk/component/common/api/at_cmd/atcmd_ethernet.c
|
|
||||||
DRAM_C += sdk/component/common/api/at_cmd/atcmd_lwip.c
|
|
||||||
DRAM_C += sdk/component/common/api/at_cmd/atcmd_sys.c
|
|
||||||
DRAM_C += sdk/component/common/api/at_cmd/atcmd_wifi.c
|
|
||||||
endif
|
|
||||||
#SRC_C += sdk/component/soc/realtek/8195a/misc/driver/low_level_io.c
|
|
||||||
|
|
||||||
#network - api
|
|
||||||
ifdef USE_P2P_WPS
|
|
||||||
SRC_C += sdk/component/common/api/wifi/rtw_wpa_supplicant/wpa_supplicant/wifi_p2p_config.c
|
|
||||||
SRC_C += sdk/component/common/api/wifi/rtw_wpa_supplicant/wpa_supplicant/wifi_wps_config.c
|
|
||||||
endif
|
|
||||||
SRC_C += sdk/component/common/api/wifi/rtw_wpa_supplicant/wpa_supplicant/wifi_eap_config.c
|
|
||||||
SRC_C += sdk/component/common/api/wifi/wifi_conf.c
|
|
||||||
SRC_C += sdk/component/common/api/wifi/wifi_ind.c
|
|
||||||
SRC_C += sdk/component/common/api/wifi/wifi_promisc.c
|
|
||||||
SRC_C += sdk/component/common/api/wifi/wifi_simple_config.c
|
|
||||||
SRC_C += sdk/component/common/api/wifi/wifi_util.c
|
|
||||||
SRC_C += sdk/component/common/api/lwip_netconf.c
|
|
||||||
ifdef USE_WIFI_API
|
|
||||||
SRC_C += sdk/component/common/api/wifi_api.c
|
|
||||||
SRC_C += sdk/component/common/api/wifi_api_scan.c
|
|
||||||
endif
|
|
||||||
|
|
||||||
#network - lwip
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/api/api_lib.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/api/api_msg.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/api/err.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/api/netbuf.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/api/netdb.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/api/netifapi.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/api/sockets.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/api/tcpip.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/ipv4/autoip.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/ipv4/icmp.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/ipv4/igmp.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/ipv4/inet.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/ipv4/inet_chksum.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/ipv4/ip.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/ipv4/ip_addr.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/ipv4/ip_frag.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/def.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/dhcp.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/dns.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/init.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/lwip_timers.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/mem.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/memp.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/netif.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/pbuf.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/raw.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/stats.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/sys.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/tcp.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/tcp_in.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/tcp_out.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/core/udp.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/src/netif/etharp.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/port/realtek/freertos/ethernetif.c
|
|
||||||
SRC_C += sdk/component/common/drivers/wlan/realtek/src/osdep/lwip_intf.c
|
|
||||||
SRC_C += sdk/component/common/network/lwip/$(LWIPDIR)/port/realtek/freertos/sys_arch.c
|
|
||||||
SRC_C += sdk/component/common/network/dhcp/dhcps.c
|
|
||||||
SRC_C += sdk/component/common/network/sntp/sntp.c
|
|
||||||
SRC_C += sdk/component/common/network/netbios/netbios.c
|
|
||||||
|
|
||||||
#network - mdns
|
|
||||||
#SRC_C += sdk/component/common/network/mDNS/mDNSPlatform.c
|
|
||||||
|
|
||||||
#os - freertos
|
|
||||||
SRC_C += sdk/component/os/freertos/$(RTOSDIR)/Source/portable/MemMang/heap_5.c
|
|
||||||
SRC_C += sdk/component/os/freertos/$(RTOSDIR)/Source/portable/GCC/ARM_CM3/port.c
|
|
||||||
SRC_C += sdk/component/os/freertos/cmsis_os.c
|
|
||||||
SRC_C += sdk/component/os/freertos/$(RTOSDIR)/Source/croutine.c
|
|
||||||
SRC_C += sdk/component/os/freertos/$(RTOSDIR)/Source/event_groups.c
|
|
||||||
SRC_C += sdk/component/os/freertos/$(RTOSDIR)/Source/list.c
|
|
||||||
SRC_C += sdk/component/os/freertos/$(RTOSDIR)/Source/queue.c
|
|
||||||
SRC_C += sdk/component/os/freertos/$(RTOSDIR)/Source/tasks.c
|
|
||||||
SRC_C += sdk/component/os/freertos/$(RTOSDIR)/Source/timers.c
|
|
||||||
|
|
||||||
#os - osdep
|
|
||||||
SRC_C += sdk/component/os/os_dep/device_lock.c
|
|
||||||
SRC_C += sdk/component/os/freertos/freertos_service.c
|
|
||||||
SRC_C += sdk/component/os/os_dep/mailbox.c
|
|
||||||
SRC_C += sdk/component/os/os_dep/osdep_api.c
|
|
||||||
SRC_C += sdk/component/os/os_dep/osdep_service.c
|
|
||||||
SRC_C += sdk/component/os/os_dep/tcm_heap.c
|
|
||||||
|
|
||||||
ifdef USE_MBED
|
|
||||||
#peripheral - api
|
|
||||||
INCLUDES += sdk/component/common/mbed/api
|
|
||||||
INCLUDES += sdk/component/common/mbed/hal
|
|
||||||
INCLUDES += sdk/component/common/mbed/hal_ext
|
|
||||||
INCLUDES += sdk/component/common/mbed/targets/hal/rtl8195a
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/analogin_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/dma_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/efuse_api.c
|
|
||||||
#SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/ethernet_api.c
|
|
||||||
#SRC_C += sdk/component/common/drivers/ethernet_mii/ethernet_mii.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/flash_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/gpio_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/gpio_irq_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/i2c_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/i2s_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/log_uart_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/nfc_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/pinmap.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/pinmap_common.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/port_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/pwmout_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/rtc_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/serial_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/sleep.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/spdio_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/spi_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/sys_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/timer_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/us_ticker.c
|
|
||||||
SRC_C += sdk/component/common/mbed/common/us_ticker_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/common/wait_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/wdt_api.c
|
|
||||||
SRC_C += sdk/component/common/mbed/targets/hal/rtl8195a/flash_eep.c
|
|
||||||
endif
|
|
||||||
|
|
||||||
#peripheral - hal
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_32k.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_adc.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_gdma.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_gpio.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_i2c.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_i2s.c
|
|
||||||
#SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_mii.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_nfc.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_pcm.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_pwm.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_sdr_controller.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_ssi.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_timer.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_uart.c
|
|
||||||
ifdef USE_SDIOH
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_sdio_host.c
|
|
||||||
SRC_C += sdk/component/common/drivers/sdio/realtek/sdio_host/src/sd.c
|
|
||||||
SRC_C += sdk/component/common/drivers/sdio/realtek/sdio_host/src/sdio_host.c
|
|
||||||
endif
|
|
||||||
|
|
||||||
#peripheral - osdep
|
|
||||||
SRC_C += sdk/component/os/freertos/freertos_pmu.c
|
|
||||||
|
|
||||||
#peripheral - rtl8195a
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_adc.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_gdma.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_gpio.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_i2c.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_i2s.c
|
|
||||||
#SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_mii.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_nfc.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_pwm.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_ssi.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_timer.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_uart.c
|
|
||||||
|
|
||||||
#peripheral - wlan
|
|
||||||
#SRC_C += sdk/component/common/drivers/wlan/realtek/src/core/option/rtw_opt_skbuf.c
|
|
||||||
|
|
||||||
#SDRAM
|
|
||||||
#DRAM_C += sdk/component/common/api/platform/stdlib_patch.c
|
|
||||||
#SDRAM - polarssl
|
|
||||||
ifdef USE_POLARSSL
|
|
||||||
INCLUDES += sdk/component/common/network/ssl/polarssl-1.3.8/include
|
|
||||||
|
|
||||||
SRC_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/bignum.c
|
|
||||||
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/ssl_ram_map/rom/rom_ssl_ram_map.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/ssl_ram_map/ssl_ram_map.c
|
|
||||||
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/aes.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/aesni.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/arc4.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/asn1parse.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/asn1write.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/base64.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/blowfish.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/camellia.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ccm.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/certs.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/cipher.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/cipher_wrap.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ctr_drbg.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/debug.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/des.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/dhm.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ecp.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ecp_curves.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ecdh.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ecdsa.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/entropy.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/entropy_poll.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/error.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/gcm.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/havege.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/hmac_drbg.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/md.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/md_wrap.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/md2.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/md4.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/md5.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/memory_buffer_alloc.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/net.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/oid.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/padlock.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/pbkdf2.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/pem.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/pkcs5.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/pkcs11.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/pkcs12.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/pk.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/pk_wrap.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/pkparse.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/pkwrite.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/platform.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ripemd160.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/rsa.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/sha1.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/sha256.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/sha512.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ssl_cache.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ssl_ciphersuites.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ssl_cli.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ssl_srv.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/ssl_tls.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/threading.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/timing.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/version.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/version_features.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/x509.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/x509_crt.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/x509_crl.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/x509_csr.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/x509_create.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/x509write_crt.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/x509write_csr.c
|
|
||||||
DRAM_C += sdk/component/common/network/ssl/polarssl-1.3.8/library/xtea.c
|
|
||||||
endif
|
|
||||||
|
|
||||||
#utilities - FatFS
|
|
||||||
ifdef USE_FATFS
|
|
||||||
INCLUDES += sdk/component/common/file_system/fatfs
|
|
||||||
INCLUDES += sdk/component/common/file_system/fatfs/r0.10c/include
|
|
||||||
SRC_C += sdk/component/common/file_system/fatfs/fatfs_ext/src/ff_driver.c
|
|
||||||
SRC_C += sdk/component/common/file_system/fatfs/r0.10c/src/diskio.c
|
|
||||||
SRC_C += sdk/component/common/file_system/fatfs/r0.10c/src/ff.c
|
|
||||||
SRC_C += sdk/component/common/file_system/fatfs/r0.10c/src/option/ccsbcs.c
|
|
||||||
ifdef USE_SDIOH
|
|
||||||
SRC_C += sdk/component/common/file_system/fatfs/disk_if/src/sdcard.c
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Reversed SDK component
|
|
||||||
#ADD_SRC_C += sdk/component/soc/realtek/8195a/cmsis/device/app_start.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_dac.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_common.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_soc_ps_monitor.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_efuse.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_log_uart.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_pinmux.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_misc.c
|
|
||||||
#ADD_SRC_C += sdk/component/soc/realtek/8195a/fwlib/src/hal_spi_flash_ram.c
|
|
||||||
# Component clib, ...
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/fwlib/ram_lib/startup.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/ram_libc.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/ram_libgloss_retarget.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/rtl_eabi_cast_ram.c
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/rtl_math_ram.c
|
|
||||||
#if +- nostdlib..
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/ram_pvvx_libc.c
|
|
||||||
#if c_printf() float
|
|
||||||
SRC_C += sdk/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/c_stdio.c
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
# Add Source file list
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
ADD_SRC_C =
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
# SAMPLES
|
|
||||||
# -------------------------------------------------------------------
|
|
||||||
ifdef USE_AT
|
|
||||||
INCLUDES += sdk/component/common/utilities
|
|
||||||
ADD_SRC_C += sdk/component/common/api/network/src/wlan_network.c
|
|
||||||
ADD_SRC_C += sdk/component/common/api/wifi_interactive_mode.c
|
|
||||||
ADD_SRC_C += sdk/component/common/api/network/src/ping_test.c
|
|
||||||
ADD_SRC_C += sdk/component/common/utilities/webserver.c
|
|
||||||
ADD_SRC_C += sdk/component/common/utilities/tcptest.c
|
|
||||||
ADD_SRC_C += sdk/component/common/utilities/update.c
|
|
||||||
INCLUDES += sdk/component/common/example
|
|
||||||
INCLUDES += sdk/component/common/example/wlan_fast_connect
|
|
||||||
ADD_SRC_C += sdk/component/common/example/wlan_fast_connect/example_wlan_fast_connect.c
|
|
||||||
ADD_SRC_C += sdk/component/common/example/uart_atcmd/example_uart_atcmd.c
|
|
||||||
ADD_SRC_C += sdk/component/common/example/example_entry.c
|
|
||||||
ADD_SRC_C += sdk/component/common/application/xmodem/uart_fw_update.c
|
|
||||||
endif
|
|
||||||
#application
|
|
||||||
#INCLUDES += sdk/component/common/application/apple/WACServer/External/Curve25519
|
|
||||||
#INCLUDES += sdk/component/common/application/apple/WACServer/External/GladmanAES
|
|
||||||
#INCLUDES += sdk/component/common/audio
|
|
||||||
#INCLUDES += sdk/component/common/application/xmodem
|
|
||||||
#INCLUDES += sdk/component/common/application
|
|
||||||
#INCLUDES += sdk/component/common/application/iotdemokit
|
|
||||||
#INCLUDES += sdk/component/common/application/google
|
|
||||||
#INCLUDES += sdk/component/common/media/framework
|
|
||||||
#SDRAM - wigadget
|
|
||||||
#DRAM_C += sdk/component/common/application/wigadget/cloud_link.c
|
|
||||||
#DRAM_C += sdk/component/common/application/wigadget/shtc1.c
|
|
||||||
#DRAM_C += sdk/component/common/application/wigadget/wigadget.c
|
|
||||||
|
|
||||||
#utilities
|
|
||||||
#ADD_SRC_C += sdk/component/common/utilities/cJSON.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/utilities/http_client.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/utilities/uart_socket.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/utilities/xml.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/utilities/ssl_client.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/utilities/ssl_client_ext.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/utilities/uart_ymodem.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/application/uart_adapter/uart_adapter.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/example/cJSON/cJSON_example.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/example/googlenest/example_google.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/example/mdns/example_mdns.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/example/socket_select/example_socket_select.c
|
|
||||||
#ADD_SRC_C += sdk/component/common/example/xml/example_xml.c
|
|
||||||
|
|
||||||
#=============================================
|
|
||||||
# PROGECT
|
|
||||||
#=============================================
|
|
||||||
#user main
|
|
||||||
ADD_SRC_C += project/src/user/main.c
|
|
||||||
#=============================================
|
|
12
userset.mk
Normal file
12
userset.mk
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
#=============================================
|
||||||
|
# User defined
|
||||||
|
#=============================================
|
||||||
|
SDK_PATH ?= ../RTL00MP3/RTL00_SDKV35a/
|
||||||
|
#GCC_PATH = d:/MCU/GNU_Tools_ARM_Embedded/5.2_2015q4/bin/# + or set in PATH
|
||||||
|
#OPENOCD_PATH = d:/MCU/OpenOCD/bin/# + or set in PATH
|
||||||
|
TOOLS_PATH ?= $(SDK_PATH)component/soc/realtek/8195a/misc/iar_utility/common/tools/
|
||||||
|
FLASHER_TYPE ?= Jlink
|
||||||
|
#FLASHER_TYPE ?= OCD
|
||||||
|
FLASHER_PATH ?= $(SDK_PATH)flasher/
|
||||||
|
JLINK_PATH ?= D:/MCU/SEGGER/JLink_V612i/
|
||||||
|
JLINK_GDBSRV ?= JLinkGDBServer.exe
|
Loading…
Reference in a new issue