New to AVR. Planning to make a dev board.

Go To Last Post
61 posts / 0 new

Pages

Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi to All! :-)

I am new to AVR (and micros), so I thought of making a basic dev board to start with.
I'm sure many experienced people here would readily suggest me to buy a dev board instead of re-inventing the wheel. However, I like working with hardware since I have some education in electronics. :-)
I'd really appreciate if I could get some inputs on what I can put on a general purpose dev board. I have a list below:

1. Micro: ATMega16
2. Xtal and caps: 4Mhz
3. Small switches: say, 8 switches, for giving inputs to port pins.
4. Header connectors for ports- 4 sets, one for each port.
5. LEDs: a set of 8 to show the status of an entire port at once (or should I put another set...)
6. Driver for LEDS (and maybe relays or steppers, if I want to add them later): here i was thinking of ULN2003/2803. Please comment if it would be too much of an overkill for LEDs, or am I thinking right about being able to use it for more later.
7. MAX232 (and associated components) for interfacing to PC.
8. DB-9 serial port connector.
8. ISP connector
9. 7805 regulator
10. DC power connector.
11. A reset switch.

12. A seven segment display (optional)

This board will only serve as a general purpose board for learning to play with AVR. I don't intend to use it for any specific application.

Thanks in advance,
Aashish.

P.S. Please point out if this could be posted in a more suitable forum on the site: I don't want to post too many 'newbie' questions here.

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

There are many dev boards already available from Poland, India, Thailand and China.

You might also pick up a secondhand STK500 from eBay.

I would also look at an Arduino + breadboard.

Quite honestly, you will never build a dev board cheaper than a ready-made one. The pcb alone will cost you a lot. If you try a do-it-yourself pcb, you will make several mistakes.

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi David,
I understand that it may well not be worth the money, and it may have a few mistakes too. But I am not making one so I can save on money: its just about the feeling of accomplishment/thrill to have made one yourself. :-)

Like I mentioned, I have some background in electronics (though I am working in software now), so I am a hardware person too.
Breadboard sounds good, atleast for the cost factor, but having a dev board with a few basic things on it already is better anyway.

I do appreciate the response, though.

Thanks,
Aashish. :-)

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

If it's for you, then you are the best judge of what to put on it, as only you know what it is you're going to try and do with it. If you want hints or inspiration, look at the dev-boards that already exist.

Personally I'd say save your money [I know it's not about the money, but needlessly spending is foolish] Get an off-the-shelf [tried, tested and true] dev-board, and then build your own add-on board for it to add functionality. This will save you a lot of headaches, and you'll still get a sense of accomplishment from the process.

Writing code is like having sex.... make one little mistake, and you're supporting it for life.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

What I did was to buy a bare PCB from one of the Asian ebay outlets that would mount a 40pin dip avr. The board had places for a max232, power socket, 7805 regulator, 9 pin D serial connector, bridge rectifier, filter caps, crystal and caps for the AVR clock. The rest of the board was all .1" spaced grid copper clad though-hole solder points for mounting other parts. On this board I could add other IC's, connectors, etc to complete my custom development board design with point to point wiring. This kind of platform may be what you want to start with.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Was the bare pcb cheaper than buying a complete populated dev board?

I always reckon that the Olimex boards are not worth the money. However you do get the prototype area to customise for yourself.

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

david.prentice wrote:

Quite honestly, you will never build a dev board cheaper than a ready-made one. The pcb alone will cost you a lot. If you try a do-it-yourself pcb, you will make several mistakes.

David.

I've been making my own prototype boards at home for years, and they nearly always work first time.

I can make a board (8/8 mils) in 30 minutes, plus drilling.

Leon

Leon Heller G1HSM

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

david.prentice wrote:
Was the bare pcb cheaper than buying a complete populated dev board?
I always reckon that the Olimex boards are not worth the money. However you do get the prototype area to customise for yourself.
David.

YES! However I did have a lot of the parts (sockets, 7805 regulator, caps) in the 'junk box', but I think even buying all new parts you would come out cheaper building it yourself rather than going with Olimex. The board I got was similar to the Olimex but had a larger prototyping area as the AVR chip was not in the middle of the board, but off to one side with the board in the 'landscape' position.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Since you are using a serial port I would change the 4Mhz crystal to something "standard baudrate friendly". Something like 7.3728Mhz or 11.0592Mhz will give you 0% error with all common baudrates. The 7805 is not the best choice for a linear regulator, the LM2940-5 for example, is much more efficient.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

OP clearly states he can buy one but wants the experience of building one. I always get the feeling some users are always hating one people trying to build custom dev board. Who care's if it's been done already, its a HUGE learning experience. 8)

@aashish_delhi
Don't let the others discourage you from building your own product. I've spent the last 8 months (part-time) designing my development board for xmega. I had a large buyer from the start so I knew I would at least break even on the project, but even if that wasn't the case its still a great experience IMO. Just some warning for you though, component research will take much longer than you think so be prepared to spend a lot of time on that.

As for what you want on the board, that is pretty much up to you. If you ask 10 different people you will get 10 different list of parts to add. Just go with what you want. I think the really necessary parts are:

    Good power supply RS-232 level shifter with DB9 connector
    ISP connector
    Reset
    Some buttons/switches
    Some LEDs
    Route all IO pins to some sort of external header.

I think those items should be on every dev board. Everything else is just extra and should be up to you.

Dan

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I'm with Dan on this one: Built your own!

Application Note AVR042 describes the crystal, programming headers etc.

Include a 6-pin ISP programming header to program the board when you are done.

Be very careful what you put on the pins that are used for ISP programming. They can do double duty, but only if you are careful in the design and what the pins share. Much easier for your first board to just dedicate those pins to programming and no other function.

Add a piezo beeper so your board can beep.

Add a pot so you can hook the pot up to an ADC to test measuring an analog input voltage.

I would add an LCD, 2x16 character, for example. That would also need a pot for setting the contrast.

You might want to add a thermistor or a Dallas Semi Temp sensor to work with, and to display its data on the LCD or 7-seg display.

You might want to add a FTDI chip, (or module), tied to one of the USARTs, so you can plug into a USB port on a PC instead of a serial port.

Make sure you have a push button reset switch. It beats turning the power on and off all the time when testing code.

It is nice to have a small on/off switch on the board.

Make sure you understand AVcc and Aref. AVcc ties to V+, Aref ties to a cap to ground.

Be sure to put mounting holes in the corner of your board.

Have fun.

JC

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

THANKS, JC, Dan, others!! That was really encouraging! :-) some really neat advice (as always!) on component selection, placement, and things-to-remember too.
Will keep you posted on the progress on this. Once I'm done with it, I plan to post all the info I can under Projects.

Cheers,
Aashish.

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I went with the bare board because I could design my own using point to point wiring without having to first go from schematic to pc layout, get it etched and drilled, etc. (Besides I LIKE doing point to point wiring!)
I used the 7805 because that's what the board was designed for (is the LM2940-5 a drop in replacement?). The board I used has both the JTAG and 10 pin ISP connector footprints as well and will work for ANY of the 40 pin AVR's. I've added an LCD, 16 pin keypad, and a rotary encoder (mounted off board) to the circuit as well as an off board SPI connector. A small speaker is connected to one port pin though a 10uf cap to beep when a key is pressed. I started with the ATmega16L, and now have an ATmega32 on it (changed out the 8mhz xtal for a 16mhz), I'll probably upgrade to a mega1284 and go to 20mhz (project is growing). If I can find the URL of the company I got the board from I'll post it here. I wish the board had a USB/Serial chip on it instead of the MAX232, but I can always pull the chip out of the socket and connect the tx/rx leads from an external USB/serial module. Right now I'm using a USB/Serial dongle on the back of the computer.

Eventually, once I've settled in on what I need for this project I may capture the complete circuit and do a PCB layout. I'll probably go with SMD parts instead of through-hole at that point though.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Since I want to include a dedicated header for ISP on the board, could you please help clarify a few things about ISP programming?
1. Let's say I buy an AVRISP mkII to program the micro.
2. I set up the micro on a breadboard with a 5V supply, xtal and caps, and a connector for ISP pins.
3. I connect the AVRISP programmer to the ISP pins.

Question: What should I do with the VTG or VCC pin of the programmer? Should I leave it NC? When is this pin really used, and how?

What are the other considerations while programming a micro? I read the user guide of AVRISP programmer and it mentions selecting the right frequency for the programmer. I couldn't really see how that is so important, or how should it be selected based on the target crystal (say 7.372MHz).

What about the default connection for ISP pins of the micro? Do they need pull-ups?

Am I missing something regarding ISP programming here? :-)

Kindly explain.

Thanks,
Aashish

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:
Question: What should I do with the VTG or VCC pin of the programmer? Should I leave it NC? When is this pin really used, and how?

On some programmers the VCC pin is an input to steal power FROM the target. On others it will SOURCE power TO the target. In the later case the programmer should have a jumper to disable this feature. On other programmers the VCC may be labeled as VTG and it SENSES the presence of power in the target. In this case the programmer will report an error if the target is NOT powered at the correct voltage before it attempts to program the target. In all cases this pin on the programmer should be connected to the VCC pin of the target processor.

Note that the ISP programmers have only one such pin, JTAGS have BOTH vSupply (VCC) and vtREF (VTG). vtREF is ALWAYS a power sense, vSupply can steal power from the target, some clones might have the option to supply power via this pin but Atmel's programmers do NOT do this. The voltage bridge chip (allowing the jtag to program low voltage parts) is powered from the vSupply pin.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Simply steal the Olimex design. Or ETT, Propox, Sure ...
This answers your pull-ups, and VTG questions.

It is very important to standardise the pin headers. Atmel has a 6pin ISP, 10pin JTAG, 10pin PORTx layout.

I recommend using box headers to ensure you plug cables correctly. At least identify pin #1 very clearly on the top of your board. (and use a square solder pad on the copper side)

A baud friendly crystal is handy. 16MHz can achieve 115200 baud with U2X.

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

In all cases this pin on the programmer should be connected to the VCC pin of the target processor

That cleared up things a bit! Going with this and with what the user guide of AVRISP says, it makes sense. The AVRISP uses this pin to sense the target's power.
Thanks for the explanation! :-)

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Both the 10 pin and 6 pin ISP connector blocks ARE standard. The 10 pin layout originated with the Kanga designed STK200 which was sold by Atmel for many years. The STK500 also uses the 10 pin layout. Later Atmel originated a JTAG connector with the same 10 pin block, at this time they came out with the 6 pin ISP connector, I think that the STK600 uses this. Dev boards are made with BOTH ISP connector styles (some actually HAVE both), and adapters are easy to make (or buy) to go from one to the other. IIRC the AVR dragon has both styles on it. If you already bought an avrispmkII you might as well use the 6 pin style on your board.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

Simply steal the Olimex design. Or ETT, Propox, Sure ...
This answers your pull-ups, and VTG questions.

Yes, I just downloaded the schematic of the Omilex board for atmega16. This has made things easier for me as far as board design is concerned. :-D Thanks for the tip, David!

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Omilex makes two 40pin dev boards, one has RS232 serial IO the other uses USB with a USB/Serial bridge chip on board. Might as well copy the newer USB design.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:
I always reckon that the Olimex boards are not worth the money. However you do get the prototype area to customise for yourself.
Have you seen these? I recon they're great! The quality is superb!...
http://www.protostack.com/boards/microcontroller-boards/28-pin-avr-development-board
A tad expensive, but if you buy a few, the shipping works out to make them quite affordable. When I bought my batch they worked out about 6-7 GBP each (all in). Did I mention the quality? :) Very easy to solder, many choices of power supply, 10 and 6 pin ISP, and an IDC near the edge! Practically perfect in every way (as a dev board). Oh, and a couple of weeks to ship to the UK.

--greg
Still learning, don't shout at me, educate me.
Starting the fire is easy; the hardest part is learning how to keep the flame!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi All!!
I have started working on my dev board. The board now has the micro, xtal, caps, reset button, 8 LEDs, a 5V regulator, 8 switches, and a header for port C. I was able to program the micro using a USB programmer i bought locally. So far I have only run a simple LED flasher program and the LED is flashing on my board. :-) :-)
This is a big moment for me since it is my first dev board/project and it works! I must thank all who encouraged me and gave great tips on how to go about it.
I have a small problem, though.
I wrote my 1Hz LED flasher program in AVR studio and selected ATMEGA16 as the chip. The simulator takes 4MHz as the default frequency. The prescaler values for the timer have been set acc. to 4MHz. The program works as expected in the simulator.
However, my mega16 is running on a 16MHz xtal. Shouldn't that speed up the LED flashing rate by 4 times? Instead, I see that the LED is flashing at 1/4 Hz! Could anyone please suggest what I may be doing wrong here? I have copied the code below:

#include 
#include 

int main(void)
{
DDRC |= (1<<0);
TCCR1B |= (1<<CS12);
TIMSK |= (1<<OCIE1A);
sei();
OCR1A = 15624;
TCCR1B |= (1<<WGM12);

for(;;){
}
}

ISR(TIMER1_COMPA_vect){
PORTC ^= (1<<0);
}

In any case, I am really happy that I got the hardware to work right, so far! Not the most difficult thing in the world, but it counts a lot for me! :-)

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

1) you can change that 4MHz in the simulator to any value - use the bottom entry on the debug menu. Note that the ONLY use of this value is for the "stopwatch" facility in the simulator - it has no effect on the speed of simulation. The simulator always simulates at something like 50kHz to 100kHz.

2) Did you change CKSEL fuses on the mega16 to actually enable the use of the 16MHz crystal - also did you enable the CKOPT fuse which is needed for "full swing" operation when using crystals of 8MHz and above?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

OOPS! I think I know my mistake...! The clock is 4 times faster, so the count after prescaling is more too!! Gosh, what was I thinking! :-P

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Clawson!
No, I did not enable the xtal explicitly. I was not aware that I had to. :-(

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Well just wiring a crystal to a chip doesn't mean it suddenly takes over from the internal RC oscillator. You have to change the CKSEL (that is ClocK SELect) fuses to tell the AVR which clock source is active.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

okay.. i just ruined everything...
I programmed this thing with USBasp programmer. I selected some fuses according to my judgement (guided by what I found by googling a bit..). The programmer I have is a socket version. I don't need to do anything except clamp the AVR into the socket and flash it from a gui (Khazama programmer).
The changing fuses operation was successful, bit now the programmer doesn't see the target at all. It says "target doesn't respond".
I had selected high frequency... and maybe 258CK startup or something.
Any ideas? What are my options now?

P.S. The AVR seems to be working on the board, though. The fuses seem to have taken effect since the LED is now flashing much faster!

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You probably need to provide the AVR with an external clock source, so that you can reset the fuses to something sensible.

Leon Heller G1HSM

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Yup, what Leon means is provide a clock source (a square wave, perhaps about 1MHz) to the XTAL1 pin while attempting to do ISP again - start by setting the fuses back to the datasheet default then THINK before changing them again. Maybe use the engbedded fuse calc (Google it) to help you with the fuse selection next time.

Possible sources for the 1MHz clock:

1) another AVR toggling a pin
2) another AVR that has CLKOUT
3) an STK500
4) an NE555
5) a signal generator
...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Leon!

I just made some connections for the ISP pins on the board. When i connect the programmer, the micro takes supply voltage from it and starts to flash the LED! :-(
It still can't detect the micro.
I had thought that once the micro has its own crystal and supply, it should be detectable by the programmer. I suppose I will have to lookup some documentation about the programmer before doing something foolish...
I don't have any other kit/programmer either.

How exactly can I go about this now...?

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I'll try giving it a clock from a 555 timer IC. Will set it all up on a breadboard.
Looks like the programmer is supplying 5V at the Vcc pin, so I won't have to give my own supply, right...?

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

That should work. Don't forget to connect the grounds.

Leon Heller G1HSM

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ALL the grounds of the ISP header? Leaving out the ones other than at pin2 won't work...? Just sayin'...

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I meant the external clock and board grounds.

Leon Heller G1HSM

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

:-( no good... I breadboarded a 555 timer with Ra=1K, Rb=220, c=.001uF. This should mage a roughly 1MHz clock. The micro is taking the clock and flashing the LED! But the programmer is still showing the same error...
Is there anything else I can try? Or am I missing something...?

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

Is there anything else I can try? Or am I missing something...?

As it's a mega16 you cannot lock yourself out with ISP alone. The only "damage" you can do is make a wrong clock selection. One important thing is that the ISP but always be 1/4 or less of the F_CPU so if you clock the AVR at 1MHz you cannot run ISP at more than 250kHz (and something slower would be better).

One thing you might want to consider is getting a JTAG interface - it's an alternative programming mechanism for mega16 and it also allows you to debug the chip. When I develop with mega16s I always lay out a header for JTAG but only sometimes bother with ISP as you can achieve everything with JTAG - it's only downside is that it ties up the top 4 pins of PORTC. (though you can disable it by software running on the mega16 itself)

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks, Clawson.
The programmer I have is called USBasp and it comes with a very basic kinda gui. Unlike AVRISP, I don't have too many options with my setup. I looked at the user guide of AVRISP and it allows control of ISP clock speed, etc. My kit doesn't allow me to do that.
I bought this 'cheap' kit simply because Atmel tools are expensive when converted to my currency :-)
JTAG is even more expensive.
I might eventually take that route, but as of now I was looking for other alternatives.

With the 555 setup, I can see that the micro is responding to the clock (the LED flasher is doing its job), but the programmer still doesn't recognize the target... Isn't this supposed to be the 'regular' solution to such problems: supplying an external clock.
I still wonder if I am missing something...

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

My kit doesn't allow me to do that.

USBAsp can be driven by avrdude. It has "-B" which allows the ISP speed to be changed (I think it will work with USBAsp).

As for the cost of JTAG, one advantage of choosing to develop with one of the very old AVRs (mega16) is that one of the $30 JTAG interfaces may only support about 10 models of AVR but the mega16 is one of them.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I will download avrdude and try with that.
I'm curious if I must know the 'exact' frequency of my external clock. 555 timer can be a bit inaccurate to setup like that. So how do I decide the clock of my ISP? Or is it safe to go with <=1/4 F_CPU? Thanks for the tip.

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I will download avrdude and try with that.
I'm curious if I must know the 'exact' frequency of my external clock. 555 timer can be a bit inaccurate to setup like that. So how do I decide the clock of my ISP? Or is it safe to go with <=1/4 F_CPU? Thanks for the tip.

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Just pick the slowest speed possible.
If the speed selected is too high, it won't work.
To slow is not a problem, it just takes a little bit longer.

JC

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I managed to resurrect my micro, for once. I re-checked the ISP connections, supplied an external clock from the 555 timer,
and flashed a LED flasher hex into it. It was all successful so far...
Then I tried to play with the fuses, using the values I found at engbedded fuses calculator(http://www.engbedded.com/fusecalc). However, when I tried to read the fuses (H and L) using avrdude, I could not see them set the way I had tried! They all seem to be 'cleared'!
After this I erased the chip using Khazama software, and that was successful too. Using the same software, I then flashed the test program again. This time, the program did not work, the LED did not flash.
Now, when I try to read the fuses using avrdude, it throws an error saying that device signature is not valid! Initially I was consistently getting a signature like 0xfffffff, but now it seems to change at each attempt to talk to the chip!
Is my micro (atmega16) dead?? :-( I don't have access to a scope, etc. Is there anything else I can try?
Please help!! :-(

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Go back to using your 555 injector and re-program using slowest speed. Double check, no, tripple check the fuses BEFORE you re-program them. Once you get the chip back working right. Don't change the fuses again :) If you keep getting it wrong, at some point, you will get it so wrong, you'll never recover it.

--greg
Still learning, don't shout at me, educate me.
Starting the fire is easy; the hardest part is learning how to keep the flame!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I seem to have gone past the 'beyond recovery' stage already...
avrdude doesn't even read the correct signature of my chip!! :-(

I'll try it again tonite and see if I can get my chip to breathe again... Fingers crossed.
IF I get it to respond to ANYTHING again, I'll first come back here and get a double clarification on fuse bits... one bit at a time..before i dare to program them again. :-)
Hmmm... could you please guide me on how to use the slowest speed? I mean, how do I command avrdude to do this? I read some documentation, but couldn't get it to work. My 555 clock is about 1MHz. Could you please post a sample command here?

Thanks for the support!:-)

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Okay, here's an update:
I managed to flash into my micro using -F option in avrdude. I also programmed the fuse bit (as found on engbedded fuse calc) to default values. Now my micro seems to be running on the internal clock. :-) yay!

Could the experts please tell me what "exact" values should I program the fuses to so that I can use a 16MHz external crystal? I don't want to mess up things this time, and I've had enough of this fuses trouble. :-) I'm sure you understand.

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Problem solved! :-)
I got the correct fuse settings from engbedded calculator and burned them in. My mega16 is now running off its 16MHz xtal! :-)
Thanks to all for valuable tips and advice!

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Excellent! :) :) :)

Now, leave the fuses alone will ya? ;)

--greg
Still learning, don't shout at me, educate me.
Starting the fire is easy; the hardest part is learning how to keep the flame!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Sure! :-D
This was my very first project with any micro and I learnt things the hard way. Imagine, a noob having to wrestle with wrong fuses and such! Thankfully I managed to improvise and got my chip back. My prior experience with the 555 timer helped too.
Will proceed with making of the remaining board and keep you guys posted if I make some really significant progress.
Thanks again,
Aashish.

-Aashish.
If you don't see it coming, you'll never know what hit you...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:
I learnt things the hard way.
Always the best way to learn. You remember better when it's cost you blood/sweat/tears. The very first thing I did was screw up the xtal fuses! Luckily I have a function generator and plenty of reading the threads in AVRFreaks about screwing up fuses put me on the right track to fix it :)
Now I'm an expert at telling people to leave the fuses alone :) :) :)

--greg
Still learning, don't shout at me, educate me.
Starting the fire is easy; the hardest part is learning how to keep the flame!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

Imagine, a noob having to wrestle with wrong fuses and such!

Stick around - it accounts for maybe as much as 5% of all the traffic on this board.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

That may well be true, Clawson. :-)
I've looked all over the 'net and I found PLENTY of posts about getting the fuses wrong.

-Aashish.
If you don't see it coming, you'll never know what hit you...

Pages