system
1
Arduino Duemilanove. I'm trying to init fast PWM on Pin 5 and 6.
ldi temp1, 0b_1010_0001
out TCCR0B, temp1
ldi temp1, 0b_0000_0011
out TCCR0A, temp1
ldi temp1, 0b_1000_0000
out OCR0A, temp1
out OCR0B, temp1
sbi DDRD, 5
sbi DDRD, 6
What can be wrong with my code? I have LOW on both Pins
Why not use C code? You gain nothing except obscurity doing it this way. The compiler will generate good code for you.
system
3
This is an education project. I'm studying atmel assembler.
I've written a lot of code for the Arduino, and I never use assembler (except for NOP in timing loops). But if you want to, fair enough.
ldi temp1, 0b_1010_0001
Do binary constants really have underscores in them?