Silencing errors

This commit is contained in:
Imbus 2025-07-16 15:51:28 +02:00
parent 8636fedb5a
commit bdfcef687a
7 changed files with 12 additions and 5 deletions

View file

@ -1,8 +1,8 @@
PROJECT := main PROJECT := main
BUILD_DIR := bin BUILD_DIR := bin
CFILES := main.c system.c # CFILES := main.c system.c
# CFILES += $(wildcard *.c) CFILES += $(wildcard *.c)
OPENCM3_DIR := ./libopencm3 OPENCM3_DIR := ./libopencm3
# Check if libopencm3 is available before including anything # Check if libopencm3 is available before including anything

View file

@ -9,7 +9,7 @@ static uint8_t seed[32];
static uint8_t signature[64]; static uint8_t signature[64];
void crypto(void) { void crypto_demo(void) {
crypto_eddsa_key_pair(sk, pk, seed); crypto_eddsa_key_pair(sk, pk, seed);
char *msg = "Hello\n"; char *msg = "Hello\n";

View file

@ -1 +1,3 @@
#pragma once #pragma once
void crypto_demo(void);

View file

@ -4,6 +4,7 @@
volatile uint64_t ticks; volatile uint64_t ticks;
__attribute__((interrupt)) void sys_tick_handler(void);
void sys_tick_handler(void) { ticks++; } void sys_tick_handler(void) { ticks++; }
uint64_t sys_ticks_get(void) { return ticks; } uint64_t sys_ticks_get(void) { return ticks; }

View file

@ -1,7 +1,7 @@
#pragma once #pragma once
#include <stdint.h> #include <stdint.h>
void sys_tick_handler(void); // void sys_tick_handler(void);
uint64_t sys_get_ticks(void); uint64_t sys_get_ticks(void);
void sys_tick_setup(void); void sys_tick_setup(void);
uint64_t sys_ticks_get(void); uint64_t sys_ticks_get(void);

3
uart.c
View file

@ -1,8 +1,9 @@
#include <libopencm3/stm32/usart.h> #include <libopencm3/stm32/usart.h>
#include <libopencm3/stm32/rcc.h> #include <libopencm3/stm32/rcc.h>
#include <libopencm3/stm32/gpio.h> #include <libopencm3/stm32/gpio.h>
#include "uart.h"
static void usart_setup(void) { void usart_setup(void) {
rcc_periph_clock_enable(RCC_GPIOA); rcc_periph_clock_enable(RCC_GPIOA);
rcc_periph_clock_enable(RCC_USART1); rcc_periph_clock_enable(RCC_USART1);

3
uart.h Normal file
View file

@ -0,0 +1,3 @@
#pragma once
void usart_setup(void);