[SOLVED] Using Digital Pin 20-21 with atmega328 on a breadboard (Int Osc)

Happy easter everyone!

I searched the forum and all I came up with was directives for an older version of the IDE so it was useless...

I was wondering if you guys have any guidance or tips on how to use the Digital pin 20 and 21 when the crystal is not used.

The IDE doesn't throw any errors if I try to use then, it just doesn't work.

The chip works on the breadboard, just can't seem to make the pins trigger...

Anyhow, if anyone have a clue... Please share!

DW

You have left the Arduino security-blanket.

It's in the datasheet. Section 13: I/O ports.

I believe you need to set the fuses to use the internal RC clock instead of the crystal that should be connected on those pins. Have you tried that?

If he didn't, it wouldn't work on a breadboard without a crystal.

His problem is that these pins are not part of the digital_pin_to_port_PGM array (pins_arduino.h). If he is lucky he can just add them there. If any other parts need modification... well he will find out.

Or use DDRx and PORTx like grownups :wink:

bubulindo: Like madworm said, it wouldnt work if RC fuse weren't set... But thanks for the input!

Thanks for the hint madworm :wink:
I already had that file open, think I will make it...

Will report back!

DW

EDIT :

I forgot... NOOOOOOOOOOOOO Not my blancket!! :stuck_out_tongue: That's the new polite way of saying RTFM right? :stuck_out_tongue:

If it is interpreted like that... then not everything is lost ]:smiley:

LMAO stop it, can't try it our while laughing :stuck_out_tongue:

Didn't watch yet, I will in the next couple minutes, as I just figured out I'm an idiot...

Pretty sure it will work now... brb

*** EDIT ***

Well, I got one step closer, but still wont work...

I did as stated on this webpage (http://placeboaudio.com/how-tu-use-atmega-pb6-pb7-with-arduino-when-n), but in the file pins_arduino.h .
(Yeah, I learned to read to potato!! .... )
I made a "no_crystal" variant, and set that in my boards.txt file for this board.
Still no signal on pin 20 or 21...

Can it have something to do with a fuse setting or bootloader?
Or is there something else I'm not getting ...

Thanks...

DW

Don't you dare say it ... :stuck_out_tongue:

Working... was an idiot again lol

For those in the future who will want the quick answer... Or for next time I need to go this :stuck_out_tongue: .....

Use the instructions in my previous post. It works.
I am using the Pro 8mhz Bootloader, on an atmega328 (non-P) with fuses: 0xD2 0xDA 0x05.

There! :slight_smile:

I'm out to see that video! :stuck_out_tongue:

DW

LMAO Please stop singing....! :wink:

Thanks for your help madworm, greatly appreciated!

DW