programming problems - MC9S12XS128

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

programming problems - MC9S12XS128

Jump to solution
1,768 Views
LeoG
Contributor I

Hello,

 

I have some problems with my freescale controller. At first, I want to provide some more details.

 

Some weeks ago I started my work for a own controller board optimiesed in size and other stuff. I started various tests on two demoboards, the DEMO9S12XEP100 and the DEMO9S12PFAME. As I liked these controllers I began to design an own circuit for my special needs. On this board there is a MC9S12XS128 with 64-pins. I tried to design this board like it is being showed on the „reference manual“ of the chip and on the schematics of the DEMO9S12PFAME board. This prototype (whole board) was milled, soldered with an placement machine and backed at about 150°C. Now, I just finished the work on it but there seem to be some problems.

 

I power my circuit with 12V and use a high inductor and a linear voltage regulator to get 5V stable.

When I power my circuit with an power supply (12V) the consuption of current is about 100 mA. Thats quite high in my opinion. Do you have any experience of „normal“ current consumption with a minimal circuit and a minimal amount of components.

 

When I now try to program my controller with a P&E Multilink USB-ML-12 rev. c (BDM) I'm not able to get the right speedsettings. I also tried to unsecure (with the program Unsecure-12) my chip but thats not possible, too. After connecting the PE-Multilink to both of my demoboards everything is fine.

 

On an oscilloscope I can see the signals of the RESET pin and the BKGD with the following behaviour. The BKGD voltage is at about 4,4 V and the RESET voltage at about 3,7 V in idle mode. During program I can see toggles on both lines. The RESET voltage now switches between 0 V and 5 V. The BKGD voltage switches also between 0V and 5V if a byte is beeing transmitted. Between two bytes there seems to be an idle time which is just a few bits long. This idle status voltage is again at about 4,4 V. Is this the normal behaviour? Are the voltages in idle mode too low? How to improve that?

 

When I click on debug in CodeWarrior the debug-program tries to find the appropriate BDM speed and ends with the message „couldn't find the right io_delay_cnt“. Afterwards it seems to program. During this time I am able to see the signals described above. In an info window the status is showed. It says „Programming at 0,003 KB/s“. After finishing the programming phase it tries again to get the right BDM speed and ends again with „couldn't find the right io_delay_cnt“. The last thing which is being showed is „Running“. So it may be possible that the transmission of the code was ok and just the debugging functions are not available. Is that right? The problem is that the functions I wanted to implement on the controller (like PWM, …) are definitly not running. I checked these pins with my oscilloscope. So I'm not sure whether the programming is fine or not.

 

I have already tried various other things to locate and solve my problem but I run out of ideas. So I appreciate any help and hints because I would really like to use these freescale controllers.

 

Ty,

Leo

 

Added p/n to subject

Message Edited by NLFSJ on 2009-05-10 10:44 AM
Labels (1)
0 Kudos
1 Solution
433 Views
LeoG
Contributor I
I just fixed that problem. I had an external oscillator with an output clock voltage of 5V. Only 1,8V is allowed. After installing a resistor network to get down to 1,8V everything is fine.

View solution in original post

0 Kudos
2 Replies
433 Views
jsmcortina
Contributor III

I might be off track here, but what clock source are you using on your board? Crystal or self clock or?

 

When using the crystal, be sure to specify the right dividers in the HIWAVE utility when trying to programme.

 

Also be sure that HIWAVE is set up for the correct CPU derivative.

 

James

0 Kudos
434 Views
LeoG
Contributor I
I just fixed that problem. I had an external oscillator with an output clock voltage of 5V. Only 1,8V is allowed. After installing a resistor network to get down to 1,8V everything is fine.
0 Kudos