Closed APBashara closed 5 days ago
Look at the Data watchpoint and trace timer
void delay_us(uint32_t us) {
uint32_t start = DWT->CYCCNT;
uint32_t cycles = us * (SystemCoreClock / 1000000);
while (DWT->CYCCNT - start < cycles);
}
May not really need this, any and all delays going forward should be non-blocking as we need to improve system performance
Will be used for timeout calculations and delays during setup