Hi, I found a small bug in hal_delay_us. Once the timer is started it continues running beyond the first counting. If hal_delay is called again, after a complete counting, CPC flag is already set. My patch simply clears the status flags before initiate a new delay. Thanks Ezequiel