Author Topic: [ARM] Does a USB device need a driver on the Host Microcontroller to get power?  (Read 1038 times)

0 Members and 1 Guest are viewing this topic.

Offline robotwizardTopic starter

  • Newbie
  • Posts: 8
  • Country: in
    I've recently transitioned from arduinoes to ARM devices[Noob Alert]. I'm trying to make a maze solving robot - 'micromouse' and I'm trying to use an optical mouse's sensors to track the movement of the robot on the maze floor.

    So I got this free NXP development board from Hackster - a FRDM-K82F board; This Board has USB support. So I saw the USB demo drivers and they're fairly complicated and add to that my puny knowledge of the USB stack - So I decided I would setup the hardware first; so I'm making a prototype and I connected two optical mice to a USB hub and tried connecting it to the USB port on the microcontroller via a cheap micro USB cable. Before powering the microcontroller up, I read in the documentation that there is a jumper in the FRDM-K82F that is supposed to be 'jumped' to give power to the USB port and allow the board to act as a USB hub. I connected the jumper properly.

    Now to check if the hardware is working properly, I connected the optical mouse + hub setup to my laptop computer and the laptop is reading both the mice. But when I connect the hub to the microcontroller and power the microcontroller, The light on the USB hub doesn't light up; neither does the light on the optical mouse.

    So this is my noob question - Does a USB host need to be running driver code for it to supply power to the devices? Or could there be something else wrong with my setup. Will I have to write the driver code before plugging in the optical mouse setup?

Also it would be nice if someone could direct me to a nice tutorial other than the documentation on setting up USB devices on NXP or ARM cortex M4 devices.

This is the link for the Development Board I have.
https://www.nxp.com/products/processors-and-microcontrollers/arm-based-processors-and-mcus/kinetis-cortex-m-mcus/k-seriesperformancem4/k8x-secure/freedom-development-platform-for-kinetis-k82-k81-and-k80-mcus:FRDM-K82F?&&tab=In-Depth_Tab

I've also attached the Datasheet for the Board.

Please tell me if you need more information. Thanks for your time!
 

Offline GeorgeOfTheJungle

  • Super Contributor
  • ***
  • !
  • Posts: 2699
  • Country: tr
As far as I know a USB 1 or 2 (and 3 too?) host should provide up to 500 mA @5v even when/if there's nothing connected to the data+ and data- pins.
The further a society drifts from truth, the more it will hate those who speak it.
 
The following users thanked this post: robotwizard

Offline GeorgeOfTheJungle

  • Super Contributor
  • ***
  • !
  • Posts: 2699
  • Country: tr
OTOH, it may well be that your mouse won't lit its led until after it has negotiated properly with the host, you know, the enumeration phase and all that jazz.
The further a society drifts from truth, the more it will hate those who speak it.
 

Offline robotwizardTopic starter

  • Newbie
  • Posts: 8
  • Country: in
Yes that is what I was wondering about.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf