In SX Microcontrollers, SX/B Compiler and SX-Key Tool, PJ Allen wrote: OK -- Yes, all you need is a resistor and an LED. This program works (the LED starts OFF and then gradually increases to full ON), I am watching it right before me -- [code] DEVICE sx28, oschs3, TURBO, OPTIONX IRC_CAL IRC_SLOW FREQ 75_000_000 PROGRAM Start duty var byte TRIS_A = $00 Start: DO FOR duty = 0 TO 255 ' sweep through angles PWM RA.0, duty, [color=red>50 ]speed of change[/color] NEXT LOOP I am using RA.0 for the output, and I am not using a capacitor or RC network at all (and I don't know why you are.) You will have to change the FREQ directive to match your time-base. [/code] ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=201629#m201861 Need assistance? Send an email to the Forum Administrator at forumadmin@parallax.com The Parallax Forums are powered by dotNetBB Forums, copyright 2002-2007 (http://www.dotNetBB.com)