Exemplo n.º 1
0
void OSD::reset(){
    max7456_on();

    byte cnt=15;

    while(cnt-- && !( MAX_read(MAX7456_STAT_reg_read) & 0x7) ) {//read status register - sync to soft-only versions
        byte j=3;

#ifdef SLAVE_BUILD
        while(j--)  osd_spi->transfer(0xff); // try to sync
#else
        while(j--)  SPI::transfer(0xff); // try to sync
#endif

        delay_15();
    }

    MAX_mode( MAX7456_RESET | video_mode );

    delay_15();

    hw_init();
}