03-23-2011 04:52 AM
unsigned char readbuff[64] absolute 0x500; // Buffers should be in USB RAM, please consult datasheet
unsigned char writebuff[64] absolute 0x540;
char cnt;
char kk;
void interrupt(){
USB_Interrupt_Proc(); // USB servicing is done inside the interrupt
}
void main(void){
int i=0;
ADCON1 |= 0x0F; // Configure all ports with analog function as digital
CMCON |= 7; // Disable comparators
HID_Enable(&readbuff,&writebuff); // Enable HID communication
for(i=0;i<64;i++)
{
writebuff[i]=12;
}
writebuff[0] =243;
while(1){
while(!HID_Write(&writebuff,64));
delay_ms(1000);
}
}
i have error with Usb via Visa check sceenshot to see them
I used the usb example from Find Example LAbview
ftp://ftp.ni.com/pub/devzone/epd/usbrawcontrollv.zip
[URL=http://img508.imageshack.us/i/firstpicture.png/][IMG]http://img508.imageshack.us/img508/2889/firstpi...
[URL=http://img816.imageshack.us/i/picutre2.png/][IMG]http://img816.imageshack.us/img816/1572/picutre2.th...
03-23-2011 04:57 AM
03-23-2011 04:58 AM
03-23-2011 04:59 AM