Fixed MCU events (thanks to @SonoSooS).
This commit is contained in:
parent
e70f80d408
commit
4b7fe6adf0
|
@ -130,7 +130,7 @@ void LGYFB_init(void)
|
|||
|
||||
/*
|
||||
* Limitations:
|
||||
* First pattern bit must be 1 and last 0 or it loses sync with the DS/GBA input.
|
||||
* First pattern bit must be 1 and last 0 (for V-scale) or it loses sync with the DS/GBA input.
|
||||
*
|
||||
* Matrix ranges:
|
||||
* in[-3] -1024-1023 (0xFC00-0x03FF)
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
|
||||
|
||||
static bool g_mcuIrq = false;
|
||||
static u32 g_events = 0;
|
||||
static u32 g_mcuEvents = 0;
|
||||
|
||||
|
||||
|
||||
|
@ -80,7 +80,7 @@ bool MCU_setEventMask(u32 mask)
|
|||
|
||||
u32 MCU_getEvents(u32 mask)
|
||||
{
|
||||
u32 events = g_events;
|
||||
u32 events = g_mcuEvents;
|
||||
|
||||
if(atomic_load_explicit(&g_mcuIrq, memory_order_relaxed))
|
||||
{
|
||||
|
@ -92,7 +92,7 @@ u32 MCU_getEvents(u32 mask)
|
|||
events |= data;
|
||||
}
|
||||
|
||||
g_mcuIrq = events & ~mask;
|
||||
g_mcuEvents = events & ~mask;
|
||||
|
||||
return events & mask;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue