Conquering the STM32F4 on the discovery board step-by-step. Commit history is tutorialesque, but not clean of course.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

41 lines
1.0 KiB

#ifndef INC_UTILS_H
#define INC_UTILS_H
// ----------------------------------------------------------------------------------------------
// C Interface
// ----------------------------------------------------------------------------------------------
#ifdef __cplusplus
extern "C" {
#endif
#include "stdint.h"
void heck_debug_suspend(void);
void heck_log(char* msg);
void assert_failed(uint8_t* file, uint32_t line);
void Error_Handler(void);
#ifdef __cplusplus
};
#endif
// ----------------------------------------------------------------------------------------------
// C++ Interface
// ----------------------------------------------------------------------------------------------
#ifdef __cplusplus
#include "types.hh"
#include <iostream>
#include <cstdint>
#include <string>
namespace Heck::Utils {
void debug_suspend_continue();
void log(std::string msg);
std::string reg_to_string(uint32_t val);
u32 random(u32 max);
} // namespace Heck::Utils
#endif
#endif /* INC_CPPMAIN_H */