| ??? 02/18/03 21:49 Read: times |
#39390 - RE: calculating a delay ms and us Responding to: ???'s previous message |
If the compiler is smart, it will always give the BEST code, so there is no risk, if writing delay loops in C, independant of the type of the loop variable.
My µC/51 compiler, will use 'djnz', if the loop variable fits into 8 bit, and two nested 'djnz', if it fits in 16 bits, regardless if you count from -25 to +25 in steps of 5 or from 65000 to 10 step -1. Which compiler does this not? |
| Topic | Author | Date |
| calculating a delay ms and us | 01/01/70 00:00 | |
| RE: calculating a delay ms and us | 01/01/70 00:00 | |
| RE: calculating a delay ms and us | 01/01/70 00:00 | |
| RE: calculating a delay ms and us | 01/01/70 00:00 | |
| RE: calculating a delay ms and us | 01/01/70 00:00 | |
| RE: calculating a delay ms and us | 01/01/70 00:00 | |
| RE: calculating a delay ms and us | 01/01/70 00:00 | |
| RE: calculating a delay ms and us | 01/01/70 00:00 | |
| RE: calculating a delay ... addendum | 01/01/70 00:00 | |
RE: calculating a delay ... addendum | 01/01/70 00:00 |



