View Single Post
Old 12-22-2008, 04:41 PM   #30 (permalink)
MPaulHolmes
PaulH
 
MPaulHolmes's Avatar
 
Join Date: Feb 2008
Location: Maricopa, AZ (sort of. Actually outside of town)
Posts: 3,832

Michael's Electric Beetle - '71 Volkswagen Superbeetle 500000
Thanks: 1,362
Thanked 1,202 Times in 765 Posts
Program with step by step instructions

Hello! OK, so I have carefully tested the small controller, and watched the results on the oscilloscope. Finally, the software appears to be without any errors, and is much simpler and easier to read now. I think I'll run the bike controller at 4kHz. It may irritate dogs in the neighborhood, but it will keep switching losses down, and it's just a first draft. Well, second draft if you count the 5v 0.01amp one.

To compile this program, download the FREE Atmel AVR Studio!
Atmel AVR Studio


To compile the program, change the file name to end with .c instead of .txt

It wouldn't let me upload it here unless it was in ".txt" format.

There are a lot of page references in PWMAndInputTest.txt. They refer to the PDF of the documentation for the ATMega8. It can be found HERE!
Also, the code assumes you are using the PDIP version of the chip (28 pin version).
Attached Files
File Type: txt PWMAndInputTest.txt (4.8 KB, 936 views)
__________________
kits and boards

Last edited by MPaulHolmes; 12-23-2008 at 12:13 AM..
  Reply With Quote
The Following User Says Thank You to MPaulHolmes For This Useful Post:
faerietree (07-14-2012)