I am getting some strange behaviour and trying to figure out what is going wrong. If I connect a LED with 220 ohm resistor to any other pin than pin 13 I am getting very low output, like there is very little current for that pin. I have the pins configured as outputs in software. On pin 13 the LED is bright, on any other pin it is very dim.

I've also tried this with 2 different atmega 168 chips, so the chip itself doesn't appear to be the problem.

I changed the pins to output pins and use digitalWrite(pinNum,HIGH). It seems like the pins can't supply much current. If I have an LED connected on pin 13 it appears dim on one atmega168 and bright on another. Connecting a digital pin through a LED and then a 220 ohm resistor, some appear bright and others appear dim. It's got me stumped whats causing the problem. I'm using a USB arduino NG modified to work as a decimelia. I have the original atmega168 that came with that and also three new ones I burned with decimelia bootloader. All the code works fine, they just don't supply much current.

Its nowhere near that bright. I've checked the resistors using a multimeter. I've also checked the voltage using an oscilloscope. Some of the pins appear bright and some don't. For example, one mega168 will have a bright output on pin 13, the next one won't, it will be quite dim. Even with no current limiting resistor the LED's are dim. I ordered the extra 168's direct from atmel as samples so I can't see that 3 samples would all be bad. I don't know if its something to do with the board itself. I'm thinking of buying a new decimelia and seeing how that is.

did you check the voltage on your pins and current through the resistor using your multimeter?you wrote you declared your pins as outputs using pinMode(pinNumber, OUTPUT), right?if you got your atmegas blank from atmel, you might try to burn the bootloader again (or try another) and have look on the fuse settings if you don't use arduino to burn the bootloader. some pins have internal pull-up/down resistors. i'm no expert on that. but since there are different bootladers available, i can imagine these a reason for the lost power.

another reason might be some short circuit on your modified NG board. but since your writing it affects all boards...

do the pins behave the same trying one chip across different boards? this would hint at an defective atmega or wrong bootloader.

i hope you can track the problem down before ordering a new board. these things tend to happen again and again.