#include <xc.h>
#include <sys/attribs.h>

int main(void)
{
    // Initialize peripherals
    InitializeSystem();

    // Interrupt Controller
    PRISS = 0x76543210;                /* assign shadow set #7-#1 to priority level #7-#1 ISRs */
    INCONSET = _INTCON_MVEC_MASK;    /* enable interrupt controller for multi-vector mode */
    __builtin_enable_interrupts();            /* atomic enable CP0 Status(IE) flag */

    while(1)
    {
        mainTasks();                /* main application loop */
    }
}