Go to the documentation of this file.
10 #define _PCE_SYSTEM_H_
23 #define NTSC_COLORBURST_FREQ (315 * 1000000 / 88)
24 #define PCE_SYSTEM_FREQ (NTSC_COLORBURST_FREQ * 6)
25 #define PCE_CPU_FREQ (NTSC_COLORBURST_FREQ * 2)
26 #define PCE_TIMER_FREQ (PCE_CPU_FREQ / 1024)
48 #define PCE_FREQ_TO_TIMER(freq) ((PCE_TIMER_FREQ / (freq)) - 1)
75 static inline void pce_cpu_irq_enable() {
76 __attribute__((leaf))
asm volatile(
"cli\n");
82 static inline void pce_cpu_irq_disable() {
83 __attribute__((leaf))
asm volatile(
"sei\n");
void pce_irq_enable(uint8_t mask)
Enable the specified IRQs.
void pce_irq_disable(uint8_t mask)
Disable the specified IRQs.
::uint8_t uint8_t
Definition: cstdint:21
const void uint16_t count
Definition: memory.h:58
void pce_timer_disable(void)
Disable the timer.
void pce_timer_enable(void)
Enable the timer.
void pce_timer_set(uint8_t count)
Initialize the timer with a given reload value.