PICcoder.co.uk Forum  


::post new topic::
C# PIC18F4550 USB demo does not work
Date: 2008/02/29 12:26 By: loco Status: User  
Karma: 0  
Posts: 4
graphgraph
Hi

I have downloaded the C# USB demo from:

http://www.piccoder.co.uk/content/view/42/26/

I have compiled the PIC18F4550 firmware using MPLAB and it went OK. I also installed the drivers on the PC.

The Led 1 and Led2 on the board go on and off, which is an indication that the connection is OK (according to the aticle). But nothing happens when I use the C# code. I click on Update Led with Led3/Led4 checked but still nothing happens.

Could someone give me some light here.

thanks!!!!
reply | quote

Re:C# PIC18F4550 USB demo does not work
Date: 2008/03/06 13:07 By: YTH Status: Visitor  
 
I am facing the same problem. Anyone has any idea? Thanks.
reply | quote

Re:C# PIC18F4550 USB demo does not work
Date: 2008/03/10 08:26 By: loco Status: User  
Karma: 0  
Posts: 4
graphgraph
No sorry, it was Microcosft problem for me.

I am using Vista and the program worked if I 'RUN AS ADMINISTRATOR'. I also need to change my Visual Studio to run in 'WIN XP Compatible mode' in order for the program to run from Visual Studio.

But the program runs perfectly without problems on XP. Its only with Vista where you must change some settings.

What version of operating system are you using???
reply | quote

Re:C# PIC18F4550 USB demo does not work
Date: 2008/03/14 19:13 By: Peter Neutelings Status: Visitor  
 
This is not a Microsoft problem:
The reason you need to be admin is that the function MPUSBIsVidPidEqual in the Microchip supplied dll opens the registry with an access mask KEY_ALL_ACCESS in the call to RegOpenKeyEx.
Replace KEY_ALL_ACCESS with the more modest access mask KEY_QUERY_VALUE, and recompile. Now you won't need admin rights anymore.
reply | quote

::post new topic::