diff options
author | Ivan Pang | 2011-10-21 16:54:20 -0500 |
---|---|---|
committer | Ivan Pang | 2011-10-21 16:54:20 -0500 |
commit | a2ea0152aedf19f939c545d3c692728a8010fea4 (patch) | |
tree | 9fbf164b1988d972bc455871caf8062babdc5b37 | |
parent | abf260d446cec73c782f2dd410deeb717ca3b07d (diff) | |
download | mcsdk-tools-a2ea0152aedf19f939c545d3c692728a8010fea4.tar.gz mcsdk-tools-a2ea0152aedf19f939c545d3c692728a8010fea4.tar.xz mcsdk-tools-a2ea0152aedf19f939c545d3c692728a8010fea4.zip |
POST updates; eepromwriter now supports .bin instead of .dat
-rw-r--r-- | boot_loader/IBL_buildibl | 2 | ||||
-rw-r--r-- | hfile2array/hfile2array.c | 4 | ||||
-rw-r--r-- | post/docs/README.txt | 18 | ||||
-rw-r--r-- | post/evmc6670l/bin/post_romparse.bat | 2 | ||||
-rw-r--r-- | post/evmc6678l/bin/post_romparse.bat | 2 | ||||
-rw-r--r-- | writer/eeprom/docs/README.txt | 21 | ||||
-rw-r--r-- | writer/eeprom/evmc6670l/bin/eepromwriter_input.txt | 2 | ||||
-rw-r--r-- | writer/eeprom/evmc6678l/bin/eepromwriter_input.txt | 2 |
8 files changed, 28 insertions, 25 deletions
diff --git a/boot_loader/IBL_buildibl b/boot_loader/IBL_buildibl index 35fc35d..fb20f36 100644 --- a/boot_loader/IBL_buildibl +++ b/boot_loader/IBL_buildibl | |||
@@ -7,6 +7,7 @@ cp -f ../util/i2cConfig/i2cparam_c66x_le.out ../../../i2cparam_0x51_c6678_le_0x5 | |||
7 | cp -f ../util/i2cConfig/i2cConfig.gel ../../../i2cConfig.gel | 7 | cp -f ../util/i2cConfig/i2cConfig.gel ../../../i2cConfig.gel |
8 | cp -f ../util/btoccs/b2ccs.exe ../../../b2ccs.exe | 8 | cp -f ../util/btoccs/b2ccs.exe ../../../b2ccs.exe |
9 | cp -f ../util/btoccs/b2i2c.exe ../../../b2i2c.exe | 9 | cp -f ../util/btoccs/b2i2c.exe ../../../b2i2c.exe |
10 | cp -f ../util/btoccs/ccs2bin.exe ../../../ccs2bin.exe | ||
10 | cp -f ../util/bconvert/bconvert64x.exe ../../../bconvert64x.exe | 11 | cp -f ../util/bconvert/bconvert64x.exe ../../../bconvert64x.exe |
11 | cp -f ../util/romparse/romparse.exe ../../../romparse.exe | 12 | cp -f ../util/romparse/romparse.exe ../../../romparse.exe |
12 | 13 | ||
@@ -25,6 +26,7 @@ mv -f ../../../i2cparam_0x51_c6670_le_0x500.out bin/i2cparam_0x51_c6670_le_0x500 | |||
25 | mv -f ../../../i2cConfig.gel bin/i2cConfig.gel | 26 | mv -f ../../../i2cConfig.gel bin/i2cConfig.gel |
26 | mv -f ../../../b2ccs.exe ../util/btoccs/b2ccs.exe | 27 | mv -f ../../../b2ccs.exe ../util/btoccs/b2ccs.exe |
27 | mv -f ../../../b2i2c.exe ../util/btoccs/b2i2c.exe | 28 | mv -f ../../../b2i2c.exe ../util/btoccs/b2i2c.exe |
29 | mv -f ../../../ccs2bin.exe ../util/btoccs/ccs2bin.exe | ||
28 | mv -f ../../../bconvert64x.exe ../util/bconvert/bconvert64x.exe | 30 | mv -f ../../../bconvert64x.exe ../util/bconvert/bconvert64x.exe |
29 | mv -f ../../../romparse.exe ../util/romparse/romparse.exe | 31 | mv -f ../../../romparse.exe ../util/romparse/romparse.exe |
30 | 32 | ||
diff --git a/hfile2array/hfile2array.c b/hfile2array/hfile2array.c index 765821f..0414afa 100644 --- a/hfile2array/hfile2array.c +++ b/hfile2array/hfile2array.c | |||
@@ -110,7 +110,7 @@ int main(int argc, char **argv) | |||
110 | { | 110 | { |
111 | if (fputs(line, out) < 0) | 111 | if (fputs(line, out) < 0) |
112 | { | 112 | { |
113 | printf ("fputs %s error\n", fputs); | 113 | printf ("fputs %s error\n", line); |
114 | goto error; | 114 | goto error; |
115 | } | 115 | } |
116 | } | 116 | } |
@@ -123,7 +123,7 @@ int main(int argc, char **argv) | |||
123 | 123 | ||
124 | if (fputs("};\n", out) < 0) | 124 | if (fputs("};\n", out) < 0) |
125 | { | 125 | { |
126 | printf ("fputs %s error\n", fputs); | 126 | printf ("fputs };\\n error\n"); |
127 | goto error; | 127 | goto error; |
128 | } | 128 | } |
129 | 129 | ||
diff --git a/post/docs/README.txt b/post/docs/README.txt index 82092e7..285d59c 100644 --- a/post/docs/README.txt +++ b/post/docs/README.txt | |||
@@ -36,18 +36,16 @@ Steps to run POST in CCSv5: | |||
36 | 36 | ||
37 | Steps to program POST to EEPROM: | 37 | Steps to program POST to EEPROM: |
38 | 38 | ||
39 | 1. Be sure that IBL romparse.exe is pre-built under tools\boot_loader\ibl\src\util\romparse, if IBL is not built, | 39 | 1. Copy tools\post\evmc66xxl\bin\post_i2crom.bin to tools\writer\eeprom\evmc66xxl\bin directory |
40 | refer to tools\boot_loader\ibl\doc\README.txt on how to build IBL for EVMC66xxL. | ||
41 | 40 | ||
42 | 2. Go to the tools\post\evmc66xxl\bin directory in Windows Explorer and open the post_romparse.bat in a text editor, | 41 | 2. Navigate to tools\writer\eeprom\evmc66xxl\bin\ and open eepromwriter_input.txt. Make the following changes: |
43 | change "C6000_CG_DIR", "TARGET", "ENDIAN" and "IBL_ROOT_DIR" parameters accordingly. | 42 | - Set the file_name to post_i2crom.bin |
43 | - Set the bus_addr to 0x50 | ||
44 | - Set start_addr to 0 | ||
45 | - Set swap_data to 0 | ||
46 | Save and close eepromwriter_input.txt | ||
44 | 47 | ||
45 | 3. Double click post_romparse.bat. This will generate a CCS format image file "post_i2crom.dat", which can be programmed | 48 | 3. Refer to tools\writer\eeprom\evmc66xxl\docs\README.txt on how to program the raw binary file to EEPROM |
46 | to I2C EEPROM slave bus address 0x50, below are the steps how to program the EEPROM using the EEPROM writer utility: | ||
47 | |||
48 | * Copy post_i2crom.dat to tools\writer\eeprom\evmc66xxl\bin directory and rename it to "app.dat". | ||
49 | * Change bus_addr to 0x50 and swap_data to "0" in tools\writer\eeprom\evmc66xxl\bin\eepromwriter_input.txt and save the file. | ||
50 | * Refer to tools\writer\eeprom\evmc66xxl\docs\README.txt on how to program the CCS data file to EEPROM. | ||
51 | 49 | ||
52 | 4. Once the programming is completed successfully, user can set the boot mode to I2C mode with bus address 0x50 and | 50 | 4. Once the programming is completed successfully, user can set the boot mode to I2C mode with bus address 0x50 and |
53 | boot the POST directly from the EEPROM after POR. The boot status and test result can be monitored using the Hyper | 51 | boot the POST directly from the EEPROM after POR. The boot status and test result can be monitored using the Hyper |
diff --git a/post/evmc6670l/bin/post_romparse.bat b/post/evmc6670l/bin/post_romparse.bat index cd42df0..92c9251 100644 --- a/post/evmc6670l/bin/post_romparse.bat +++ b/post/evmc6670l/bin/post_romparse.bat | |||
@@ -39,6 +39,6 @@ if %ENDIAN% == little ( | |||
39 | echo Generating I2C ROM data ... | 39 | echo Generating I2C ROM data ... |
40 | %IBL_ROOT_DIR%\src\util\romparse\romparse -rom_base 0x50 post_i2crom.map.pp | 40 | %IBL_ROOT_DIR%\src\util\romparse\romparse -rom_base 0x50 post_i2crom.map.pp |
41 | 41 | ||
42 | mv i2crom.ccs post_i2crom.dat | 42 | %IBL_ROOT_DIR%\src\util\btoccs\ccs2bin -swap i2crom.ccs post_i2crom.bin |
43 | 43 | ||
44 | rm -f *.ccs *.b | 44 | rm -f *.ccs *.b |
diff --git a/post/evmc6678l/bin/post_romparse.bat b/post/evmc6678l/bin/post_romparse.bat index 03d5e58..a8378d4 100644 --- a/post/evmc6678l/bin/post_romparse.bat +++ b/post/evmc6678l/bin/post_romparse.bat | |||
@@ -39,6 +39,6 @@ if %ENDIAN% == little ( | |||
39 | echo Generating I2C ROM data ... | 39 | echo Generating I2C ROM data ... |
40 | %IBL_ROOT_DIR%\src\util\romparse\romparse -rom_base 0x50 post_i2crom.map.pp | 40 | %IBL_ROOT_DIR%\src\util\romparse\romparse -rom_base 0x50 post_i2crom.map.pp |
41 | 41 | ||
42 | mv i2crom.ccs post_i2crom.dat | 42 | %IBL_ROOT_DIR%\src\util\btoccs\ccs2bin -swap i2crom.ccs post_i2crom.bin |
43 | 43 | ||
44 | rm -f *.ccs *.b | 44 | rm -f *.ccs *.b |
diff --git a/writer/eeprom/docs/README.txt b/writer/eeprom/docs/README.txt index 9da0cb9..a456d38 100644 --- a/writer/eeprom/docs/README.txt +++ b/writer/eeprom/docs/README.txt | |||
@@ -2,16 +2,18 @@ EEPROM Writer Utility | |||
2 | 2 | ||
3 | EEPROM Writer is a simple utility to program a CCS format image/data file to I2C EEPROM. | 3 | EEPROM Writer is a simple utility to program a CCS format image/data file to I2C EEPROM. |
4 | 4 | ||
5 | Steps to program the EEPROM: | 5 | Steps to program the EEPROM with a binary file: |
6 | 6 | ||
7 | 1. Be sure to set the boot mode dip switch to no boot/EMIF16 boot mode on the EVM. | 7 | 1. Be sure to set the boot mode dip switch to no boot/EMIF16 boot mode on the EVM. |
8 | 8 | ||
9 | 2. Copy the CCS format data file to writer\eeprom\evmc66xxl\bin directory, and rename it to app.dat. | 9 | 2. Copy the binary file to writer\eeprom\evmc66xxl\bin directory. |
10 | 10 | ||
11 | 3. Change the file_name, bus_addr, start_addr and swap_data in writer\eeprom\evmc66xxl\bin\eepromwriter_input.txt if necessary. | 11 | 3. Change the file_name, bus_addr, start_addr and swap_data in writer\eeprom\evmc66xxl\bin\eepromwriter_input.txt if necessary. |
12 | By default the EEPROM writer will load app.dat to DSP memory and write the data to I2C slave | 12 | Make sure that file_name is set to the name of your binary file. |
13 | |||
14 | *By default the EEPROM writer will load app.bin to DSP memory and write the data to I2C slave | ||
13 | bus address 81 (0x51) at EEPROM device start byte address 0 with data swap disabled (0). | 15 | bus address 81 (0x51) at EEPROM device start byte address 0 with data swap disabled (0). |
14 | 16 | ||
15 | 4. Open CCSv5 and launch the evmc66xx emulator target configuration and connect to core 0. | 17 | 4. Open CCSv5 and launch the evmc66xx emulator target configuration and connect to core 0. |
16 | 18 | ||
17 | 5. Load the program writer\eeprom\evmc66xxl\bin\eepromwriter_evm66xxl.out to CCS, be sure evmc66xxl.gel is used in CCS | 19 | 5. Load the program writer\eeprom\evmc66xxl\bin\eepromwriter_evm66xxl.out to CCS, be sure evmc66xxl.gel is used in CCS |
@@ -21,10 +23,12 @@ Steps to program the EEPROM: | |||
21 | 23 | ||
22 | 7. Load app.dat to 0x80000000: | 24 | 7. Load app.dat to 0x80000000: |
23 | * In CCSv5, right click mouse in memory window, select "load memory". | 25 | * In CCSv5, right click mouse in memory window, select "load memory". |
24 | * Browse and select writer\eeprom\evmc66xxl\bin\app.dat. | 26 | * Browse and select your binary file. |
25 | * Select the option "Use the file header information to set the start address and size of the memory block to be | 27 | - By default, the browse menu only displays .dat files. You will have to change the option |
26 | loaded" and click "next". | 28 | TI Data Format (*.dat) to Raw Data Format (*.bin) to find your binary file. |
27 | * Change the Start Address to "0x80000000" if it is not 0x80000000, and click "finish". | 29 | * Change the Start Address to "0x80000000" if it is not 0x80000000 |
30 | * Change the Type-size to 32 bits if it is not 32 bits. | ||
31 | * click "finish". | ||
28 | 32 | ||
29 | 8.After the data file is loaded into the memory, run the program (in CCSv5, press F8), it will start to program the | 33 | 8.After the data file is loaded into the memory, run the program (in CCSv5, press F8), it will start to program the |
30 | EEPROM. | 34 | EEPROM. |
@@ -32,7 +36,6 @@ Steps to program the EEPROM: | |||
32 | 9.When programming is completed, the console will print "EEPROM programming completed successfully", if there | 36 | 9.When programming is completed, the console will print "EEPROM programming completed successfully", if there |
33 | is any error, the console will show the error message. | 37 | is any error, the console will show the error message. |
34 | 38 | ||
35 | |||
36 | Steps to re-build eepromwriter: | 39 | Steps to re-build eepromwriter: |
37 | 40 | ||
38 | 1. Uses CCS to build eepromwriter: | 41 | 1. Uses CCS to build eepromwriter: |
diff --git a/writer/eeprom/evmc6670l/bin/eepromwriter_input.txt b/writer/eeprom/evmc6670l/bin/eepromwriter_input.txt index 76b3dd9..d87d3c4 100644 --- a/writer/eeprom/evmc6670l/bin/eepromwriter_input.txt +++ b/writer/eeprom/evmc6670l/bin/eepromwriter_input.txt | |||
@@ -1,4 +1,4 @@ | |||
1 | file_name = app.dat | 1 | file_name = app.bin |
2 | bus_addr = 0x51 | 2 | bus_addr = 0x51 |
3 | start_addr = 0 | 3 | start_addr = 0 |
4 | swap_data = 0 | 4 | swap_data = 0 |
diff --git a/writer/eeprom/evmc6678l/bin/eepromwriter_input.txt b/writer/eeprom/evmc6678l/bin/eepromwriter_input.txt index 76b3dd9..d87d3c4 100644 --- a/writer/eeprom/evmc6678l/bin/eepromwriter_input.txt +++ b/writer/eeprom/evmc6678l/bin/eepromwriter_input.txt | |||
@@ -1,4 +1,4 @@ | |||
1 | file_name = app.dat | 1 | file_name = app.bin |
2 | bus_addr = 0x51 | 2 | bus_addr = 0x51 |
3 | start_addr = 0 | 3 | start_addr = 0 |
4 | swap_data = 0 | 4 | swap_data = 0 |