TMDSEVM6657LS评估板恢复出厂默认状态
前言
TMDSEVM6657LS评估板特别适用于DSP开发的初学者,但有时候拿到手的开发板几经流转,被别人修改过,也可能自己烧录过程出错,导致开发板的状态未知等原因,需要恢复到出厂默认状态,本文主要介绍如何利用官方提供的工具将开发板恢复到出厂默认状态。
在开始前,需要安装CCS工具,默认安装完成后,会在安装目录生成两个文件夹:C:\ti\ccsv5\ccs_base\scripting\bin和C:\ti\mcsdk_2_01_01_04\tools\program_evm(不同版本的CCS可能导致mcsdk的版本号不同,以自己安装的目录为准)。如果没有program_evm文件夹,可以使用购买时厂家提供的光盘里的program_evm文件夹里程序。
操作步骤
- 安装CCS
我这里安装的是CCS5.5(步骤略)。
安装完CCS后,生成的两个文件夹:
- 硬件准备
(1)将12v DC电源适配器于评估板的电源接口相连;
(2)将评估板上自带的XDS200仿真器通过USB连接线与电脑相连(确保J4 J5 均处于开路状态);
(3)将评估板上COM_SEL1跳线中的3-5针相连,4-6针相连,选择使用三针串口,并用评估板自带的串口连接线连接至电脑的串口。(如果选择使用板上的USB-uart,需要将COM_SEL1跳线中的1-3针相连,2-4针相连)
(4)将16个BOOT拨码开关调整到如下状态:
最终实物图如下所示:
- 恢复出厂默认配置步骤
恢复出厂默认配置主要是将重新烧录评估板中EEPROM、NOR FLASH和NAND FLASH中的镜像。
(1)设置环境变量
评估板上电后,打开cmd命令窗口,设置两个环境变量:
set DSS_SCRIPT_DIR="C:\ti\ccsv5\ccs_base\scripting\bin"
set PROGRAM_EVM_TARGET_CONFIG_FILE=C:\ti\mcsdk_2_01_01_04\tools\program_evm\configs\evm6657l\evm6657ls.ccxml
(2)运行DSS脚本
%DSS_SCRIPT_DIR%\dss.bat program_evm.js tmdsevm6657ls-le
运行后输出以下信息:
由于"program_evm\binaries\evm6657l"文件夹中没有nand.bin镜像文件,所以会提示nand Flash烧录失败,eeprom和NOR都烧录成功了。
C:\ti\mcsdk_2_01_01_04\tools\program_evm>%DSS_SCRIPT_DIR%\dss.bat program_evm.js
Syntax error in command line
Syntax: program_evm.js [tmdx|tmds]evm[c](<device>)l[x][e][-le|-be] [images_to_write]
tmdx: TMDX type EVM
tmds: TMDS type EVM
c: Not used, for backward compatibility
<device> is the board name e.g 6472,6678 etc
l: Low cost EVM
x: EVM supports encryption
e: EVM uses 560 Mezzanine Emulator daughter card
le: Little Endian
be: Big Endian
example: TMDXEVM6678L-le
[images_to_write] OPTIONAL is a list of the images to be written
example: eeprom50,nor
If not specified all (eeprom50,eeprom51,nand,nor) will be written
C:\ti\mcsdk_2_01_01_04\tools\program_evm>%DSS_SCRIPT_DIR%\dss.bat program_evm.js tmdsevm6657ls-le
board: evm6657l
endian: Little
emulation: XDS200 emulator
binaries: C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/
ccxml: C:\ti\mcsdk_2_01_01_04\tools\program_evm\configs\evm6657l\evm6657ls.ccxml
C66xx_0: GEL Output:
Connecting Target...
C66xx_0: GEL Output: DSP core #0
C66xx_0: GEL Output: C6657L GEL file Ver is 1.003
C66xx_0: GEL Output: Global Default Setup...
C66xx_0: GEL Output: Setup Cache...
C66xx_0: GEL Output: L1P = 32K
C66xx_0: GEL Output: L1D = 32K
C66xx_0: GEL Output: L2 = ALL SRAM
C66xx_0: GEL Output: Setup Cache... Done.
C66xx_0: GEL Output: Main PLL (PLL1) Setup ...
C66xx_0: GEL Output: PLL in Bypass ...
C66xx_0: GEL Output: PLL1 Setup for DSP @ 1000.0 MHz.
C66xx_0: GEL Output: SYSCLK2 = 333.3333 MHz, SYSCLK5 = 200.0 MHz.
C66xx_0: GEL Output: SYSCLK8 = 15.625 MHz.
C66xx_0: GEL Output: PLL1 Setup... Done.
C66xx_0: GEL Output: Power on all PSC modules and DSP domains...
C66xx_0: GEL Output: Set_PSC_State... Timeout Error #03 pd=12, md=4!
C66xx_0: GEL Output: Power on all PSC modules and DSP domains... Done.
C66xx_0: GEL Output: DDR3 PLL (PLL2) Setup ...
C66xx_0: GEL Output: DDR3 PLL Setup... Done.
C66xx_0: GEL Output: DDR3 Init begin (1333 auto)
C66xx_0: GEL Output: XMC Setup ... Done
C66xx_0: GEL Output:
DDR3 initialization is complete.
C66xx_0: GEL Output: DDR3 Init done
C66xx_0: GEL Output: DDR3 memory test... Started
C66xx_0: GEL Output: DDR3 memory test... Passed
C66xx_0: GEL Output: PLL and DDR3 Initialization completed(0) ...
C66xx_0: GEL Output: configSGMIISerdes Setup... Begin
C66xx_0: GEL Output: SGMII SERDES has been configured.
C66xx_0: GEL Output: Enabling EDC ...
C66xx_0: GEL Output: L1P error detection logic is enabled.
C66xx_0: GEL Output: L2 error detection/correction logic is enabled.
C66xx_0: GEL Output: MSMC error detection/correction logic is enabled.
C66xx_0: GEL Output: Enabling EDC ...Done
C66xx_0: GEL Output: Global Default Setup... Done.
Start writing eeprom50
Writer:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/eepromwriter_evm6657l.out
Image:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/eeprom50.bin
C66xx_0: GEL Output: Invalidate All Cache...
C66xx_0: GEL Output: Invalidate All Cache... Done.
C66xx_0: GEL Output: GEL Reset...
C66xx_0: GEL Output: GEL Reset... Done.
C66xx_0: GEL Output: Disable all EDMA3 interrupts and events.
EEPROM Writer Utility Version 01.00.00.05
Writing 59356 bytes from DSP memory address 0x0c000000 to EEPROM bus address 0x0050 starting from device address 0x0000 ...
Reading 59356 bytes from EEPROM bus address 0x0050 to DSP memory address 0x0c010000 starting from device address 0x0000 ...
Verifying data read ...
EEPROM programming completed successfully
Start writing eeprom51
Writer:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/eepromwriter_evm6657l.out
Image:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/eeprom51.bin
C66xx_0: GEL Output: Invalidate All Cache...
C66xx_0: GEL Output: Invalidate All Cache... Done.
C66xx_0: GEL Output: GEL Reset...
C66xx_0: GEL Output: GEL Reset... Done.
C66xx_0: GEL Output: Disable all EDMA3 interrupts and events.
EEPROM Writer Utility Version 01.00.00.05
Writing 47848 bytes from DSP memory address 0x0c000000 to EEPROM bus address 0x0051 starting from device address 0x0000 ...
Reading 47848 bytes from EEPROM bus address 0x0051 to DSP memory address 0x0c010000 starting from device address 0x0000 ...
Verifying data read ...
EEPROM programming completed successfully
Writer:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/nandwriter_evm6657l.out
NAND:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/nand.bin
Required NAND files does not exist in C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/
Writer:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/norwriter_evm6657l.out
NOR:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/nor.bin
C66xx_0: GEL Output: Invalidate All Cache...
C66xx_0: GEL Output: Invalidate All Cache... Done.
C66xx_0: GEL Output: GEL Reset...
C66xx_0: GEL Output: GEL Reset... Done.
C66xx_0: GEL Output: Disable all EDMA3 interrupts and events.
Start loading nor.bin
Start programming NOR
2023_02_8_151707
NOR Writer Utility Version 01.00.00.03
Flashing sector 0 (0 bytes of 663723)
Flashing sector 1 (65536 bytes of 663723)
Flashing sector 2 (131072 bytes of 663723)
Flashing sector 3 (196608 bytes of 663723)
Flashing sector 4 (262144 bytes of 663723)
Flashing sector 5 (327680 bytes of 663723)
Flashing sector 6 (393216 bytes of 663723)
Flashing sector 7 (458752 bytes of 663723)
Flashing sector 8 (524288 bytes of 663723)
Flashing sector 9 (589824 bytes of 663723)
Flashing sector 10 (655360 bytes of 663723)
Reading and verifying sector 0 (0 bytes of 663723)
Reading and verifying sector 1 (65536 bytes of 663723)
Reading and verifying sector 2 (131072 bytes of 663723)
Reading and verifying sector 3 (196608 bytes of 663723)
Reading and verifying sector 4 (262144 bytes of 663723)
Reading and verifying sector 5 (327680 bytes of 663723)
Reading and verifying sector 6 (393216 bytes of 663723)
Reading and verifying sector 7 (458752 bytes of 663723)
Reading and verifying sector 8 (524288 bytes of 663723)
Reading and verifying sector 9 (589824 bytes of 663723)
Reading and verifying sector 10 (655360 bytes of 663723)
NOR programming completed successfully
End programming NOR
终止批处理操作吗(Y/N)? y
C:\ti\mcsdk_2_01_01_04\tools\program_evm>set DSS_SCRIPT_DIR="C:\ti\ccsv5\ccs_base\scripting\bin"
C:\ti\mcsdk_2_01_01_04\tools\program_evm>set PROGRAM_EVM_TARGET_CONFIG_FILE=C:\ti\mcsdk_2_01_01_04\tools\program_evm\configs\evm6657l\evm6657ls.ccxml
C:\ti\mcsdk_2_01_01_04\tools\program_evm>%DSS_SCRIPT_DIR%\dss.bat program_evm.js tmdsevm6657ls-le
board: evm6657l
endian: Little
emulation: XDS200 emulator
binaries: C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/
ccxml: C:\ti\mcsdk_2_01_01_04\tools\program_evm\configs\evm6657l\evm6657ls.ccxml
C66xx_0: GEL Output:
Connecting Target...
C66xx_0: GEL Output: DSP core #0
C66xx_0: GEL Output: C6657L GEL file Ver is 1.003
C66xx_0: GEL Output: Global Default Setup...
C66xx_0: GEL Output: Setup Cache...
C66xx_0: GEL Output: L1P = 32K
C66xx_0: GEL Output: L1D = 32K
C66xx_0: GEL Output: L2 = ALL SRAM
C66xx_0: GEL Output: Setup Cache... Done.
C66xx_0: GEL Output: Main PLL (PLL1) Setup ...
C66xx_0: GEL Output: PLL not in Bypass, Enable BYPASS in the PLL Controller...
C66xx_0: GEL Output: PLL1 Setup for DSP @ 1000.0 MHz.
C66xx_0: GEL Output: SYSCLK2 = 333.3333 MHz, SYSCLK5 = 200.0 MHz.
C66xx_0: GEL Output: SYSCLK8 = 15.625 MHz.
C66xx_0: GEL Output: PLL1 Setup... Done.
C66xx_0: GEL Output: Power on all PSC modules and DSP domains...
C66xx_0: GEL Output: Power on all PSC modules and DSP domains... Done.
C66xx_0: GEL Output: DDR3 PLL (PLL2) Setup ...
C66xx_0: GEL Output: DDR3 PLL Setup... Done.
C66xx_0: GEL Output: DDR3 Init begin (1333 auto)
C66xx_0: GEL Output: XMC Setup ... Done
C66xx_0: GEL Output:
DDR3 initialization is complete.
C66xx_0: GEL Output: DDR3 Init done
C66xx_0: GEL Output: DDR3 memory test... Started
C66xx_0: GEL Output: DDR3 memory test... Passed
C66xx_0: GEL Output: PLL and DDR3 Initialization completed(0) ...
C66xx_0: GEL Output: configSGMIISerdes Setup... Begin
C66xx_0: GEL Output: SGMII SERDES has been configured.
C66xx_0: GEL Output: Enabling EDC ...
C66xx_0: GEL Output: L1P error detection logic is enabled.
C66xx_0: GEL Output: L2 error detection/correction logic is enabled.
C66xx_0: GEL Output: MSMC error detection/correction logic is enabled.
C66xx_0: GEL Output: Enabling EDC ...Done
C66xx_0: GEL Output: Global Default Setup... Done.
Start writing eeprom50
Writer:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/eepromwriter_evm6657l.out
Image:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/eeprom50.bin
C66xx_0: GEL Output: Invalidate All Cache...
C66xx_0: GEL Output: Invalidate All Cache... Done.
C66xx_0: GEL Output: GEL Reset...
C66xx_0: GEL Output: GEL Reset... Done.
C66xx_0: GEL Output: Disable all EDMA3 interrupts and events.
EEPROM Writer Utility Version 01.00.00.05
Writing 59356 bytes from DSP memory address 0x0c000000 to EEPROM bus address 0x0050 starting from device address 0x0000 ...
Reading 59356 bytes from EEPROM bus address 0x0050 to DSP memory address 0x0c010000 starting from device address 0x0000 ...
Verifying data read ...
EEPROM programming completed successfully
Start writing eeprom51
Writer:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/eepromwriter_evm6657l.out
Image:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/eeprom51.bin
C66xx_0: GEL Output: Invalidate All Cache...
C66xx_0: GEL Output: Invalidate All Cache... Done.
C66xx_0: GEL Output: GEL Reset...
C66xx_0: GEL Output: GEL Reset... Done.
C66xx_0: GEL Output: Disable all EDMA3 interrupts and events.
EEPROM Writer Utility Version 01.00.00.05
Writing 47848 bytes from DSP memory address 0x0c000000 to EEPROM bus address 0x0051 starting from device address 0x0000 ...
Reading 47848 bytes from EEPROM bus address 0x0051 to DSP memory address 0x0c010000 starting from device address 0x0000 ...
Verifying data read ...
EEPROM programming completed successfully
Writer:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/nandwriter_evm6657l.out
NAND:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/nand.bin
Required NAND files does not exist in C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/
Writer:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/norwriter_evm6657l.out
NOR:C:\ti\mcsdk_2_01_01_04\tools\program_evm/binaries/evm6657l/nor.bin
C66xx_0: GEL Output: Invalidate All Cache...
C66xx_0: GEL Output: Invalidate All Cache... Done.
C66xx_0: GEL Output: GEL Reset...
C66xx_0: GEL Output: GEL Reset... Done.
C66xx_0: GEL Output: Disable all EDMA3 interrupts and events.
Start loading nor.bin
Start programming NOR
2023_02_8_164346
NOR Writer Utility Version 01.00.00.03
Flashing sector 0 (0 bytes of 663723)
Flashing sector 1 (65536 bytes of 663723)
Flashing sector 2 (131072 bytes of 663723)
Flashing sector 3 (196608 bytes of 663723)
Flashing sector 4 (262144 bytes of 663723)
Flashing sector 5 (327680 bytes of 663723)
Flashing sector 6 (393216 bytes of 663723)
Flashing sector 7 (458752 bytes of 663723)
Flashing sector 8 (524288 bytes of 663723)
Flashing sector 9 (589824 bytes of 663723)
Flashing sector 10 (655360 bytes of 663723)
Reading and verifying sector 0 (0 bytes of 663723)
Reading and verifying sector 1 (65536 bytes of 663723)
Reading and verifying sector 2 (131072 bytes of 663723)
Reading and verifying sector 3 (196608 bytes of 663723)
Reading and verifying sector 4 (262144 bytes of 663723)
Reading and verifying sector 5 (327680 bytes of 663723)
Reading and verifying sector 6 (393216 bytes of 663723)
Reading and verifying sector 7 (458752 bytes of 663723)
Reading and verifying sector 8 (524288 bytes of 663723)
Reading and verifying sector 9 (589824 bytes of 663723)
Reading and verifying sector 10 (655360 bytes of 663723)
NOR programming completed successfully
End programming NOR
(3)验证
断电后,将BOOT拨码开关拨到如下状态:
将评估板的串口连接好串口工具,重新上电后,会输出以下信息,证明镜像烧录成功:
TMDXEVM6657L POST Version 01.00.00.06
------------------------------------------
SOC Information
FPGA Version: 0010
Board Serial Number: ti
EFUSE MAC ID is: 00 18 30 0A 01 CF
PLL Reset Type Status Register: 0x00000001
Platform init return code: 0x00000000
Additional Information:
(0x02350014) :0AEB0000
(0x02350624) :000211FF
(0x02350678) :00123400
(0x0235063C) :000801FF
(0x02350640) :000801FF
(0x02350644) :000900DB
(0x02350648) :000A40DB
(0x0235064C) :000B10DB
(0x02350650) :000C00DB
(0x02350654) :000C00DB
(0x02350658) :000C00DB
(0x0235065C) :000D1800
(0x02350660) :000E1800
(0x02350668) :000F1800
(0x02350670) :00101800
(0x02620008) :0B009006
(0x0262000c) :040101A7
(0x02620010) :00000000
(0x02620014) :76780000
(0x02620018) :0B97A02F
(0x02620180) :0602B000
------------------------------------------
Power On Self Test
POST running in progress ...
POST I2C EEPROM read test started!
POST I2C EEPROM read test passed!
POST SPI NOR read test started!
POST SPI NOR read test passed!
POST EMIF16 NAND read test started!
POST EMIF16 NAND read test passed!
POST EMAC loopback test started!
POST EMAC loopback test passed!
POST external memory test started!
POST external memory test passed!
POST done successfully!
POST result: PASS
等显示出“POST result: PASS”后,通过串口助手发送"ti"(小写)即可设置自己的序列号(等待时间间隔久了貌似久不响应了):
Please enter the 10 digit serial number for this board, and then press ENTER key:
12502120
Serial number programmed to EEPROM successfully!
将拨码开关设置为如下状态,将网口与电脑的网口相连,验证NOR FLSH功能:
串口输出如下信息:
IBL version: 1.0.0.15
IBL: Booting from NOR
platform_init Done
Start BIOS 6
HUA version 2.00.00.04
Setting hostname to tidemo-502120
MAC Address: 00-18-30-0A-01-CF
Configuring DHCP client
Service Status: DHCPC : Enabled : : 000
Service Status: THTTP : Enabled : : 000
Service Status: DHCPC : Enabled : Running : 000
完成!