Hi,
I've used this example of Keil: C:\Keil\ARM\Boards\Keil\MCB1700\RL\USB\Device\Memory_FlashFS I want (whenever I needed) be able to switch between two cases: 1)access to SD card via Micro (SPI) 2)access to SD card via PC (PC detects micro as mass storage device)
I've used a key for switch between cases +unfortunatly I had to plugin (the USB cable) again for reconfig it after a switch :( . my code is:
if(switchmode==0) { .... funinit(NULL); mc0 = ioc_getcb (NULL); if(ioc_init (mc0) == 0) { ioc_read_info (&info, mc0); usbd_init(); usbd_connect(__TRUE); while (!usbd_configured()); } } else { usbd_connect(__FALSE); ioc_uninit (mc0); finit(NULL); }
I know that I can't disconnect USB device by RL library.(if I can tell me how,please) Please guide me : how can I swith through firmware(not hardware)? (my microcontroller is NXP LPC1768)
View all questions in Keil forum