Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Atmel AVR Pin Config Trouble

Status
Not open for further replies.

t_anjan

New Member
I am building a line tracer robot.

http://elm-chan.org/works/ltc/report.html

I am referring to the above page for the circuit and build design. He has used an Atmel ATmega8 AVR microcontroller. The pin configuration he has used is an MLF, which is a sqaure shaped IC with pins on all 4 sides, 8 on each side, 32 in total.

Here is the ATmega8 Datasheet: https://www.electro-tech-online.com/custompdfs/2005/02/doc2486.pdf

Refer to page 2 of the datasheet to get what I mean.

In the region where I live, only the DIP28 type of ATmega8 is available. The 4 pin difference between the DIP28 and MLF 32 types are
1. An extra Vcc
2. An extra Gnd
3. ADC6
4. ADC7

i.e., the above pins r there on the MLF type and not there on the DIP.

Now it seems as though I have to make do with the DIP type. But the creator of this line tracer has connected 2 of the IR detectors to ADC6 and ADC7. He has used these 2 pins instead of 2 pins PC4 and PC5 on Port C

Here is the circuit diagram: http://elm-chan.org/works/ltc/ltc_fin.png

These pins PC4 and PC5 are available on the DIP. But the ADC6 and ADC7 are not. Is it OK to shift over the 2 sensors to these 2 pins PC4 and PC5? Or is there is some special meaning to the "SCL", "SDA" that is printed next to PC4 and PC5, which makes those 2 pins unusable??

Also, after making the change in the circuit diagram, the source code for the AVR also has to be modified. I am guessing that the modification part will be pretty simple.

Here is the Assembly code: http://elm-chan.org/works/ltc/ltc.zip

Could someone please tell me if the circuit modifications can be made without causing erors? If so, could someone also be kind enuf to make the necessary modifications in the source code (I am not really well versed in assembly language yet)?

THANX A MILLION!!
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top