Dieser Beitrag wurde bereits 2 mal editiert, zuletzt von »salocin_13« (7. Februar 2010, 18:56)

Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von »Jakob« (7. Februar 2010, 20:27)
|
|
Quellcode |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
$regfile = "attiny13.dat" Config Timer0 = Pwm , Pwm = 8 , Compare A Pwm = Clear Up , Compare B Pwm = Clear Down , Prescale = 1 Config Adc = Single , Prescaler = Auto Start Adc Enable Timer0 Dim Wert As Word Do Getadc(0) = Wert Wert = Wert / 4 Ocr0a = Wert Loop End |
Zitat
AVRASM: AVR macro assembler 2.1.42 (build 1796 Sep 15 2009 10:48:36)
Copyright (C) 1995-2009 ATMEL Corporation
C:\Franzis\LED2\LED2.asm(1): error: $regfile: Unknown instruction or macro
C:\Franzis\LED2\LED2.asm(1): error: syntax error, unexpected '='
Assembly failed, 2 errors, 0 warnings
|
|
Quellcode |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
$regfile = "attiny13.dat" $crystal = 9600000 Config Timer0 = Pwm , Pwn = 8 , Compare A Pwm = Clear Up , Compare B Pwm = Clear Up , Prescale = 8 Config Adc = Single , Prescaler = Auto Start Adc Enable Timer0 Dim Wert As Word Config Portb.0 = Output Do Wert = Getadc(2) Wert = Wert / 4 Ocr0a = Wert Loop End |

