window 10 does not recognise USB

General discussion on mikroPascal PRO for PIC32.
Author
Message
tormod
Posts: 57
Joined: 29 Nov 2004 16:31

window 10 does not recognise USB

#1 Post by tormod » 27 Dec 2017 10:44

Tried to establish an usb hid connection between mikro-media pic32 and windows 10, but window 10 rejects connection ," a request for USB device descriptor failed". Tried the supplied example on two computers, what need to be fixed and how?

User avatar
strahinja.jacimovic
mikroElektronika team
Posts: 200
Joined: 18 Dec 2017 18:19

Re: window 10 does not recognise USB

#2 Post by strahinja.jacimovic » 28 Dec 2017 10:42

Hi,

This usually occurs due to the wrong drivers or hardware malfunction.

The error can be caused by hardware issues. So first, follow the simple instructions below to do the troubleshooting.

1. Try the device on a different USB port. This will figure out if problem is caused by a broken port.

2. Connect the device to another PC. This will figure out if the external device has problem.

If you did 1 and 2 and you still get the same error, then it's hardware related. If not, do the methods explained below.

Method 1: Remove the Power Supply
This method will fix the problem magically if the problem is caused by Power Supply.

1. Remove the Power Supply plug from PC.

2. Restart the PC and connect the device to the USB port.

3. After that, plug in the Power Supply.

Method 2: Uninstall the USB Driver in Device Manager
Follow these steps:

1. Open Device Manager(click windows button and type device manager) and expand category Universal Serial Bus Controllers and locate the USB device which is not being recognized by Windows.

2. Right-click on the device and select Uninstall from the context menu.

3. After finishing the uninstall, restart your PC and Windows will reinstall the device automatically.

Method 3 : Update the USB Driver
The problem can be caused by faulty USB driver. In this case, updating driver should fix the problem.

Method 4: Disable Fast Startup
If Windows is booting quickly, the external device may not be detected before the boot is completed, then the problem will occur. In this case, disabling the fast boot option in Power Options can resolve the problem.

1. Press Win+R (Windows logo key and R key) at the same time. A Run dialog box will appear.

2. Type control in the run box and click OK button. This will open Control Panel.

3. View by Large Icons and click on Power Options.

4. Select Choose what the power buttons do in left pane.

5. Click on Change settings that are currently unavailable.

6. Under Shutdown settings, uncheck the box next to Turn on fast startup (recommended). Then click on Save changes button.

7. Restart your PC and see if the problem resolves. Note that your PC will boot a little slower.

Method 5: Change the USB Selective Suspend Settings
Follow these steps:

1. In Power Options, click on Show additional plans. (If you tried Method 2, you must know how to go to Power Options. If not, go back to Method 2 and refer the steps to open Power Options.)

2. Click Change settings that are currently unavailable.

3. Select High performance and click on Change plan settings.

4. Click on Change advanced power settings.

5. Click on Change settings that are currently unavailable.

6. Locate USB settings and expand it.

7. Expand USB selective suspend setting. Disable both On battery and Plugged in settings.

8. Click Apply button and restart your computer.

After using methods in this post, you must resolve the Device Descriptor Request Failed error for Windows 10.

I hope this helps.

Kind regards,
Strahinja Jacimovic

tormod
Posts: 57
Joined: 29 Nov 2004 16:31

Re: window 10 does not recognise USB

#3 Post by tormod » 28 Dec 2017 20:59

Thank you for your answer, I tried the most of solutions on several PC's even a XP-pc without success and with the same response, is it the unit itself that has a problem. I have been using it for a substancial large project without problem. I tried a clicker 2 for 32mx, and the USB connection came up as it should, and it was possible to communicate in both directions, so the hard conclusion is:
there must be something wrong with the mikromedia for PIC32mx. Is there any way to get this checked or do I have to buy a new one?

Tormod S

User avatar
strahinja.jacimovic
mikroElektronika team
Posts: 200
Joined: 18 Dec 2017 18:19

Re: window 10 does not recognise USB

#4 Post by strahinja.jacimovic » 29 Dec 2017 11:49

Hi,

I think it's a problem regarding the bootloader on your board.

I would recommend to try programming it with a programmer. You can use our programmer: https://www.mikroe.com/mikroprog-pic-dspic-pic32
Or you can use any Microchip programmer.

If you don't have one, maybe someone you know does. Borrow it.

Download the hex file for programming here: https://download.mikroe.com/setups/addi ... t-v210.zip

And use the programmer to load and then write the hex file to the board.
The hex code works on any mikromedia PIC32 board.

Try this if you can and we'll go from there.

Kind regards.
Strahinja Jacimovic

tormod
Posts: 57
Joined: 29 Nov 2004 16:31

Re: window 10 does not recognise USB

#5 Post by tormod » 30 Dec 2017 14:53

Now I am a little bit confused, I never used the built in boot loader always the micro programmer. I checked the file given and found firmvare for the boot loader in hex. Do you mean I should install this at the card, and initially this was the cause of problem ? This I can do, but since I never use it why bother with it. By the way trying the bootloader, it neither could connect to the unit becuase that it could not find it

tormod S

User avatar
strahinja.jacimovic
mikroElektronika team
Posts: 200
Joined: 18 Dec 2017 18:19

Re: window 10 does not recognise USB

#6 Post by strahinja.jacimovic » 03 Jan 2018 12:00

Hi,

So when you connect it and open our Software, it doesn't even see you mikromedia?

I'll have to investigate this further.

Kind regards,
Strahinja Jacimovic

tormod
Posts: 57
Joined: 29 Nov 2004 16:31

Re: window 10 does not recognise USB

#7 Post by tormod » 04 Jan 2018 11:13

Neither HID terminal nor bootloader detect the unit. I have a clicker 2 with same processor, it works Ok with the HID terminal, the bootloader will not detect it -also this unit programmed with micro programmer. For back-up purposes I have got a brand new unit, which should work with bootloader, I can aslo try to run the example program and se if the HID terminal will get connected.

By the way, I bought the newest USART click board and I need to manage the CTS/RTS pins, do you have an example or some code how to do this

tormod

User avatar
strahinja.jacimovic
mikroElektronika team
Posts: 200
Joined: 18 Dec 2017 18:19

Re: window 10 does not recognise USB

#8 Post by strahinja.jacimovic » 04 Jan 2018 11:47

Hi,

I'm not sure what you exactly mean by that, but this is how to properly connect them:

RTS is output
CTS is input
RxD is input
TxD is Output

Is must be crossed over just like RxD and TxD...

DeviceA DeviceB
--------- ----------
RxD (Pin2)<--------------TxD(Pin3)
TxD (Pin3)-------------->RxD(Pin2)
RTS (Pin7)-------------->CTS(Pin8)
CTS (Pin8)<--------------RTS(Pin7)

The pinout's are just for this example.

Is this what you meant?

Kind regards,
Strahinja Jacimovic

tormod
Posts: 57
Joined: 29 Nov 2004 16:31

Re: window 10 does not recognise USB

#9 Post by tormod » 04 Jan 2018 13:42

Skjermbilde.PNG
Skjermbilde.PNG (53.23 KiB) Viewed 6362 times
Sorry I did not mention that the clickboard was USART on USB, and the newest card has pinout for RTS/CTS on the mikrobus and I am looking for software to manage these two pins, I do not need any explanation on what CTS/RTS is. The MX32 processor itself has pinouts for CTS/RTS which could be manipulated, but I guess that these pins does not apply to the same two pins in the mikrobus pinout.

https://www.mikroe.com/usb-uart-4-click

User avatar
strahinja.jacimovic
mikroElektronika team
Posts: 200
Joined: 18 Dec 2017 18:19

Re: window 10 does not recognise USB

#10 Post by strahinja.jacimovic » 04 Jan 2018 13:48

Hi,

I see what you mean.

The connections on mikroBUS are GPIO, meaning general purpose input/output.

You can define them any way you want to.

Kind regards,
Strahinja Jacimovic

tormod
Posts: 57
Joined: 29 Nov 2004 16:31

Re: window 10 does not recognise USB

#11 Post by tormod » 07 Jan 2018 23:39

Now I have tried a brand new mikromedia for pic32mx with the same sad result, tested first bootloader and it detected the unit, next loded the example software for USB via micro programmer and neither window, nor USB terminal analyser or HID terminal detects it now tried on two PC -so what is wrong?



tormod

User avatar
strahinja.jacimovic
mikroElektronika team
Posts: 200
Joined: 18 Dec 2017 18:19

Re: window 10 does not recognise USB

#12 Post by strahinja.jacimovic » 08 Jan 2018 17:42

Hi,

Have you maybe overwritten the boot loader with another .hex file?

If you have, then download the default firmware for it from this link:
https://download.mikroe.com/setups/addi ... t-v210.zip

It's in the folder firmware.

Program it to your mikromedia, then come back and tell me if your PC sees your mikromedia device or not and we'll go from there.

Kind regards,
Strahinja Jacimovic

tormod
Posts: 57
Joined: 29 Nov 2004 16:31

Re: window 10 does not recognise USB

#13 Post by tormod » 11 Jan 2018 12:34

You had right, it was the missing bootloader that caused the problem, but during this tests I discovered some pecularities that need to be fixed or worked around. First of all you need the micro programmer to load the bootloader so you are 100% dependent on this. To use this it is natural to start the compiler and find the mikro programmer under Tools - and what do you see, it is blocked until you open a random project!!! of which points to a hex file you are not going to use and when you are able to open it it starts erasing the chip every time!!! All this should be controlable by the user. After been through this you can load the bootloader.

Tried so to load the example program with the boot loader, and it works fine with sending/receiving USB messages with your HID terminal. Trying to load the same software with the micro programmer (compiled by the compiler) and I am back where I started, USB not recognised - so the micro programmer again has erased the boot loader, so my question is:
Is there any setting of the microprogrammer to avoid this happening since I want to continue using this rather than the boot loader

tormod

User avatar
strahinja.jacimovic
mikroElektronika team
Posts: 200
Joined: 18 Dec 2017 18:19

Re: window 10 does not recognise USB

#14 Post by strahinja.jacimovic » 11 Jan 2018 18:18

Hi,

That is quite unfortunate, yes, but however, when you write a program to your mikromedia you have to know that it takes 3 things into consideration.

Boot loader, Flash memory, Reset vector.

The reset vector tells the programmer to load the program in the flash memory from a certain position. Now if the code is too big, sometimes it writes over the boot loader part as well.

That's why you lose the bootloader on your device.

Kind regards,
Strahinja Jacimovic

tormod
Posts: 57
Joined: 29 Nov 2004 16:31

Re: window 10 does not recognise USB

#15 Post by tormod » 12 Jan 2018 12:24

What is big software, the only application I try to load is the simple USB application found on your site and still it overwrites the flash memory, so occasionally it does this and occasionally it does that is not an answer. My own software does not use more than 12% of ROM, so ther shoud be plenty of space. I have not any use for the boot loader but I need USB communication.

To conclude as you do is not good enough, with all respect I expect a solution!!

Post Reply

Return to “mikroPascal PRO for PIC32 General”