Forum Index > Projects > Micro-readerboard project support
 Dev Board Help! Simple Circuit
 |  Printable Version
By: Anonymous: JRH53 () on Sunday, December 20 2009 @ 12:23 PM PST (Read 7317 times)  
Anonymous: JRH53

I recently purchased a Dev. Board and built the simple LED blink circuit Adafruit provided as an example on there website. I have the Dev board being powered by the programmer which is a USBTinyISP from Adafruit and the LED does not blink. I'm just starting out with programming microcontrollers so my skill level is just a beginner. The example code is pasted below. The LED is oriented correctly, I applied an external 5V across the resistor and LED and it lights up. Please help, seems like a simple problem!

PHP Formatted Code

#define F_CPU 1000000  // by default we have the 1MHz internal oscillator

#include <avr/io.h>      // this contains all the IO port definitions
#include <util/delay.h>

int main(void) {
  DDRB = (1 << 5);  // set PORTB5 to an output

  while (1) {
    PORTB |= 1 << 5;  // turn LED on
    _delay_ms(100);
    PORTB &= ~(1 << 5);  // turn LED on
    _delay_ms(100);
  }
}
 






       
   
By: Windell (offline) on Sunday, December 20 2009 @ 12:55 PM PST  
Windell

Maybe better to post a smaller photo next time. Eek!

Your code is fine, so the problem must be elsewhere.

What makefile are you using-- are you sure that the fuses were set correctly to give a 1 MHz clock rate?
Are you certain that the chip was actually programmed?

Also, check your solder joints.


Windell H. Oskay
drwho(at)evilmadscientist.com
http://www.evilmadscientist.com/

Forum Evil Scientist
Evil Scientist

Status: offline

Registered: 06/15/06
Posts: 1932
Sunnyvale, CA

Profile Email Website  
   
By: Anonymous: JRH53 () on Sunday, December 20 2009 @ 01:15 PM PST  
Anonymous: JRH53

I'm using the example code from Adafruit http://www.ladyada.net/learn/avr/atmega8-1mhz-blink.zip

It includes the Make, C and Hex file.

I programmed it using the USBTiny and AVRdude and it programs successfully. I'm powering the Dev board by leaving the USBtiny programmer hooked up to the board. I verified it has 5V power using a multimeter.





       
   
By: Windell (offline) on Sunday, December 20 2009 @ 01:22 PM PST  
Windell

I've tried your circuit and it works, along with your code. So, either you aren't programming the chip like you think you are, or the circuit isn't hooked up how you think it is. I suspect the latter. If you have a multimeter, you could use that to verify the connections. Otherwise, solder an LED to a resistor, and touch one pin to the pin of your chip and the other to ground.


Windell H. Oskay
drwho(at)evilmadscientist.com
http://www.evilmadscientist.com/

Forum Evil Scientist
Evil Scientist

Status: offline

Registered: 06/15/06
Posts: 1932
Sunnyvale, CA

Profile Email Website  
   
By: Anonymous: JRH53 () on Sunday, December 20 2009 @ 02:25 PM PST  
Anonymous: JRH53

Ok, does this screenshot look correct for the programming?






       
   
By: Windell (offline) on Sunday, December 20 2009 @ 02:51 PM PST  
Windell

Hmm. I got "206 bytes of flash verified."


Windell H. Oskay
drwho(at)evilmadscientist.com
http://www.evilmadscientist.com/

Forum Evil Scientist
Evil Scientist

Status: offline

Registered: 06/15/06
Posts: 1932
Sunnyvale, CA

Profile Email Website  
   
By: xDGx (offline) on Friday, April 15 2011 @ 11:12 AM PDT  
xDGx

Hey, I bought that exact kit from adafruit. I have the target board and usbtinyisp ready and working, even got the blinking code to work (btw I got "174 bytes of flash verified"Wink. I hooked the GND and VCC on the target board (the ones around the printed SQUARES, top left of board) to power.


Forum Scientist
Scientist


Status: offline

Registered: 08/18/09
Posts: 41

Profile Email    
   



 All times are PDT. The time is now 09:37 PM.
Normal Topic Normal Topic
Locked Topic Locked Topic
Sticky Topic Sticky Topic
New Post New Post
Sticky Topic W/ New Post Sticky Topic W/ New Post
Locked Topic W/ New Post Locked Topic W/ New Post
View Anonymous Posts 
Able to Post 
Filtered HTML Allowed 
Censored Content 

Evil Mad Scientist Forum Archives — Read only!

Please visit our new forums for new discussions.


DIY Hardware for Electronic Art


The Original Egg-Bot Kit


Octolively
Interactive LED kits


Meggy Jr RGB
LED matrix game
development kit.


Business-card sized
AVR target boards


Peggy 2
LED Pegboard kits

My Account






Lost your password?