Hat jemand eine Idee, die LED will uns verrecken nicht seine Helligkeit ändern;-((( Bin verzweifelt;-) An PB3 (PIN 17) hängt eine LED mit der Kathode, über 220 Ohm geht's an Plus. Fusebits sind auf internen Oszi eingestellt. 'PWM with output on the PB3(OC1) pin. $regfile = "m88def.dat" $crystal = 8000000 $hwstack=40 $swstack=16 $framesize=32 $crystal = 8000000 Config Portb.1 = Output Config Portb.2 = Output Config Timer1 = Pwm , Pwm = 10 , Compare A Pwm = Clear Down , Prescale = 1 Config Pinb.4 = Input Enable Interrupts Compare1a = 1023 Waitms 1000 Compare1a = 0 Waitms 1000 Do 'If Pinb.4 = 0 Then 'Capture1 = Capture1 + 10 'End If 'Compare1a = Capture1 Incr Compare1a Waitms 10 Loop End
Olivander schrieb: > Hat jemand eine Idee, > > die LED will uns verrecken nicht seine Helligkeit ändern;-((( > Starte mal den Timer. Kurt
Enable Timer1 ? Der Ausgang OC1A ist auf PINB.1, PIN 15.
:
Bearbeitet durch User
Bitte melde dich an um einen Beitrag zu schreiben. Anmeldung ist kostenlos und dauert nur eine Minute.
Bestehender Account
Schon ein Account bei Google/GoogleMail? Keine Anmeldung erforderlich!
Mit Google-Account einloggen
Mit Google-Account einloggen
Noch kein Account? Hier anmelden.