Codewarrior Debug terminating early on 9S08QG8

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Codewarrior Debug terminating early on 9S08QG8

883 Views
Spikey_Mikey
Contributor II

I am having trouble debugging my code using a PE USB Multilink Interface connecting to a prototype board that I built up using a 9S08QG8CDT.  Here is a stippet of the console window.  I find it odd that at the end the Frequency changes to ~0hz... twice even.

 

Info: Initialized.Info: ;version 1.03, 07/13/2009, Copyright P&E Microcomputer Systems, www.pemicro.com [9s08qg8]Info: ;device Freescale, 9S08QG8, All Info: ;begin_cs Info: Loading programming algorithm ... Info: Done.(FCDIV=$AC)Info: CMD>EMInfo: Erasing.Info: Module has been erased.Info: CMD>PMInfo: Programming and Verifying.Info: Processing Object File Data ... Info: . Info: Programmed.Info: CMD>VCInfo: Verifying object file Checksum16+CRC8 to device ranges ... Info:    block 0000E000-0000E3B1 ... Info: Ok.Info:    block 0000FFBD-0000FFBD ... Info: Ok.Info:    block 0000FFBF-0000FFBF ... Info: Ok.Info:    block 0000FFD0-0000FFFF ... Info: Ok.Info:    Checksum Verification Successful. (Cumulative Checksum16+CRC8=$F661FA)Info: CMD>PTInfo: Programming Trim value $A7 to location $    Info:  Success.Info: Programming FTrim value $00 to location $    Info:  Success.Info: CMD>REInfo: Initializing.Info: Target has been RESET and is active.Info: Frequency change to ~3984375hz.Info: Frequency change to ~0hz.Info: Frequency change to ~0hz.

 

Also, in the debug window I get:

<terminated>s08_MC9S08QG8_PnE U-MultiLink [CodeWarrior Download]<terminated, exit value: 0>C:\Users\Mike\workspace\s08\MC9S08QG8\s08.abs (9/18/11 9:52 PM)

 

 

Any ideas what I am doing wrong?

 

Installed Products: - CodeWarrior for MCU Version: 10.1 Build Id:110204

 

Thanks in advance!

Labels (1)
5 Replies

428 Views
bigmac
Specialist III

Hello, and welcome to the forum.

 

Perhaps reset due to COP timeout is occurring?

 

Regards,

Mac

 

0 Kudos

428 Views
Spikey_Mikey
Contributor II

Thanks for the welcome and thoughts on COP timeout.

 

I generated my code with processor expert.  First I didn't include the COP bean.  Then when the problem arose I tried including the watchdog timer bean and with a timer interrupt cleared it early and frequently.  I don't think the COP is the problem, but don't know what else to try to prove that theory.

 

My current theory is that my USB Multilink Interface may be defective.  I am going to see if I can scrounge up another one somewhere to test with.

 

Should the PE micro multilink be able to power 9S08QG8 parts?  My yellow LED wouldn't go on unless I used an external power source.

0 Kudos

428 Views
J2MEJediMaster
Specialist I

There is a very basic example program that comes with CodeWarrior for the 9S08QG8 that consists of an infinite for loop and all it does is spin and tickle the watchdog timer. Can you download it, and does it run successfully? If so, then your multilink setup is OK and you've got a problem with your program. If you can't get that program to work, then you've either got a problem with the multilink or your board.

 

Look at the multilink's data sheet and see if it is able to provide power. Some multilinks do, and some don't. Lacking that, go to P&E's web site and look there for information. Best bet is to check their comparison table for their different multilinks and you should find something on providing power there.

 

---Tom

0 Kudos

428 Views
Spikey_Mikey
Contributor II

Thanks for the tips.  I have should have access to a second multilink tomorrow to try, so I can eliminate that variable.  Meanwhile I have tried downloading several programs to the device and I can't stay connected to the device in debug mode.  It just terminates before I can get to any breakpoints.  A very simple program that toggles an LED based on a timer will load before it terminates, but a longer program that initializes several peripherals and then toggles IO will only partially work, which could either be a COP or file loading problem...

0 Kudos

428 Views
J2MEJediMaster
Specialist I

You can check out the COP issue now, assuming that your project uses the header file mc9s08qg8.h. At the very start of your program, add the line:

 

SOPT1_COPE = 0;  /* Disable COP watchdog */

 

That should turn off the COP watchdog timer. If your programs all run after that change, then it's a COP problem.

 

---Tom