In SX Microcontrollers, SX/B Compiler and SX-Key Tool, Zoot wrote: When using SX/B, and mixing SX/B and ASM, I want to setup my code so that the rate of the ISR is dependent on the freq setting. I don't want to use a lot of '{$IFDEF}s -- is this info aliased or set up as a constant by SX/B? The help file says that computed constants can not be used for ISR rates? I want to able to just change the freq. directive and have the change cascade throughout the code without adjusting other constants by hand. I.E., I would like to do something like: DEVICE OSCHS2 FREQ 20_000_000 and then later on in the program use something like IsrRate CON __freq / 4 INTERRUPT IsrRate and val1 = __freq * val2 and val1 = val2 / IsrRate etc. ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=232105 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)