Building to hex etc. file and flashing from that file without rebuilding Topic is solved

Technical questions regarding the xTIMEcomposer, xSOFTip Explorer and Programming with XMOS.
User avatar
aclassifier
Respected Member
Posts: 319
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Building to hex etc. file and flashing from that file without rebuilding

Postby aclassifier » Wed Jul 05, 2017 9:23 am

This probably has been shown before..

I have a startKIT I would like to reflash with different versions of the code without rebuilding.

I found the XFlash Options to output to file but I didn't get it to work...

What's the procedure for this and where do I find it described?
View Solution
colin
Experienced Member
Posts: 74
Joined: Mon Dec 16, 2013 12:14 pm

Postby colin » Wed Jul 05, 2017 9:58 am

Hi aclassifier

You can use xflash option -o to output your flash image to file, i.e: xflash my_prog.xe -o my_flash_prog.bin

You can then use xflash option --write-all to write your binary file to flash memory, i.e.: xflash --write-all my_flash_prog.bin --target=XCORE-200-EXPLORER

Best Wishes,
Colin
User avatar
aclassifier
Respected Member
Posts: 319
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Postby aclassifier » Wed Jul 05, 2017 2:29 pm

Thanks! I did

Flash As | Flash Configurations and made a new config (based on the default) called "MyProject to-file". I then edited in XFlash Options with Other XFlash options: -o _Aquarium_1_x.bin as the other params should have been picked up. This generated _Aquarium_1_x.bin ok

Another new config called "MyProject from-file". Same as above but with the last set to --write-all _Aquarium_1_x.bin with or without --target=STARTKIT. Any way I got "Error: F03073 Mutually incompatible options specified."

I did find these params in "xTIMEcomposer User Guide, chapter 32XFLASH Command-Line Manual", but I didn't find out which params that clashed. I tried some of the params in the Main tab but no
colin
Experienced Member
Posts: 74
Joined: Mon Dec 16, 2013 12:14 pm

Postby colin » Wed Jul 05, 2017 2:40 pm

Same as above but with the last set to --write-all _Aquarium_1_x.bin



When you say same as above, do you have --write-all and -o in the same xflash command set? If so then this is what would give you the mutually exclusive options error. You cannot output a file and write a file to flash memory at the same time. You must give target or target-file when using write-all as xflash cannot resolve the XN file from the *.bin file.

Colin.
User avatar
aclassifier
Respected Member
Posts: 319
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Postby aclassifier » Wed Jul 05, 2017 3:57 pm

No, I didn't:-( The -o was in to-file config and the --write-all _Aquarium_1_x.bin with or without --target=STARTKIT was in from-file config
User avatar
aclassifier
Respected Member
Posts: 319
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Postby aclassifier » Thu Jul 06, 2017 7:01 pm

I have tried "everything" but since I am not able to see the offending action when "Error: F03073 Mutually incompatible options specified" then I am completely stuck.

I have attached a jpg with the three configs (three rows) and the two tabs for each (columns).

The top config is default build and flash. The middle builds the bin file fine. It is the bottom config that causes the error.

Image
colin
Experienced Member
Posts: 74
Joined: Mon Dec 16, 2013 12:14 pm

Postby colin » Fri Jul 07, 2017 8:50 am

Hi aclassifier,

I've done a little digging and it seems that you cannot use the GUI to perform --write-all, --read-all or --erase-all functions with xflash. The GUI xflash configuration automatically adds the xcore binary (*.xe) to the xflash command line. In doing so it forces you to either program the binary to flash or output the binary to a binary file (as in your first case). In your second case, adding --write-all to the command line options appends this with the automatically added xcore binary (*.xe) and so gives the mutually exclusive error. Therefore you are going to have to perform the --write-all option using the command line rather than through the GUI.

I will raise this as an issue internally for future releases.

Best Wishes
Colin.
User avatar
aclassifier
Respected Member
Posts: 319
Joined: Wed Apr 25, 2012 8:52 pm
Contact:

Postby aclassifier » Fri Jul 07, 2017 8:58 am

Thanks! I had a feeling there was something inherent. I certainly agree that it should have been great to do it with the GUI.

Who is online

Users browsing this forum: bear118 and 162 guests