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.

AVR Fuse Bits setting with Sinaprog

Status
Not open for further replies.

A.Rashad

Member level 4
Joined
Jul 27, 2011
Messages
69
Helped
6
Reputation
10
Reaction score
5
Trophy points
1,288
Location
Pune
Activity points
1,792
I need to set fuse bits for Atmega 8 , High Fuse bits : from D9 to F9 for disabling fyrther programming ..
I am using Sinaprog front end for AVR dude , When I sets Fuse Bits to F9 and click Write AVR dude Error Message comes , and fuse bits remain unchanged , I reinstall AVR dude also ! What should I DO ?
 

Are you able to communicate with the chip?
Can you read the fuses?
If not see if you have set the programmer data correctly (port and type)

I use AVR8 Burn-O-Mat avrdude GUI ,
it is also a front end for avrdude, I haven't tried Sinaprog
 

Are you able to communicate with the chip?
Can you read the fuses?
If not see if you have set the programmer data correctly (port and type)

I use AVR8 Burn-O-Mat avrdude GUI ,
it is also a front end for avrdude, I haven't tried Sinaprog

Yes!
I am Able to communicate and read the fus bits but I am not able to write fuse bits .. I tried Your Burn-O-Mat also , I installed it but when i am opening it , its not getting open , I have Jre also installed
....
 

Can you write any of the fuses with Sinaprog?
Can the chip be write protected, if so I think you need to do a full erase to write it.

I never had a problem with Burn-O-Mat, I have no idea what is wrong.
 

Can you write any of the fuses with Sinaprog?
Can the chip be write protected, if so I think you need to do a full erase to write it.

I never had a problem with Burn-O-Mat, I have no idea what is wrong.

I am doing Chip Erase by sinaprog but still its not working..can u say about some other GUI for AVR dude?
 

Writing F9 will disable serial programming. There should be some sort of protection for accidental disabling of serial programming (safe mode).

Try to switch off safe mode if there is an option. (I dont use sinaporg or burn-o-mat).

By the way why are you trying to disable serial programming. It is safer to use lock bits.
 

Writing F9 will disable serial programming. There should be some sort of protection for accidental disabling of serial programming (safe mode).

Try to switch off safe mode if there is an option. (I dont use sinaporg or burn-o-mat).

By the way why are you trying to disable serial programming. It is safer to use lock bits.


If I just make the lock bits to lock the code can anyone else change the lock bits back to 3f and read the code ? This is reason I was disabling the serial programming..
I am confused here, I think I have accidentally wasted my chip, Now is it possible to completely lock the chip by just using lock bits , means no one can rechange to these lock bits?I am newbie to AVR , please suggest
 

I think you should read
View attachment AVR_LOCKBITS_DN_020.pdf

The lockbits are there to prevent someone from making further changes or read the chip content, you can easily remove all the locks with a complete erase of the chip
 
If I just make the lock bits to lock the code can anyone else change the lock bits back to 3f and read the code ? This is reason I was disabling the serial programming..
I am confused here, I think I have accidentally wasted my chip, Now is it possible to completely lock the chip by just using lock bits , means no one can rechange to these lock bits?I am newbie to AVR , please suggest

Even though alexan answered it, i'll try to be more detailed.

Once lock bit is written, (the chip is locked)
1) you cant write anything into the chip. So the fusebits or lockbits cant be modified.
2) you can only read the fusebits and not the contents (hex file)

the only way to reset the lock bit is to erase the chip. Erasing the chips erase the contents in the flash(your data will also be erased)

Hope you will now be clear.
 
1) you cant write anything into the chip. So the fusebits or lockbits cant be modified.

The only exception are the lockbits which allow to program a higher level of protection (allows changing unprogrammed bits to programmed, but not the other way around) so when you are in level 2 that prevents further programming but allows read back you can change the lockbit to a higher level (level 3) to lock the read back as well.
 
The only exception are the lockbits which allow to program a higher level of protection (allows changing unprogrammed bits to programmed, but not the other way around) so when you are in level 2 that prevents further programming but allows read back you can change the lockbit to a higher level (level 3) to lock the read back as well.

Hello,
please help!
While working on ATMEGA 8, I write default fuse bytes HB:0xD9 LB:E1(Factory set) to HB:D9 LB:FF i.e I want to use external crystal of 8 MHz with 22pf capacitors, CKSEL0-3: 1111(unprogrammed i.e 1), the fuse bytes getting changed to D9 FF but the controller is not searchable/detectable after this in Sinaprog/AVR extreme Burner ,

After thinking that I set wrong fuse bytes, I set another Microcontrollers I/O pin to give pulses at 5ms delay and connected this signal to not working atmega 8's XTAL1 input , and search again in sinaprog , so NOW it was "searchable"

It gives me hope that my chip is now working / so i reset the fuse bytes to D9 E1 i.e default value , the chip started working fine and programming section was also working fine ,

But whenever I set fuse bytes to D9 FF i.e for external crystal, Its get stuck , code doesnt work neither the chip is detectable in any programming software(XTREME BURNER/AvR sinaprog) untill I gives it a 5ms PULSE from other microcontroller.

Iwant to use external crystal of 8 MHZ.

I have read datasheet also completely, I am Stuck at this what should I Do ??
 
I don't see a problem with the fuses, it should be working.
Have you tried with CKOPT programmed to see if you get a different result?

Are you sure that your crystal is OK?
 

I don't see a problem with the fuses, it should be working.
Have you tried with CKOPT programmed to see if you get a different result?

Are you sure that your crystal is OK?

hello,

Yes I checked with programming CKOPT means making that bit 0, i.e 1100100:cry:1 i.e C9 high byte ,
but it didnt work, my crystal is new , even I have changed lots of crystals and capacitors , also different atmega 8 , but the problem persists ..
I tried right now by using AVRDUDE also , by writing commands , but No results , as it sets once D9 FF
, chip gets unsearchable ..
Please help
 

Are you sure that this isn't a problem of your programmer device?
Are you able to communicate normally if you set the clock to internal RC 8MHz?
 

Are you sure that this isn't a problem of your programmer device?
Are you able to communicate normally if you set the clock to internal RC 8MHz?
hello,
Yes My programmer device USBasp its working fine for all the time, Yes once I set the internal 8 Mhz Oscillator , the device reponds searchable and code also runs fine..
 

USBasb has a jumper for slow clock operation , are you sure it isn't placed?

Setting jumpers:
J1 Power target
Supply target with 5V (USB voltage). Be careful with this option, the
circuit isn't protected against short circuit!
J2 Jumper for firmware upgrade (not self-upgradable)
Set this jumper for flashing the ATMega(4)8 of USBasp with another working
programmer.
J3 SCK option
If the target clock is lower than 1,5 MHz, you have to set this jumper.
Then SCK is scaled down from 375 kHz to about 8 kHz.
 
I'm not sure what else to suggest, I never had such a problem.
Are you sure that your connections around the crystal are correct?
Double check the pins where the crystal is connected.
Can you try with a lower freq crystal like 4MHz or 2 or 1MHz?
 

I'm not sure what else to suggest, I never had such a problem.
Are you sure that your connections around the crystal are correct?
Double check the pins where the crystal is connected.
Can you try with a lower freq crystal like 4MHz or 2 or 1MHz?


Hi,
Ok sir , I will check , Thank you very much for efforts..
 

I'm not sure what else to suggest, I never had such a problem.
Are you sure that your connections around the crystal are correct?
Double check the pins where the crystal is connected.
Can you try with a lower freq crystal like 4MHz or 2 or 1MHz?


Hello Sir ,
I am now successfully able to set the fuse bytes for external crystal , the chip is detectable again :)
But the code runs for 2/3 hours properly, after that the ATMEGA 8 starts malfunctioning , and if i Connect the board to my programmer, again the ATMEGA 8 is not searchable,

Is this a issue of heating ? Do I need to put ATMEGA 8 in sleep Mode untill my code which is interrupt driven for UART , receives any data on UART ?
can you please help me how can i use sleep Modes ? I have studied Data sheet , where i found five power saving mode ?
I can set MCUCR but which instruction I should use to enable sleep/Power save mode and which power save mode should i use?
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top