public static void CHECK_IRQ2() {
        if ((m6800.irq2 & (TCSR_ICF | TCSR_OCF | TCSR_TOF)) != 0) {
            if ((m6800.irq2 & TCSR_ICF) != 0) {
                TAKE_ICI();
                if (m6800.irq_callback != null) {
                    m6800.irq_callback.handler(M6800_TIN_LINE);
                }
            } else if ((m6800.irq2 & TCSR_OCF) != 0) {
                TAKE_OCI();
            } else if ((m6800.irq2 & TCSR_TOF) != 0) {
                TAKE_TOI();
            }
        }
    }