cancel
Showing results for 
Search instead for 
Did you mean: 

work well when programmed, but not on debugger

omatza
Associate II
Posted on November 23, 2005 at 08:59

work well when programmed, but not on debugger

6 REPLIES 6
omatza
Associate II
Posted on November 16, 2005 at 15:22

Hello

I have simple program that get byte from spi channel and send it to SCI channel.

When I program/burn it to the board, then it runs fine.

when I load it with in-dart debugger and hit run, then the program gets TRAP and stop in first line of the program.

Can any body tell me why ?

(I think it is related to the interrupts vectors table, but I don't know how to fix it)

File is attached

Thanks

Oren

________________

Attachments :

main.asm : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I06k&d=%2Fa%2F0X0000000bTV%2FHHfJifGT1j6RXCgqOlWDlt7PpOxBGrNWrvPXqsQNYAs&asPdf=false
omatza
Associate II
Posted on November 17, 2005 at 05:16

Correction!!!

I get traps also when it burnned into the flash.

(I made a test like this:

printout character

endlessloop

code here

jump back to endlessloop

and I got the printout characters every 250ms (estimation only)

)

why I get this traps ????

Thanks

Oren

alain2399
Associate II
Posted on November 22, 2005 at 05:15

Hi Oren,

my guess is that your problem is due to a watchdog reset. Do you take care of not programming hardware watchdog or refreshing the watchdog in order for it not to trigger a reset ?

alain2399
Associate II
Posted on November 22, 2005 at 05:35

Hi Oren,

my guess is that your problem is due to a watchdog reset. Do you take care of not programming hardware watchdog or refreshing the watchdog in order for it not to trigger a reset ?

omatza
Associate II
Posted on November 22, 2005 at 06:46

Helo Alaini

I thought about the watchdog.

I am doing anything with the watchdog.

It stays the same way as it was in power up, and I understand that it is disabled by default.

(The entire code is attached in the main.asm, in original message)

Any more hints ?

Thanks

Oren

omatza
Associate II
Posted on November 23, 2005 at 08:59

hello all

I got answer for this and it was right.

The problem was that the option bytes was configured to hw watchdog, meaning the WD starts automatically after the reset and reset the MCU if not refreshed within the correct time window

I saw that in the STVD debugger there is a place to change the option bytes. I changed it to SW WD and now it is ok.

🙂

Oren