ArvernOS
Loading...
Searching...
No Matches
bcm2835_timer.h File Reference
#include <stdint.h>
Include dependency graph for bcm2835_timer.h:

Functions

void bcm2835_timer_init (uintptr_t mmio_base, void(*callback)())
 
uint64_t bcm2835_timer_uptime_microseconds ()
 

Detailed Description

Function Documentation

◆ bcm2835_timer_init()

void bcm2835_timer_init ( uintptr_t mmio_base,
void(*)() callback )

Initializes the BCM2835 system timer (currently, only the timer 1).

Parameters
mmio_basethe MMIO base address to use to get access to the System Timer registers
callbacka function that gets called every time the timer fires an interrupt

◆ bcm2835_timer_uptime_microseconds()

uint64_t bcm2835_timer_uptime_microseconds ( )

Returns the timer uptime in microseconds.

Returns
the timer uptime in microseconds