Announcements

Help us improve the Power & Sensing Selection Guide. Share feedback

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
YoIs_1298666
Level 5
Level 5
250 sign-ins 100 replies posted 100 sign-ins

Hello,

I compared hex files between "Programmed hex" and "Read to hex" with PSoC Programmer.

There was a difference between the two(518th line). Of course, the checksum of the hex files are the same(514th line).

Please see the below.

Why?

pastedImage_2.png

Best regards,

Yocchi

0 Likes
1 Solution

The line 518 is the metadata, which contains Silicon ID and other parameters.

Please refer to the CY8C4xxx, CYBLxxxx Programming Specifications, Section 2.3 Organization of the Hex File.

If the metadata is different, it would be difference of Silicon ID mainly.

When HEX file is generated by PSoC Creator, PSoC Creator puts ** revision in HEX file.

While, PSoC programmer reads the actual Silicon ID.

regards,

takashi

View solution in original post

7 Replies
MotooTanaka
Level 9
Level 9
Distributor - Marubun (Japan)
First comment on blog Beta tester First comment on KBA

Hi,

I think that the ".hex" file is in Intel Hex Format.

http://www.interlog.com/~speff/usefulinfo/Hexfrmt.pdf

And the line you specified is type of "data",

so the content(s) seems to be at the mercy of PSoC Creator.

I ran following test with my sample program.

(1) Program the project then read it using PSoC Programmer (test1.hex)

(2) Without re-compiling the project programmed and read it (test2.hex)

(3) Cleaned and rebuilt the project and programmed and read it (test3.hex)

Then I compared there three using cygwin

cmp_test.JPG

So, test1.hex and test2.hex were same, but test2,hex and test3.hex were different

even though they were from exactly same program/project.

The tail part of hexes are

test1.hex

test1_tail.JPG

test2.hex

test2_tail.JPG

test3.hex

test3_tail.JPG

So my observation is that PSoC Programmer keeps track of hex

by building history or something.

So I think that the hex will be same as far as no "re-compile" takes place.

In other words, I think that your PSoC was programmed with

different version of the same program/project between two files.

moto

0 Likes

Hello moto,

Unfortunately, the hex files are same version.

The original hex file that is programmed by PSoC Programmer is different from the read one that is read by PSoC Programmer.

Best regards,

Yocchi

0 Likes
MotooTanaka
Level 9
Level 9
Distributor - Marubun (Japan)
First comment on blog Beta tester First comment on KBA

Dear Yocchi-san,

Sorry for my short-sight.

Then I tried using PSoC Programmer 3.28.4

(1) Load from hex, using previous test1.hex

(2) Program

(3) Load from device

(4) Read to Hex -> test4.hex

(5) Quit PSoC Programmer

(6) Cycled power of my board

(7) Started PSoC Programmer again

(8) Load from device

(9) Read to Hex -> test5.hex

(10) Then compared test4.hex and test5.hex

cmp2_test.JPG

In my environment, all test1.hex, test4.hex, test5.hex were same.

From your description, I was expecting some timestamp related differences

but with this test I could not reproduce the symptom.

Probably there was/were something between you programmed the original hex

and read out the data to file.

Best Regards,

22-Aug-2019

Motoo Tanaka

0 Likes

Hello,

I have been asking that something from the beginning.

Best regards,

Yocchi

0 Likes
MotooTanaka
Level 9
Level 9
Distributor - Marubun (Japan)
First comment on blog Beta tester First comment on KBA

Dear Yocchi-san,

> I have been asking that something from the beginning.

I am very sorry about that.

I wonder in case you program a new hex, let's call it  hexA,

and read out to a hex, let's call it hexB.

If these two are same or not.

But doing this may lose the current status.

Another thing I can think of is that the program itself may be affecting the value in the Flash ROM.

Such as using the flash as emEEPROM, etc.

Except those, I can not think of reasonable cause(s).

We need help from a Cypress expert for the explanation.

Best Regards,

26-Aug-2019

Motoo Tanaka

0 Likes

The line 518 is the metadata, which contains Silicon ID and other parameters.

Please refer to the CY8C4xxx, CYBLxxxx Programming Specifications, Section 2.3 Organization of the Hex File.

If the metadata is different, it would be difference of Silicon ID mainly.

When HEX file is generated by PSoC Creator, PSoC Creator puts ** revision in HEX file.

While, PSoC programmer reads the actual Silicon ID.

regards,

takashi

Hello Takashi-san,

It became clear.

Thank you very much.

Best regards,

Yocchi

0 Likes