Hi, i am trying to get a home build ardunio up and running, but am having issues.
I bought the basic components needed to make a stripped down bourduino, I jumped straight into soldering the first board up and almost suprisingly it did not work ;D So i bought another set of components and a prototyping board (good job this stuff is cheap ) and got it wired up, still does not work. I have triple checked the component posistions and everything appears to be in the correct place.
this is the circuit i am working to, there is no power supply / regulation as i am using a mintyboost as the supply.
This is the circuit i have, ignore the wire colour, it's just scraps i had laying around, 5v rail is on bottom and the 0v rail on top
The red led is connected to pin 13 and it should be running the blink scetch. I checked the led function by moving the resistor over to the 5v rail, its good. The chip works as i've used it in my uno and i've also checked the chip function after power up of the above circuit, the chip is still functioning.
I am wondering if the ceramic crystal is causing the issues, the website i purchased it from bitsbox, Has very little information on the crystal and i just assumed it would work, farnel has a pdf file on what appers to be the same unit and that shows the built in caps to be 30pf. Is it worth spending a bit more and getting a crystal and two seperate caps or is that not the caues of my issues.
Those breadboards have a high capacitance, add that to the 30pF of the crystal and a bit more for the long wires and it's well over the 12-20 in the specs, maybe that is the problem :-/
Try holding the xtal pins directly onto the chip (or stick it into the BB holes right near the chip with the middle pin bent up) with a flying wire to GND. Even then you'll still have the 30pF + the breadboard though.
Also you could bend pins 9/10 up and hold the xtal on them, just to possibly proove one way or the other.
Try holding the xtal pins directly onto the chip (or stick it into the BB holes right near the chip with the middle pin bent up) with a flying wire to GND. Even then you'll still have the 30pF + the breadboard though.
There are no crystal loading caps and that is not a crystal. It's a 3 terminal resonator, center lead grounded and has internal padding components.
Crosh had it right. You have got your Arduino pin connector numbers mixed up with mega328 package pin numbers. Arduino pin 13 led (with series resistor!) wires to pin 19 of the chip, not pin 13 of the chip, which is arduino pin # 7. Your board was probably working fine with the blink sketch loaded and running but with the led wired to the wrong pin, how would one/you know.
I thought those resonators still had internal caps connected to the middle pin.
Arduino pin 13 led (with series resistor!) wires to pin 19 of the chip
I hate the way Arduino and Picaxe "standardise" pins like that, I'm used to pin X being pin X. I can see why it's done and there are benefits, but I'm still getting used to it :-[. I think Picaxe differentiate by saying "leg X" and "pin X" where one is the physical pin and the other the logical pin.
I hate the way Arduino and Picaxe "standardise" pins like that, I'm used to pin X being pin X. I can see why it's done and there are benefits, but I'm still getting used to it . I think Picaxe differentiate by saying "leg X" and "pin X" where one is the physical pin and the other the logical pin.
Well the situation is that it is very desirable that the software be able to use 'logical pin numbers' that stay consistent thoughout the IDE (for both arduino and picaxe) so they can support different processor chips in different packages with different number of I/O pins available.
The lack of a one to one relationship is really a very small complaint given the large number of processors both IDEs can support. The arduino software mapping of logical pin numbers to physical pin numbers is truly a valuable function and central attribute of the platform. There is of course a speed penalty having to go through that pin translation function when doing digital I/O, but if one is willing to do direct port I/O commands then they may bypass the speed penalty at the cost of it only working correctly on one specific processor type.
So don't hate that there is not a one to one wiring relationship of pin numbers, but rather be joyful of the wide range of different chips you can utilize without having to memorize the I/O pins numbers of each different supported Atmel AVR chip that the arduino supports. It's really a good thing, as Martha would put it.
So don't hate that there is not a one to one wiring relationship of pin numbers, but rather be joyful of the wide range of different chips you can utilize without having to memorize the I/O pins numbers of each
Take a look at the board and schematic for this, its probably the simplest practical arduino type circuit - it uses a resonator rather than a crystal and caps. Theres a nice little diagram of the 168/328 pinouts as well. You're better forgetting all about the arduino when you're talkng homebrews, it just confuses the issue.
Well, i'll be, it's working, moved the resitor from pin 13 to 19, applied power and away it went Thanks for the help everyone.
So one lesson learnt, pin number does not correspond to output nuber in the sketch, sounds like some of the plc's i work with ;D Best make a note of which I/O goes to which pin.
Crosh, the 100nf cap is part of the mintyboost board i built as a test supply, now i've got this working the next version will have both circuits on one board.
Pluggy, thanks for the link, I've printed out the pin layout for future reference