Numworks Epsilon
1.4.1
Graphing Calculator Operating System
log.cpp
Go to the documentation of this file.
1
#include <ion/log.h>
2
#include "
regs/itm.h
"
3
4
// We're printing using SWO.
5
// This is achieved by writing to the ITM register, which is sent through the
6
// Cortex Debug bus
7
8
void
ion_log_string
(
const
char
* message) {
9
char
character = 0;
10
while
((character = *message++) != 0) {
11
if
(
ITM
.
TER
()->
get
(0)) {
12
ITM
.
STIM
(0)->
set
(character);
13
}
14
}
15
}
ITM::TER::get
bool get(int index) volatile
Definition:
itm.h:16
ITM
Definition:
itm.h:8
ITM::TER
Definition:
itm.h:14
Register::set
void set(Register< T > value) volatile
Definition:
register.h:12
ion_log_string
void ion_log_string(const char *message)
Definition:
log.cpp:8
ITM::STIM
volatile STIM * STIM(int i) const
Definition:
itm.h:20
itm.h
epsilon
ion
src
device
log.cpp
Generated by
1.8.14