| ??? 04/05/02 18:22 Read: times |
#21467 - RE: Timing I2C bus with 8052 |
With NOP timing, I often insert a conditional e.g.
#define CLOCK_FREQUENCY_12M. Then in the code, if the originl code is for 12 MHz: #if CLOCK_FREQUENCY_12M ... NOP ... #else You must code here for the clock frequency #endif This works if the #define is in an obvious place and will lead the poor sod who has to change the code to all places where change is required, then you hope that (s)he will make it: #if CLOCK_FREQUENCY_12M ... NOP ... #else if CLOCK_FREQUENCY_18M ... #else You must code here for the clock frequency #endif Play it safe it is more fun, Erik |
| Topic | Author | Date |
| Timing I2C bus with 8052 | 01/01/70 00:00 | |
| RE: Timing I2C bus with 8052 | 01/01/70 00:00 | |
| RE: Timing I2C bus with 8052 | 01/01/70 00:00 | |
| RE: Timing I2C bus with 8052 | 01/01/70 00:00 | |
RE: Timing I2C bus with 8052 | 01/01/70 00:00 |



