| August 8th, 2009 Ok, it's almost 5 am and I need to go to bed! I think I am finally starting to get how things work with AVR and kits. My first working code I got to work (without any walk through or tutorials) that blinks an LED every 100ms on a Atemega168 MCU on pin 26 (PC3):
The above code uses no libnerdkits include files supplied by the kit maker www.nerdkits.com, only includes provided by WinAVR/AVRdude. When I first got this kit about 60 hours ago, I thought I was only stuck using the files in libnerdkit which would limit the source codes and samples I could find on the internet, but thankfully I am not limited to only what NerdKits makes on the bootloader or with the include files. I was also falsely believing that these include files were on the MCU itself (but now realize these files are on my PC when I do the make command to compile). I guess I was assuming it was like PC where you can have different operating systems and I was thinking that NerdKit was some new unknown linux release but I was expecting Windows or something like that. Now I can understand better controling a simple on/off device. Next i will attempt to make it dim instead of flash on off, I'm assuming that has to do with pulse width modulation (PWM).Kind of like how you speed down/up and normal DC motor (usually goes almost full throttle). Then I will try a servo, 3V DC motor, and other parts that I have ordered. |
Free image widgets HERE.