~ruther/stm32h747i-disco-usb-image-viewer

ref: 8313b61dab467a7d9823e32aca9603f804ff3ca8 stm32h747i-disco-usb-image-viewer/src/delay.c -rw-r--r-- 304 bytes
8313b61d — Rutherther feat: implement fmc sdram control 4 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#include "delay.h"
#include <stm32h7xx.h>

uint32_t us_ticks;

void systick_configure() {
  SysTick->LOAD = SYSTICK_LOAD;
  SysTick->VAL = 0;
  SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_ENABLE_Msk; //| SysTick_CTRL_TICKINT_Msk;
  us_ticks = 0;
}

void systick_handler() {
  us_ticks++;
}
Do not follow this link