calculating program segment execution speed?
Jed
Posts: 107
Is there a list of how many clock cycles each PBASIC command ends up taking? I'm trying to calculate the time it will take for a specific segment of code to execute. I know I can probably figure it out by trial and error but it would be nice if I could just calculate it somehow. Possible?
Comments
That said, if you are looking for some pretty good estimates on actual times for setting up and executing some common Pbasic commands, see Dr. Tracy Allen's notes on the subject here: emesystems.com/BS2speed.htm
I will also add as a matter of programming style, that while you can not achieve true time regularity like you could with an SX or the like, it does help to keep times more consistent by using structures that *always* evaluate in some fashion -- rather than IF/THEN and similar statements. Example:
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
When the going gets weird, the weird turn pro. -- HST
1uffakind.com/robots/povBitMapBuilder.php
1uffakind.com/robots/resistorLadder.php