- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You can download the python script below and gicve your spt file as input.
https://ftp.dlitz.net/pub/dlitz/cyusb-fw-extract/0.1/cyusb-fw-extract.py
Though, I don't know why, the script puts one byte too many on each line.
So just delete that extra byte on every line, and you're good to go.
If you get 2 files as output, you have to merge them after having corrected them (remove last byte on each line)
EDIT:
I have figured out why the .py script that I posted above puts one byte too many on each line. It's the Checksum !
See: https://en.wikipedia.org/wiki/Intel_HEX
So, you just have to merge the two files together, but don't delete the checksum !. The reason why there are two files is because in the spt files, between the loading of the first file and second file, it puts the chip out of reset, and back to reset to load the second part. I have no idea why it does that, but I've managed to make it wok by just putting the two files one after the other in a new file (of course, you have to remove the end-of-file line on the first file).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The SPT file is just a recording of all that you do in Control Center. So, if it downloads firmware, it will have a bunch of vendor commands that load specific data to the device.
The file format is not documented though. You can therefore take a look at our Control Center's source code (follow the code bound with the bRecording flag) to understand how data is stored in the file. From this, the data needs to be extracted and then converted to a hex file.
It is likely much easier if you can get the source code and compile it to a hex file.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Can we use Usblyzer program in order to see those vendor commands and specific datas while installing driver on windows?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, you can. You still have to decode the commands though.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Aren't they the exact hex codes? Why is it still required to decode them?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
They are. What I meant by decoding was to extract the destination address from the transfers and construct a hex file based on that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
There are many coloumns in that program, raw data is what we are looking for, am I right ? Do you know usbylzer program?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You can download the python script below and gicve your spt file as input.
https://ftp.dlitz.net/pub/dlitz/cyusb-fw-extract/0.1/cyusb-fw-extract.py
Though, I don't know why, the script puts one byte too many on each line.
So just delete that extra byte on every line, and you're good to go.
If you get 2 files as output, you have to merge them after having corrected them (remove last byte on each line)
EDIT:
I have figured out why the .py script that I posted above puts one byte too many on each line. It's the Checksum !
See: https://en.wikipedia.org/wiki/Intel_HEX
So, you just have to merge the two files together, but don't delete the checksum !. The reason why there are two files is because in the spt files, between the loading of the first file and second file, it puts the chip out of reset, and back to reset to load the second part. I have no idea why it does that, but I've managed to make it wok by just putting the two files one after the other in a new file (of course, you have to remove the end-of-file line on the first file).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
We have two .ihx files. When we merge them without deleting last byte and put it onto edsim 8051 simulator program, it verifies every line. Name the lines as jump, move, etc. However, when we delete last byte of everyline, it doesnt recognize lines as jump, move etc.