Faster Execution
Is there a way to execute this code faster?
The code executes four methods based upon a case statement. The repeat loop goes through an array list
PUB RunProgram | i
repeat
repeat i from 0 to numberOfCommands - 1
case functionCodes[i]
0:
LightsOff
1:
LightsOn
2:
SetBrightness(functionData[i])
3:
DelayMs(functionData[i])
[/i][/i][/i]
The code executes four methods based upon a case statement. The repeat loop goes through an array list
Comments
How big are the LightsOff, LightsOn, SetBrightness and DelayMs functions?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
http://www.propgfx.co.uk/forum/·home of the PropGFX Lite
·
Graham
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Composite NTSC sprite driver: Forum
NTSC & PAL driver templates: ObEx Forum
OnePinTVText driver: ObEx Forum
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔