diff options
| author | sowgro <tpoke.ferrari@gmail.com> | 2025-11-05 22:56:07 -0500 |
|---|---|---|
| committer | sowgro <tpoke.ferrari@gmail.com> | 2025-11-05 22:56:07 -0500 |
| commit | 843e263ac896fae11b8c176810bab4866eb8b2a8 (patch) | |
| tree | abe5938c16b5537192edb989b189e4e1afd90a2e /project/Core/Src/System | |
| parent | e51714a66f5361c5f063f1395fdd441567932d19 (diff) | |
| download | 340-repo-Sowgro-843e263ac896fae11b8c176810bab4866eb8b2a8.tar.gz 340-repo-Sowgro-843e263ac896fae11b8c176810bab4866eb8b2a8.tar.bz2 340-repo-Sowgro-843e263ac896fae11b8c176810bab4866eb8b2a8.zip | |
begin logic for local control
Diffstat (limited to '')
| -rw-r--r-- | project/Core/Src/System/systick.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/project/Core/Src/System/systick.c b/project/Core/Src/System/systick.c index ac3a731..c18707e 100644 --- a/project/Core/Src/System/systick.c +++ b/project/Core/Src/System/systick.c @@ -23,6 +23,8 @@ void init_systick() s->CSR |= 1; } + + // This fuction is to create delay using SysTick timer counter void delay_systick() { @@ -54,3 +56,12 @@ int check_systick() { return 0; } } + +static uint32_t count = 0; +void SysTick_Handler() { + SysTick_Handler2(count++); +} + +uint32_t systick_get_count() { + return count; +} |
