mirror of
https://github.com/drasko/open-ameba.git
synced 2024-11-28 09:10:29 +00:00
update
This commit is contained in:
parent
10a49b3995
commit
afcadda20e
20 changed files with 38 additions and 15 deletions
|
@ -1,4 +1,5 @@
|
||||||
@echo off
|
@echo off
|
||||||
|
call paths.bat
|
||||||
cd flasher
|
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"
|
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"
|
rem -c "shutdown"
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
@echo off
|
@echo off
|
||||||
|
call paths.bat
|
||||||
cd flasher
|
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"
|
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
|
echo flash read fullflash.bin
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
@echo off
|
||||||
|
call paths.bat
|
||||||
@cd flasher
|
@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"
|
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
|
rem
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
@echo off
|
@echo off
|
||||||
|
call paths.bat
|
||||||
cd flasher
|
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"
|
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
|
pause
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
@echo off
|
@echo off
|
||||||
PATH=D:\MCU\SEGGER\JLink_V610a;%PATH%
|
call paths.bat
|
||||||
start JLink.exe -Device CORTEX-M3 -If SWD -Speed 4000 flasher\RTL00ConsoleROM.JLinkScript
|
start JLink.exe -Device CORTEX-M3 -If SWD -Speed 4000 flasher\RTL00ConsoleROM.JLinkScript
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
@echo off
|
@echo off
|
||||||
PATH=D:\MCU\SEGGER\JLink_V610a;%PATH%
|
call paths.bat
|
||||||
JLink.exe -Device CORTEX-M3 -If SWD -Speed 4000 flasher/RTL_FFlash.JLinkScript
|
JLink.exe -Device CORTEX-M3 -If SWD -Speed 10000 flasher/RTL_FFlash.JLinkScript
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
@echo off
|
@echo off
|
||||||
PATH=D:\MCU\SEGGER\JLink_V610a;%PATH%
|
call paths.bat
|
||||||
JLink.exe -Device CORTEX-M3 -If SWD -Speed 1000 flasher\RTL_Reset.JLinkScript
|
JLink.exe -Device CORTEX-M3 -If SWD -Speed 1000 flasher\RTL_Reset.JLinkScript
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
@echo off
|
@echo off
|
||||||
PATH=D:\MCU\SEGGER\JLink_V610a;%PATH%
|
call paths.bat
|
||||||
start JLink.exe -Device CORTEX-M3 -If SWD -Speed 4000 flasher\RTL_RunRAM.JLinkScript
|
start JLink.exe -Device CORTEX-M3 -If SWD -Speed 4000 flasher\RTL_RunRAM.JLinkScript
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
@echo off
|
@echo off
|
||||||
PATH=D:\MCU\GNU_Tools_ARM_Embedded\5.2_2015q4\bin;D:\MCU\SEGGER\JLink_V610a;%PATH%
|
call paths.bat
|
||||||
start JLinkGDBServer.exe -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
start JLinkGDBServer.exe -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
||||||
arm-none-eabi-gdb.exe -x flasher/gdb_rdflash.jlink
|
arm-none-eabi-gdb.exe -x flasher/gdb_rdflash.jlink
|
||||||
taskkill /F /IM JLinkGDBServer.exe
|
taskkill /F /IM JLinkGDBServer.exe
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
@echo off
|
@echo off
|
||||||
PATH=D:\MCU\GNU_Tools_ARM_Embedded\5.2_2015q4\bin;D:\MCU\SEGGER\JLink_V610a;%PATH%
|
call paths.bat
|
||||||
@if exist build\obj\build.axf goto run
|
@if exist build\obj\build.axf goto run
|
||||||
echo File 'build\obj\build.axf' not found!
|
echo File 'build\obj\build.axf' not found!
|
||||||
echo Build project...
|
echo Build project...
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
@echo off
|
@echo off
|
||||||
PATH=D:\MCU\GNU_Tools_ARM_Embedded\5.2_2015q4\bin;D:\MCU\SEGGER\JLink_V610a;%PATH%
|
call paths.bat
|
||||||
@if %1x==x goto xxx
|
@if %1x==x goto xxx
|
||||||
set img_file=%1
|
set img_file=%1
|
||||||
goto run
|
goto run
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
@echo off
|
@echo off
|
||||||
PATH=D:\MCU\GNU_Tools_ARM_Embedded\5.2_2015q4\bin;D:\MCU\SEGGER\JLink_V610a;%PATH%
|
call paths.bat
|
||||||
start JLinkGDBServer.exe -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
start JLinkGDBServer.exe -device Cortex-M3 -if SWD -ir -endian little -speed 1000
|
||||||
arm-none-eabi-gdb.exe -x flasher/gdb_init.jlink
|
arm-none-eabi-gdb.exe -x flasher/gdb_init.jlink
|
||||||
taskkill /F /IM JLinkGDBServer.exe
|
taskkill /F /IM JLinkGDBServer.exe
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
@echo off
|
@echo off
|
||||||
|
call paths.bat
|
||||||
cd flasher
|
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 "rtl8710_flash_read ../fullflash.bin 0 1048576" -c "shutdown"
|
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
|
echo flash read fullflash.bin
|
||||||
pause
|
pause
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
@echo off
|
@echo off
|
||||||
cd flasher
|
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 3900" -c "rtl8710_flash_read_id" -c "rtl8710_flash_read ../fullflash.bin 0 1048576" -c "shutdown"
|
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
|
echo flash read fullflash.bin
|
||||||
pause
|
pause
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
@echo off
|
@echo off
|
||||||
PATH=D:\MCU\OpenOCD;%PATH%
|
call paths.bat
|
||||||
taskkill /F /IM openocd.exe
|
taskkill /F /IM openocd.exe
|
||||||
start openocd -f interface\Jlink.cfg -f flasher\ameba1.cfg
|
start openocd -f interface\Jlink.cfg -f flasher\ameba1.cfg
|
||||||
|
|
|
@ -1154,8 +1154,21 @@ void fATSL(void *arg) {
|
||||||
#if CONFIG_UART_XMODEM
|
#if CONFIG_UART_XMODEM
|
||||||
void fATSX(void *arg)
|
void fATSX(void *arg)
|
||||||
{
|
{
|
||||||
|
#ifdef RTL8711AM
|
||||||
|
#error "Set OTU_FW_Update UARTx pins!"
|
||||||
// use xmodem to update, RX: PA_6, TX: PA_7, baudrate: 1M
|
// use xmodem to update, RX: PA_6, TX: PA_7, baudrate: 1M
|
||||||
OTU_FW_Update(0, 2, 115200);
|
OTU_FW_Update(0, 2, 115200);
|
||||||
|
|
||||||
|
#else
|
||||||
|
#ifdef RTL8710AF
|
||||||
|
#error "OTU_FW_Update work only SDRAM buffer!"
|
||||||
|
#endif
|
||||||
|
// use xmodem to update, RX: PC_0, TX: PC_3, baudrate: 1M
|
||||||
|
OTU_FW_Update(0, 0, 115200);
|
||||||
|
// use xmodem to update, RX: PE_3, TX: PE_0, baudrate: 1M
|
||||||
|
// JTAG Off!
|
||||||
|
// OTU_FW_Update(0, 1, 115200);
|
||||||
|
#endif
|
||||||
at_printf("\r\n[ATSX] OK");
|
at_printf("\r\n[ATSX] OK");
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -15,6 +15,7 @@
|
||||||
#include "hal_spi_flash.h"
|
#include "hal_spi_flash.h"
|
||||||
#include "rtl8195a_spi_flash.h"
|
#include "rtl8195a_spi_flash.h"
|
||||||
#include <platform/platform_stdlib.h>
|
#include <platform/platform_stdlib.h>
|
||||||
|
#include <platform_opts.h>
|
||||||
|
|
||||||
#if CONFIG_UART_SOCKET
|
#if CONFIG_UART_SOCKET
|
||||||
#if /*CONFIG_PERI_UPDATE_IMG*/1
|
#if /*CONFIG_PERI_UPDATE_IMG*/1
|
||||||
|
|
|
@ -87,7 +87,7 @@ void flash_init(flash_t *obj) {
|
||||||
flashobj.SpicInitPara.Mode.CpuClk = curclk;
|
flashobj.SpicInitPara.Mode.CpuClk = curclk;
|
||||||
flashobj.SpicInitPara.Mode.BitMode = flmode;
|
flashobj.SpicInitPara.Mode.BitMode = flmode;
|
||||||
|
|
||||||
#if CONFIG_DEBUG_LOG > 4
|
#if CONFIG_DEBUG_LOG > 3
|
||||||
DBG_SPIF_INFO("Flash ID: %02x%02x%02x\n", flashobj.SpicInitPara.id[0], flashobj.SpicInitPara.id[1], flashobj.SpicInitPara.id[2]);
|
DBG_SPIF_INFO("Flash ID: %02x%02x%02x\n", flashobj.SpicInitPara.id[0], flashobj.SpicInitPara.id[1], flashobj.SpicInitPara.id[2]);
|
||||||
DBG_SPIF_INFO("Flash Mode: 0x%02x; BaudRate:%d; RdDummyCyle:%d; DelayLine:%d\n",
|
DBG_SPIF_INFO("Flash Mode: 0x%02x; BaudRate:%d; RdDummyCyle:%d; DelayLine:%d\n",
|
||||||
flashobj.SpicInitPara.Mode.BitMode, flashobj.SpicInitPara.BaudRate, flashobj.SpicInitPara.RdDummyCyle, flashobj.SpicInitPara.DelayLine);
|
flashobj.SpicInitPara.Mode.BitMode, flashobj.SpicInitPara.BaudRate, flashobj.SpicInitPara.RdDummyCyle, flashobj.SpicInitPara.DelayLine);
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
@echo off
|
@echo off
|
||||||
|
call paths.bat
|
||||||
cd flasher
|
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"
|
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
|
echo flash read fullflash.bin
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
@echo off
|
||||||
|
call paths.bat
|
||||||
@cd flasher
|
@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"
|
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
|
rem
|
||||||
|
|
Loading…
Reference in a new issue