User avatar
marciokoko
Posts: 291
Joined: Sat Aug 27, 2016 4:33 pm

Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 12:15 am

Ive got this Tenda W311MI wifi-usb dongle. I bought it to get my rpi0 online. What I have is a rpi0 that came with a preloaded version of raspbian. I plugged it into a tv with the hdmi adapter and i got an install screen and let it run. The rpi0 came with a power plug and a usb-microUSB cable. So i can only use microUSB1 for power and microUSB2 for the microUSB-USB converter which I can use to plug in either mouse, keyboard or wifi-USB dongle.

I plugged in the dongle but there is no activity in the top right corner where the network interface icon is. I just get the 2 red x's. I check the network for any new devices and I get nothing I check the linksys router and I get nothing. So im pretty positive the usb isnt installed and working.

I did take a look at dmesg and I saw the whole history (cool) from the install of raspbian to the keyboard plug in by logitech. But I did see a bunch of stuff about an 802.11n adapter although the manufacturer was not ralink, but MediaLink.

In this page (http://elinux.org/RPi_USB_Wi-Fi_Adapters) it says the W311MI should not have a problem with it.

I even found a link where I should add the network={ ssid="myssid" psk="mypwd"} but after rebooting it doesnt work. Same as above.

What else can I try?

peterlite
Posts: 720
Joined: Sun Apr 17, 2016 4:00 am

Re: Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 12:46 am

Run lsusb and look for the ID of the dongle. Some USB device manufacturers change the chip every batch. A driver works with one chip but not the next. Google linux + chip id. What is the chip id?

The next problem can be power. Some USB devices chew up power when starting. Some wireless devices need extra power when transmitting. Let Raspbian start then plug in the device and look for the low power indicator on the screen.

If the device is really new, the driver might load but not work. You may need a later version of the driver.

User avatar
marciokoko
Posts: 291
Joined: Sat Aug 27, 2016 4:33 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 2:05 am

But how can i download stuff to it if I have no Internet?

User avatar
DougieLawson
Posts: 36312
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 4:04 am

marciokoko wrote:But how can i download stuff to it if I have no Internet?
Pull the SDCard, download with Windows, copy to first partition of the SDCard and you're good to go.
Run your RPiZ in USB OTG mode connected to your Windows laptop with a OTG cable.
https://gist.github.com/gbaman/50b6cca61dd1c3f88f41
You can then use Windows "Internet Connection Sharing" to get your RPi connected to the internet.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

User avatar
marciokoko
Posts: 291
Joined: Sat Aug 27, 2016 4:33 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 11:33 am

OK but I don't have a Windows machine, I have a Mac. Actually all computers in my office are mac.

I understand how to download stuff to an SD card but I don't know how to share the connection from my account to my rpi.

I just noticed that anytime i plug in the microUSB into the pi0, it reboots. Is that normal?

As for the git posted, is my understanding correct:

Method 1
A. My rpi0 came with raspbian on the SDcard so its already 'flashed' onto it.
B. Add "dtoverlay=dwc2" at the end of the config.txt file. Is that file visible in the sdcard just by plugging it into my laptop?
C. Create empty file called "ssh". Both steps B & C are done in the part of the sdcard where the img is, correct?
D. In the cmdline.txt file, add modules-load=dwc2,g_ether after rootwait.
E. Insert the sdcard into the rpi0 and connect the rpi0 to the laptop via USB and ssh into it.

Ok so this is going to let me run lsusb via ssh on my laptop while leaving the 2nd microUSB port for the wifi adapter. Once I get the id of the tenda, I can use it to find its drivers. But then I will have to download them to the sdcard because I still wont have internet on my pi0, right?

Im also emailing back and forth with Tenda support and they are sending me to the drivers page. Wouldnt that be the same thing?

drgeoff
Posts: 9886
Joined: Wed Jan 25, 2012 6:39 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 2:21 pm

marciokoko wrote: Ok so this is going to let me run lsusb via ssh on my laptop while leaving the 2nd microUSB port for the wifi adapter.
No.

The micro-USB port nearest the HDMI socket is the only one that you can communicate through using either a USB Wi-Fi adaptor or a USB ethernet adaptor or by putting the RPi0 into gadget mode. The other micro-USB socket is power only. Its other pins are not even connected to anywhere on the Zero. If you run a USB cable from it to a USB port on a computer you will never communicate through it by ssh or any other means.

User avatar
bensimmo
Posts: 4182
Joined: Sun Dec 28, 2014 3:02 pm
Location: East Yorkshire

Re: Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 2:25 pm

I don't understand.
You can use the Pi0 as is now and see it on a screen?
Ah missed the bit about no usb hub, so WiFi or keyboard not both.


Why not stick the WiFi dongle in the Mac and see what it says it is?
After all this is all just to see the chipset.
? https://apple.stackexchange.com/questio ... mmand-line ?
Alternative is boot with the WiFi in and have lsusb run from rc.local saving it's output to a file.
(yes switching the WiFi adaptor can make it reboot as it see the power surge, mine sometimes do that, even do it with hdmi connectors, they seem a bit fikkle)
Last edited by bensimmo on Thu May 18, 2017 7:54 pm, edited 1 time in total.

User avatar
marciokoko
Posts: 291
Joined: Sat Aug 27, 2016 4:33 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 3:06 pm

Im super confused now!

I know the first microUSB is for power, it says it on the pi0. Im using the other one, nearest the hdmi for dongle or keyboard which is uncomfortable.

Ok so but using this OTG cable gets plugged into the HDMI-near-microUSB. Great, now what are the 2 methods mentioned in the github for? The ones mentioned by DougieLawson? I dont have a windows machine, i have a mac.

User avatar
bensimmo
Posts: 4182
Joined: Sun Dec 28, 2014 3:02 pm
Location: East Yorkshire

Re: Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 7:51 pm

Follow the 'Fast' #1 method link.
That should get it setup working.

Just try it and see what happens.
Instructions are the same for Windows/Mac from a quick look through.

drgeoff
Posts: 9886
Joined: Wed Jan 25, 2012 6:39 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 8:46 pm

marciokoko wrote:The ones mentioned by DougieLawson? I dont have a windows machine, i have a mac.
Download needed files to your Mac. Put the micro-SD card into a USB card reader and plug into your Mac. The first partition on the card is FAT or FAT32 and will be available on the Mac. Copy the downloaded file(s) to the card. Also make the changes to the card to boot the Zero it into gadget mode ("USB ethernet") with ssh enabled. Put card into Zero. Connect Zero to Mac USB port. Do whatever a Mac needs (I haven't the foggiest) to connect over that USB cable. Run ssh on the Mac and log in to the Zero. Copy the downloaded file(s) from the /boot directory to wherever needed and use them.

User avatar
marciokoko
Posts: 291
Joined: Sat Aug 27, 2016 4:33 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Thu May 18, 2017 10:33 pm

So Got 3 different driver files which I got from a url provided by Tenda support but they failed to say which one. anyway I put them into the boot partition of my sd card:
Screen Shot 2017-05-18 at 4.00.10 PM.png
Screen Shot 2017-05-18 at 4.00.10 PM.png (46.62 KiB) Viewed 3213 times
I made the mods to config and cmdline txt files.

When I try to ssh by ssh [email protected] in terminal I get this:

Code: Select all

Marcios-MacBook-Air-2:GoogleHome quique123$ ssh [email protected]
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@       WARNING: POSSIBLE DNS SPOOFING DETECTED!          @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
The ECDSA host key for raspberrypi.local has changed,
and the key for the corresponding IP address fe80::bd57:mm18:5490:8264%en7
is unknown. This could either mean that
DNS SPOOFING is happening or the IP address for the host
and its host key have changed at the same time.
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@    WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!     @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that a host key has just been changed.
The fingerprint for the ECDSA key sent by the remote host is
SHA256:xeQH6SFYLEdya7PrfZXZXQrXuIeZ3qhUDzUbUGOIge4J0.
Please contact your system administrator.
Add correct host key in /Users/quique123/.ssh/known_hosts to get rid of this message.
Offending ECDSA key in /Users/quique123/.ssh/known_hosts:18
ECDSA host key for raspberrypi.local has changed and you have requested strict checking.
Host key verification failed.
Marcios-MacBook-Air-2:GoogleHome quique123$ 
Could it be because I use this mac to ssh into my other pi, a rpi2 which is connected to my home's wifi network?

How do I fix this?
Attachments
Screen Shot 2017-05-18 at 4.09.56 PM.png
Screen Shot 2017-05-18 at 4.09.56 PM.png (37.24 KiB) Viewed 3213 times

User avatar
bensimmo
Posts: 4182
Joined: Sun Dec 28, 2014 3:02 pm
Location: East Yorkshire

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 6:28 am

SSH key, just accept it (however you do that on your Mac).
It is probably because it is a new one etc.

The config.txt file.
I think it is saying there will not be any 'backup' of the file (guessing the Mac creates some for roll back to a previous version of the file, if you need it)
It's not an error. It is normal.
(Would be my opinion but I do not know OSX)

drgeoff
Posts: 9886
Joined: Wed Jan 25, 2012 6:39 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 7:56 am

bensimmo wrote:SSH key, just accept it (however you do that on your Mac).
It is probably because it is a new one etc.

The config.txt file.
I think it is saying there will not be any 'backup' of the file (guessing the Mac creates some for roll back to a previous version of the file, if you need it)
It's not an error. It is normal.
(Would be my opinion but I do not know OSX)
+1 to everything bensimmo said. Including the final sentence. :)

My Linux Mint is more friendly with the ssh warning. It shows me the entire command string I need to run verbatim to proceed.

tweak42
Posts: 500
Joined: Tue Mar 22, 2016 3:16 am
Location: Los Angeles, California

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 10:23 am

marciokoko wrote: When I try to ssh by ssh [email protected] in terminal I get this:

Code: Select all

Marcios-MacBook-Air-2:GoogleHome quique123$ ssh [email protected]

Could it be because I use this mac to ssh into my other pi, a rpi2 which is connected to my home's wifi network?

How do I fix this?[/quote]
This is because your pi2 and your pizero are using the same hostname and it's warning somethings fishy.
Since you have a pi2 it would be much easier/faster to swap in the pizero sd card update it, verify the W311MI wifi adapter works and setup the to join wifi network.  Then pop it into the pizero ready to connect.

I don't use MacOS but here is a guide where MacOS internet is shared to Pi Zero over usb.
https://stevegrunwell.com/blog/raspberry-pi-zero-share-internet/

I bought a few Tenda W311MI adapters 7 months ago, and lsusb:  [b]148f:7601 Ralink Technology, Corp. MT7601U[/b]
MT in the model name stands for MediaTek, but Ralink bought out MediaTek few years ago.  W311MI detected and worked right out of the box with the latest Raspbian then, so they should work with the current version now.  Any drivers the company sends you will likely be for older versions of linux kernel 3.xx series and/or for x86 processors.  Current Raspbian is using kernel 4.4 and MT7601U had complied in support in 4.2 and later.

User avatar
marciokoko
Posts: 291
Joined: Sat Aug 27, 2016 4:33 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 1:32 pm

ok I was able to log into my rpi0 via ssh by plugging it into my new macbook pro. I understand im supposed to accept the new key at the prompt back in my mba, but the problem was that even though the prompt did show up, it 'auto-answered' or whatever, and I was never able to enter yes or no to accept the key.

Anyway, Im here at the boot. I see 2 of the driver directories I copied over, 3.0.0.4 and 2.6.1.3 with a bunch of files inside. Im sorry but Im spoiled, Im used to exe and dmgs. How do I get my driver installed from the terminal?
Screenshot-2017-05-19-07.29.43.jpg

User avatar
bensimmo
Posts: 4182
Joined: Sun Dec 28, 2014 3:02 pm
Location: East Yorkshire

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 1:35 pm

No idea and just above there is a post saying they may not work as they are designed for an older system.


What is it being identified as ?
Really just need the 1234:5678 part of lsusb

User avatar
marciokoko
Posts: 291
Joined: Sat Aug 27, 2016 4:33 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 2:03 pm

how can i run lsusb if I cant get the wifi-usb into the pi0 because the dongle connecting it to my laptop is in there?

User avatar
bensimmo
Posts: 4182
Joined: Sun Dec 28, 2014 3:02 pm
Location: East Yorkshire

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 2:06 pm

What about your Pi2 or you Apple computer?
(Or taking the cover off the dongle)
Without knowing what you are installing for, how do you expect to install the driver?

User avatar
marciokoko
Posts: 291
Joined: Sat Aug 27, 2016 4:33 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 2:11 pm

Do i just pull the cover off? I plugged it into a usbc adapter and this is what shows up in the terminal:

Code: Select all

system_profiler SPUSBDataType
USB:

    USB 3.0 Bus:

      Host Controller Driver: AppleUSBXHCISPTLP
      PCI Device ID: 0x9d2f 
      PCI Revision ID: 0x0021 
      PCI Vendor ID: 0x8086 

        RNDIS/Ethernet Gadget:

          Product ID: 0xa4a2
          Vendor ID: 0x0525  (PLX Technology, Inc.)
          Version: 4.04
          Speed: Up to 12 Mb/sec
          Manufacturer: Linux 4.4.21+ with 20980000.usb
          Location ID: 0x14500000 / 4
          Current Available (mA): 500
          Current Required (mA): 2
          Extra Operating Current (mA): 0

        USB2.0 Hub:

          Product ID: 0x100f
          Vendor ID: 0x05ac  (Apple Inc.)
          Version: 45.28
          Speed: Up to 480 Mb/sec
          Manufacturer: Apple Inc.
          Location ID: 0x14400000 / 5
          Current Available (mA): 500
          Current Required (mA): 100
          Extra Operating Current (mA): 0

            USB-C Digital AV Multiport Adapter:

              Product ID: 0x1460
              Vendor ID: 0x05ac  (Apple Inc.)
              Version: 2.33
              Serial Number: DLC642300QEG2KQAB
              Speed: Up to 1.5 Mb/sec
              Manufacturer: Apple Inc.
              Location ID: 0x14420000 / 6
              Current Available (mA): 500
              Current Required (mA): 0
              Extra Operating Current (mA): 0

        iBridge:

          Product ID: 0x8600
          Vendor ID: 0x05ac  (Apple Inc.)
          Version: 1.01
          Speed: Up to 480 Mb/sec
          Manufacturer: Apple Inc.
          Location ID: 0x14100000 / 1
          Current Available (mA): 500
          Current Required (mA): 0
          Extra Operating Current (mA): 0
          Built-In: Yes

    USB 3.1 Bus:

      Host Controller Driver: AppleUSBXHCIAR
      PCI Device ID: 0x15d4 
      PCI Revision ID: 0x0002 
      PCI Vendor ID: 0x8086 
      Bus Number: 0x00 

    USB 3.1 Bus:

      Host Controller Driver: AppleUSBXHCIAR
      PCI Device ID: 0x15d4 
      PCI Revision ID: 0x0002 
      PCI Vendor ID: 0x8086 
      Bus Number: 0x01 

        USB3.0 Hub:

          Product ID: 0x100e
          Vendor ID: 0x05ac  (Apple Inc.)
          Version: 45.28
          Speed: Up to 5 Gb/sec
          Manufacturer: Apple Inc.
          Location ID: 0x01100000 / 1
          Current Available (mA): 900
          Current Required (mA): 144
          Extra Operating Current (mA): 0

User avatar
bensimmo
Posts: 4182
Joined: Sun Dec 28, 2014 3:02 pm
Location: East Yorkshire

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 3:19 pm

I think this is one of them WiFi where you just buy something that works out of the box.
From a search on the driver names you posted, look for MrEngmann but I think it's a faff to try to keep it up to date as they advance Raspian.
Buy something else and save your time and hassle.

drgeoff
Posts: 9886
Joined: Wed Jan 25, 2012 6:39 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 4:51 pm

Put the Tenda dongle into your RPi2 and run the lsb command there, either directly or from your Mac via ssh over Wi-Fi to other dongle already on the RPi2.

User avatar
marciokoko
Posts: 291
Joined: Sat Aug 27, 2016 4:33 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 5:57 pm

OK I just returned the Tenda single and they confirmed it wasn't working it seemed to be asleep because it wasn't recognized by any of their pcs either. They did something to it and it worked. But I went ahead and got a tp-link one anyway. It's a tl-wn725n. I plugged it into my pi0 at least a led blinks on this unit. However it wasn't recognized by the pi0 in the sense that I got connectivity. So I guess I'm better off but back to square one.

So now I have to move the drivers onto the pi0's SD card but how do I install them when I'm ssh'd onto my pi0?


User avatar
marciokoko
Posts: 291
Joined: Sat Aug 27, 2016 4:33 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 8:29 pm

Here is what shows up on both wifi-usb adapters (since both of them are showing up now):
IMG_2415b.jpg
IMG_2415b.jpg (17.54 KiB) Viewed 3047 times
and
IMG_2416b.jpg
IMG_2416b.jpg (25.06 KiB) Viewed 3047 times
where can I get the drivers for my kernel 4.4.21 #911?

drgeoff
Posts: 9886
Joined: Wed Jan 25, 2012 6:39 pm

Re: Raspberry Pi 0 without internet Tenda Dongle

Fri May 19, 2017 9:13 pm

You can make things much easier for yourself by putting the dongle and SD card into your RPi2. When you have dongle and RPi working there you can transfer both to the Zero where they will continue to work.

Return to “Beginners”