Uh oh!
There was an error while loading. Please reload this page.
Added support for segment addresing in output hex files - #5
Conversation
bialix
commented
Apr 20, 2016
I'd like to have some simple test for your changes. If you don't intend to write one, I will do it later, before merging. |
mmajchrzycki
commented
Apr 21, 2016
I've added a unit test for writing segmented hex file. It takes a data64k dictionary and write it in the 'shex' format. Then the result is compared with a predefined 'shex64k' hex file. |
bialix
commented
Apr 21, 2016
Mateusz, do you have access to original files intended to be used by your application? I'm interested to know whether such files have start address record. I have suspicious it has CS/IP pair, so segmented addresses make perfect sense in such context. I think IntelHex library can make automatic decision about using one or another address scheme based on presence of start addr field. What do you think? |
mmajchrzycki
commented
Apr 21, 2016
Unfortunately, I couldn't share that file with you. It is a proprietary firmware. However, it doesn't have any records other than 00, 01 and 02. It looks like it was made by the converter which didn't support linear addressing. I also looked at the Intel Hex standard and it seems that the Start Segment record is not required. |
bialix
commented
Apr 21, 2016
I don't really need your file, I just need to know about start address. Thank you for information. Start record is not written if it's not here, you can see it in code. I personally don't really like your "shex" name, because technically they're both HEX files, and two different address schemes are both defined by the same format. I'm going to think about the proper way to support your use case, but most likely I will change "shex" to something different. |
mmajchrzycki
commented
Apr 22, 2016
I understand you as I didn't have any better solution for this fix. The name 'shex' is very ugly :) Maybe it is worth to consider the solution with automatic using of segment address when CS:IP is present? The other solution I've found on Wikipedia. Maybe all output formats should get their names from this convention. What do you think? |
Quote from Wikipedia
I guess we can employ this naming scheme in IntelHex library. I've never heard about this naming sceme before, but it makes sense for me. Thank you for pointing at this page. |
bialix
commented
Apr 22, 2016
So, my plan would be like this:
|
bialix
commented
Sep 27, 2019
Sorry for not working on your pull request. I'm looking for a new maintainer for Python IntelHex project. I hope someone will help. |
bialix
commented
Jul 9, 2020
Your patch is partially superseded by #41 |
I recently met a problem with application which requires Intel HEX files but with segment addressing instead of linear. So I added another (shex - segment hex) output format for hex files.