Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Atmega64/1281 crashes/restarts/corrupts

Status
Not open for further replies.

movie_freak

Member level 5
Joined
Mar 20, 2007
Messages
89
Helped
2
Reputation
4
Reaction score
0
Trophy points
1,286
Activity points
1,943
I have a little.. weird kind of situation and I am unable to find a particular reason..

My program flow:

Code:
//global variables
int g_power_on_F = 1;


main()
 {
	
	
	//initialization of variables and copy some from eeprom

	//other initializations
	//indicate variable and other initializations


	while(1)
 	 {
		if(g_power_on_F == 1)
		 {
			indicate power on
			g_power_on_F = 0;
		 }
		all other states of my system

	 }
 }


My Situation:
After some time of proper execution my code behaves abnormal and I am unable to figure out whether its a crash without restart, a restart or corruption


What happens:
After some time of proper execution I can see an indication of power on again, at this particular point all the initialized eeprom variables are blank and erased, and the code does not work as intended, also before this power on indication if the controller had a restart it should show variable and other initialization indications which is not showed in this situation (whereas in contrast, a manual power reset these indications do work)


So as we can see that the code is designed in a way that the power on indication should only come when the controller is reset, and if my eeprom and variables indications are not showing it seems to me as if the code is jumping with corruption


So I want help:
--- I wanna know what are the steps i can now take to further deepen and narrow the faulty area of my code
-- and if some one could have already faced this kinda problem then what could be the issue?
-- What could be the possible causes?



Many Thanks,
Surya
 

Yup i belive so.. my fuses are
Code:
0x4D 0x91 0xFF

low high extended respectively
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top