CCLib
CCLib copied to clipboard
Suggestion to change cc_delay to make it MCU speed agnostic
It seems like the cc_delay function is heavily dependent on MCU speed, thus the timing on the CC interface won't be valid for faster MCUs. I suggest to change the function to take the MCU speed into account or use Arduino delay functions.
Any input?
Good observation! I don´t think this really matters, the ccXXXX might already be fast enough for the pulses generated.
This worked for me though:
void cc_delay( uint16_t d )
{
delayMicroseconds( d);
}