Extending Motorola S-record syntax with S6

Wishlists for new functionality and features.
Post Reply
gerhardf
Posts: 5
Joined: 20 Apr 2022 12:35

Extending Motorola S-record syntax with S6

Post by gerhardf »

Hello,
when importing a s-record file which contains a s-record type S6 I get an error message (see attachment).

Any chance to get rid of this message (except by deleting the line :) )?

Many thanks in advance!
Gerhard
Attachments
error_s6.jpg
error_s6.jpg (9.33 KiB) Viewed 12670 times
Maël
Site Admin
Posts: 1454
Joined: 12 Mar 2005 14:15

Re: Importing Motorola S-record with S6

Post by Maël »

Thanks for the report. I moved this to feature requests, as S6 isn't part of the official standard, and I haven't found any updated standard describing it, aside from a mention in the English Wikipedia article: https://en.wikipedia.org/wiki/SREC_(file_format)

Syntax checking according to the official doc is not a bug. But if nothing gets broken by it, I might consider adding it. Do you have any official docs regarding that syntax extension?

A test file would also be helpful.

Edit: this record appears to be an extended version of S5 and is optional. Deleting it manually should have no effect, except maybe missing to catch inconsistencies in the file.

Edit 2: semi-official documentation can be found here: http://srecord.sourceforge.net/man/man5 ... orola.html
gerhardf
Posts: 5
Joined: 20 Apr 2022 12:35

Re: Extending Motorola S-record syntax with S6

Post by gerhardf »

Hello Maël,
many thanks for the quick response.

You can "produce" a s6 record type very easily with the help of the "srec_cat" tool (see http://srecord.sourceforge.net).
In case of adding a CRC to an existing srecord file the tool adds this S6 record type (even though it's nearly useless).

regard
Gerhard
Maël
Site Admin
Posts: 1454
Joined: 12 Mar 2005 14:15

Re: Extending Motorola S-record syntax with S6

Post by Maël »

Is that how you created your file?

I can produce random files, the point is to have one to test it against, where I know it matches your issue. You could modify yours so it contains no important data.
gerhardf
Posts: 5
Joined: 20 Apr 2022 12:35

Re: Extending Motorola S-record syntax with S6

Post by gerhardf »

Hello,
I attached a test file.

regarding your question:
Is that how you created your file?
Yes, srec_cat was used to fill some area and add a CRC.

Many thanks in advacnce!

Gerhard
Attachments
test_s6.zip
(293 Bytes) Downloaded 334 times
Maël
Site Admin
Posts: 1454
Joined: 12 Mar 2005 14:15

Re: Extending Motorola S-record syntax with S6

Post by Maël »

Thanks for the file. Seems to detect the incomplete file correctly now in the changed code (the count in the S6 record and the amount of records in the file don't match).

Do you also have a valid example file, to test if this works as well?
Maël
Site Admin
Posts: 1454
Joined: 12 Mar 2005 14:15

Re: Extending Motorola S-record syntax with S6

Post by Maël »

I made some test files with srec_cat and HxD handles it as expected.

I'll just assume it will work for you as well. Let me know if you want to have the dev version to test it out.

If it does not work (with the German dev version I'll send upon request), please provide the srec_cat command line with which you created the srec file, and the file size of the original file, so I can produce a similar srec file.
gerhardf
Posts: 5
Joined: 20 Apr 2022 12:35

Re: Extending Motorola S-record syntax with S6

Post by gerhardf »

Hello,
once again many thanks for your efforts.

As I'm pretty sure that your implmentation is working I don't see any need for preliminary testing.

Any plans for releasing a new version of HxD?

regards
Gerhard
Maël
Site Admin
Posts: 1454
Joined: 12 Mar 2005 14:15

Re: Extending Motorola S-record syntax with S6

Post by Maël »

A new version wont come soon, so you can have the dev version or wait.
gerhardf
Posts: 5
Joined: 20 Apr 2022 12:35

Re: Extending Motorola S-record syntax with S6

Post by gerhardf »

I can wait!
Post Reply