mikroC - C Compiler for Microchip PIC microcontrollers

//Timer 0 T0CON = 0x07;

TMR0H = (65536-156) >> 8; TMR0L = (65536-156) & 0xFF;

INTCON.T0IE = 1;

// Enable T0IE

T0CON.TMR0ON = 1;

 

}//~

 

/** Main Program Routine **/

void main() { Init_Main();

Hid_Enable(&userRD_buffer, &userWR_buffer);

do {

for (k = 0; k < 255; k++) {

//Prepare send buffer userWR_buffer[0] = k;

//Send the number via USB Hid_Write(&userWR_buffer, 1);

}

}while (1);

Hid_Disable();

}//~!

mikroC

making it simple...

page

 

278

MikroElektronika: Development tools - Books - Compilers