All pastes #681045 Raw Edit

Miscellany

public text v1 · immutable
#681045 ·published 2007-09-04 14:17 UTC
rendered paste body
void* main(void)
{
#ifndef SANSA_E200
    char buf[256];
    unsigned short* identify_info;
#endif
    int i = 0;
    int btn = 0;
    int rc;
    int num_partitions;
    struct partinfo* pinfo;
#ifdef SANSA_E200
    int usb_retry = 0;
    bool usb = false;
#endif
/*
    chksum_crc32gentab ();

    system_init();
    kernel_init();
    lcd_init();
    font_init();
    button_init();

    lcd_set_foreground(LCD_WHITE);
    lcd_set_background(LCD_BLACK);
    lcd_clear_display();
    lcd_update();
*/
    GPIOG_OUTPUT_EN |= 0x80;
    GPIOG_ENABLE = 0x80;
    while (1)
    {
        i++;
        if (i%10000 == 0)
            btn = ~btn;
        if (btn)
            GPIOG_OUTPUT_VAL &=~0x80;
        else 
            GPIOG_OUTPUT_VAL |=0x80;;
    }
    btn = button_read_device();
...