# RTL8187B USB Wireless Problem



## Fotis (Jun 27, 2015)

Hi guys. First of all I am new to FreeBSD. I made an install _of_ FreeBSD 10.1 _on_ my pc and I'm st_u_ck because I can't set _up_ my internet. I got this error:


```
urtw0<vendor 0x0bda product 0x8187,class 0/0,rev 2.00/2.00 addr 4>on usbus0
urtw0:could not allocate usb transfers,err=USB_ERR_NO_PIPE
device attach:urtw0 attached returned 6.
```

It is about a_n_ AirData 54USB Crypto...Chinese adapter

Does anyone knows what this means? And what can I do?
Thanks a lot...


----------



## romanaOne (Jun 28, 2015)

I don't know what the error means, but you could try using ndisgen() to convert the Windows driver into a module for the card.

I got strange errors with my $5 Broadcom BCM4322 and it was easier to set up ndis instead of the native drivers which I think do not support this card. Don't forget to copy your kernel sources from your install media to your hard drive before trying to run ndisgen.


----------



## Fotis (Jul 1, 2015)

romanaOne said:


> I don't know what the error means, but you could try using ndisgen() to convert the windows driver into a module for the card.
> 
> I got strange errors with my $5 Broadcom BCM4322 and it was easier to set up ndis instead of the native drivers which I think do not support this card. Don't forget to copy your kernel sources from your install media to your hard drive before trying to run ndisgen.[/QUOT]
> 
> ...


----------



## romanaOne (Jul 3, 2015)

If you don't have the kernel source installed, ndisgen(8) will not build a module. It will stop with an error.

To install the kernel source, copy /usr/src/sys from your FreeBSD 10 install disk to /usr/src/sys on your computer.

Then try ndisgen(8) again.


----------



## Fotis (Jul 4, 2015)

Thanks again for replying. I am almost desperate.
I copied the source files to my /usr/ports/sys. I execute the `ndisgen` and I got the produced module rtl8187_sys.ko. I copied it to /boot/modules and also added the line 
	
	



```
#lrtl8187_sys_Load="YES"
```
to /boot/loader.conf. 
I rebooted and finally had the same result as before. Nothing changed.
The strange thing is during this procedure no error was announced by the kernel, only in the end driver was no working.
Do you have another idea?

Thanks


----------



## tingo (Jul 4, 2015)

Go for an easy idea: get a supported adapter (external), insert into machine, configure, enjoy.


----------



## romanaOne (Jul 7, 2015)

Fotis said:


> Thanks again for replying. I am almost desperate.
> I copied the source files to my /usr/ports/sys. I execute the `ndisgen` and I got the produced module rtl8187_sys.ko. I copied it to /boot/modules and also added the line
> 
> 
> ...



The pound sign (#) comments a line. It means everything after it is ignored, not just in loader.conf but in lots of things.


Also, you don't have to reboot to test the module:
`sudo kldload trl8187_sys` and then look at the last few lines of dmesg to see if it loaded:
`dmesg | tail`
There should be some stuff about the wifi card if the module worked.

Then check if the ndis0 device exists: `ifconfig -a`

Once module is loaded you may have to do further configurations as described in the link above because there is a problem with dhcp and ndis.

tingo has a point about just getting an external USB wifi that is supported. I mean, they are really cheap. But figuring it out might be more educational.

Sorry for taking all year to respond but I once in a while do work. LOL.


----------



## Fotis (Jul 9, 2015)

Thanks guys for replying...
I tried it all the ways, maybe the best solution for me is to buy a new adapter. Can you suggest me a chipset like RTL8187b??? A chipset which is already used by you or other users you know, and is easy to configure for freebsd??FreeBSD?
Thanks again, I have all the time in the world.


----------



## tingo (Jul 9, 2015)

Atheros chipsets supported by ath(4) is good. To figure out which wireless drivers exist in your version of FreeBSD, run `$ apropos wireless`.


----------



## Fotis (Jul 21, 2015)

Hi again.
After a little research iI found this: ADAPTER TP-LINK ATHEROS TL-WN822N.
It costs about 20e, is cheap enough and iI can afford.
Any other suggestion?
Thanks again.


----------



## wblock@ (Jul 21, 2015)

Last I knew, Atheros support for internal cards was good, not so good for uath(4).


----------

