I am doing a Nordic project, that need to be a USB host. May I know how to make nRF52840 to be a USB host ?
I am doing a Nordic project, that need to be a USB host. May I know how to make nRF52840 to be a USB host ?
I have found that the nRF52840 is not capable of being a USB host, it's peripheral only. I've concluded that from this devzone post and this infocenter entry.
You can use a microcontroller with USB host functionality and another communication protocol compatible with the nRF52840 or a USB bridge IC. I'm doing the same thing at the moment using an SPI to USB bridge.
guys do you have tried the Vinculum-II? I also want to connect a nRF5840 to a CDC Modem using AT commands a give it cellular functionality. at the moment no luck to make work the Vinculum II
I have not.
I am using a MAX3421E, this does not have a programmable microcontroller though.
I have not.
I am using a MAX3421E, this does not have a programmable microcontroller though.
Thanks @KevinL I am going to give a look to that one :)
Hello KevinL,
Can you help us understand the settings that were done for MAX3421E to be configured for USB host? Does the SPI on Nordic have to configure the MAX3421E chip ? We are using the same but facing issues in interfacing it to Nordic. Thanks for the help.
Hi Akarsh,
I've been out of the project for over a year now, so don't have the specifics available anymore.
You indeed have to use the Nordic SPI to configure the MAX3421E. First set the SPI communication bits on the MAX. Then make sure you can read the revision number of you MAX to confirm SPI communication. After that you can set the HOST bit on the MAX. Specifics on how to program the chip can be found in the MAX3421E programming manual on the website of Maxim Integrated.
Back then I wrote my own code to use the MAX3421E, but after I was finished I found some open source code on github to do exactly that. You might be able to find it.
Good luck
Hi Kevin,
Thanks for the suggestions. It will be helpful reference if we can have a link where we can find the reference code.
Akarsh
Hello Akarsh,
If you search for "MAX3421E code" or "MAX3421E github" on google you will find multiple libraries. 2 examples:
https://github.com/felis/lightweight-usb-host
https://github.com/greiman/UsbFat/blob/master/USB_Host_Shield_2.0/max3421e.h
As for the SPI on the Nordic chip I will assume you're using SDK 16.0.0. This is the documentation for the example code for an SPI master:
Kevin