|
|
View previous topic :: View next topic |
Author |
Message |
linera
Joined: 23 Nov 2011 Posts: 6
|
Mouse Driver for ex_usb_mouse.c |
Posted: Tue Apr 02, 2013 4:50 am |
|
|
I am trying to simulate the ex_usb_mouse.c example using proteus.
The schematic that i am using is the "picdem fs usb.dsn" sample design available in PROTEUS USB examples.
For use this schematic I have done several changes to the ex_usb_common.h file.
Code: |
I defined a new profile #define USB_HW_MCHP_PIC18F4550
#if defined(USB_HW_CCS_PIC18F4550)
#include <18F4550.h>
#fuses HSPLL,NOWDT,NOPROTECT,NOLVP,NODEBUG,USBDIV,PLL5,CPUDIV1,VREGEN
#use delay(clock=48000000)
//leds ordered from bottom to top
#DEFINE LED1 PIN_A5 //green
#define LED2 PIN_B4 //yellow
#define LED3 PIN_B5 //red
#define BUTTON_PRESSED() !input(PIN_A4)
//see section below labeled USB_CABLE_IS_ATTACHED
#define PIN_USB_SENSE PIN_B2
#define HW_ADC_CONFIG ADC_CLOCK_INTERNAL
#define HW_ADC_CHANNEL 0
#define HW_ADC_PORTS AN0
#endif |
After several tries, I have discovered that I must change the Processor clock frequency to 2 MHz.
With this clock frequency, the messges in the RS-232 windows can be watched OK.
When I start the PROTEUS simulation, a virtual connection of the USB device to the PC is executed. The computer detects a new device connected in another device "unknown device", but i do not know which driver (.inf file) must i use to connect this device to my PC.
Someone can tell me where can i obtain the driver?
Thanks |
|
|
temtronic
Joined: 01 Jul 2010 Posts: 9243 Location: Greensville,Ontario
|
|
Posted: Tue Apr 02, 2013 5:38 am |
|
|
Please read PIC101 thread.
If you need a proteus driver, go to proteus.
This is NOT a forum for 'simulation', rather 'stimulation'!
Most here work in the real world, coding real PICs, doing real tasks!
Even the collective brains here haven't the time or energy to deug and repair proteus.It has far too many bugs,errors,faulty DRCs.
When you get a real PIC, cut some code , most here will eagerly help you
hth
jay |
|
|
linera
Joined: 23 Nov 2011 Posts: 6
|
|
Posted: Tue Apr 02, 2013 9:33 am |
|
|
Sorry, I have not read PIC101 thread.
I have not yet any real PIC to test it in the real world. This is the reason because I am trying to use PROTEUS in order to gain some advance.
I have installed the VIrtual USB drivers provided by proteus, but it does not work.
Moreover, I wrote a similar problem in Labcenter forums, but nobody answered yet. This is the reason because I put this new topic here.
The next time, I hope to put the new topic in the right forum.
Apologize me. |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|