| Andy Neil 02/18/09 11:30 Read: 2589 times Basingstoke Uk |
#162556 - It's IMPOSSIBLE - but here's how... Responding to: Erik Malund's previous message |
Erik Malund said:
you can NEVER predict the duration of a delay in 'C'. In fact, you can never predict the duration of any piece of high-level language (HLL) source code[1]. You can, of course, examine the generated machine code after compilation - but the effort is (far) more than just writing it in assembler in the first place! any change (related or not) to your code may change the delay true write it in assembler. exactly! And here's how: http://www.8052.com/forum/read/149030 See also: http://www.8052.com/forum/read/150987 and: http://www.8052.com/forum/read/98544 [1] Unless you have some explicit, compiler-specific extension; eg, the _nop_() "intrinsic" function in Keil. |
| Topic | Author | Date |
| Delay loop in C Programming | Harrison Cheung | 02/18/09 10:54 |
| you can't | Erik Malund | 02/18/09 10:59 |
| Timer ticks | Per Westermark | 02/18/09 11:28 |
| It's IMPOSSIBLE - but here's how... | Andy Neil | 02/18/09 11:30 |
You do not | Per Westermark | 03/24/09 03:35 |



