In SX Microcontrollers, SX/B Compiler and SX-Key Tool, bean wrote: This is dead easy with SX/B. [code] DEVICE SX28, OSCXT2, TURBO, OPTIONX, STACKX FREQ 5_120_000 OutPin VAR RC.4 INTERRUPT NOCODE OutPin = ~OutPin ' Toggle state of output pin RETURNINT 64 ' Repeat every 64 clocks ([url=80KHz@5.12MHz]80KHz @ 5.12MHz[/url]) PROGRAM Start NOSTARTUP Start: OUTPUT OutPin ' Set pin as output OPTION = $88 ' Setup RTCC interrupts with no pre-scaler END [/code] Bean. ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=107862#m108409 Need assistance? Send an email to the Forum Administrator at forumadmin@parallax.com The Parallax Forums are powered by dotNetBB Forums, copyright 2002-2006 (http://www.dotNetBB.com)