# help installing hybrid nic driver (appletv nic) [solved]

## h2sammo

can anyne explain to me how to install this driver for 32 bit system?

http://www.broadcom.com/support/802.11/linux_sta.php

i tried following the directions in the text file but i got stuck when i had to compile the source.  whats the gentoo way to do it?Last edited by h2sammo on Wed Dec 16, 2009 12:37 am; edited 2 times in total

----------

## cach0rr0

```

laptop02 linux # eix broadcom

* net-wireless/broadcom-sta

     Available versions:  ~5.10.91.9.3-r1+i!m ~5.10.91.9.3-r2+i!m {kernel_linux}

     Homepage:            http://www.broadcom.com/support/802.11/linux_sta.php

     Description:         Broadcom's IEEE 802.11a/b/g/n hybrid Linux device driver.

```

so i reckon emerge broadcom-sta

from the look of things, it does have kernel dependencies as such

```

pkg_setup() {

        check_license

        CONFIG_CHECK="~!B43 ~!SSB"

        if kernel_is ge 2 6 31; then

                CONFIG_CHECK="${CONFIG_CHECK} LIB80211"

        elif kernel_is ge 2 6 29; then

                CONFIG_CHECK="${CONFIG_CHECK} LIB80211 COMPAT_NET_DEV_OPS"

        else

                CONFIG_CHECK="${CONFIG_CHECK} IEEE80211 IEEE80211_CRYPT_TKIP"

        fi

        linux-mod_pkg_setup

        BUILD_PARAMS="-C ${KV_DIR} M=${S}"

        BUILD_TARGETS="wl.ko"

}

```

----------

## h2sammo

thank you, it was an interactive emerge and i had to make 2 changes in kernel now my nic is seen and i am working on setting it up so i am on wireless network.

----------

## h2sammo

i had made another post here with another problem i have but they seem to be converging.  maybe a mod can merge the two:

https://forums.gentoo.org/viewtopic-p-6095173.html#6095173

----------

## h2sammo

also, since eth0 is not shown with ifconfig or iwconfig, i tried making the symlink to net.eth1 and have that added to default.

net.eth1 shows in init.d but when i do the rc-update addition it says net.eth1 does not exist in init.d.

everytime i boot, eth0 tries to be run and of course that goes nowhere (even though i remvoed net.eth0 from rc-update level).

i still have no network since eth1 shows up but i cannot put it on the wireless network (see my last post in the merged and locked post)

thank you

----------

## mikegpitt

Can you post the output of the following?

```
ifconfig -a

iwconfig

lspci
```

If you have the broadcom chipset you likely still need to install the firmware.  If the device is however not showing up in the ifconfig output, it means the system is missing the driver.

----------

## h2sammo

```
ifconfig -a

eth0     Link encap: Ethernet HWaddr 00:23....

           UP BROADCAST MULTICATS MTU:1500 Metric:1

           .

           .

           .

eth1     Link encap: Ethernet HWaddr 00:23....

           inet addr: 169.254.178.193 Bast: 169.254.255.255  Mach: 255.255.0.0

           UP BROADCAST MULTICATS MTU:1500 Metric:1

           .

           .

           .

lo         Link encap: Local Loopback

            inet address: 127.0.0.1 Mark: 255.0.0.0

           .

           .

           .

iwconfig

lo        no wireless extension

eth0    no wireless extension

eth1    IEEE 802.11 abgn ESSID:"" Nickname: ""

          Mode: Managed  Freq:2.412ghz    Access Point: Not Associated

           .

           .

           .

lspci -k

          .

          .

          .

       00.0 Network controller: Broadcom Corporation BCM4328 802.11 abgn (rev05)

              Kernel driver in use: wl

              Kernel modules: wl

           .

           .

           .

```

according to this wiki: http://en.gentoo-wiki.com/wiki/Apple_Macbook#WLAN

this nic shows to be working properly.

i just need help to get on the wireless network

----------

## d2_racing

Ok, right now, can you post this :

```

# dmesg | grep -i broad

# iwconfig

# iwlist scan

# dmesg | tail

```

----------

## h2sammo

```
 dmesg | grep -i broad

eth1: Broadcom4328 802.11 Wireless Controller 5.10.91.9

iwconfig

lo        no wireless extension 

eth0    no wireless extension 

eth1    IEEE 802.11 abgn ESSID:"" Nickname: "" 

          Mode: Managed  Freq:2.412ghz    Access Point: Not Associated 

           . 

           . 

           . 

iwlist scan

lo     interface doesnt support scanning

eth0  interface doesnt support scanning

eth1  Scan Completed:

         Cell  01 - Adress: 00:21:00:6D:E5:0F

                 ESSID: Motorola

                 Mode: Managed

                 Freq: 2.412 Ghz (Channel 1)

                 Quality: 3/5 Signal level: -69 dBm Noise level: -84dBm

                 IE: WPA Version 1

                      Group cipher: TKIP

                      Pairwise Cipher (1): TKIP

                      Authentication Suites (!): PSK

                 Encryption Key: on

                 Bit Rates: 1 Mb/s...............54 Mb/s

         Cell 02 - neighbour's, unprotected network, lol

dmesg | tail

.

.

.

eth1: Broadcom BCM4328 802.11 Wireless Controller 5.10.91.9

.

.

.

eth0: link down

ping www.google.com

ping: unknown host www.google.com

```

i see it scans my network (Motorola), i can get it to grab an IP address and get on the network however

----------

## d2_racing

Ok, since we see a network AP, then it's a pretty good start.

Right now, do you want to use wpa_supplicant or a network connection manager like WICD or network manager ?

What WM are you using right now ? KDE,Gnome,Xfce etc... ?

----------

## h2sammo

look at the end of this, i have wpa_supplicant setup (i dont know if i have done it right, but those are my settings)

https://forums.gentoo.org/viewtopic-p-6095173.html#6095173

towards end

i am using just fluxbox (X is not running yet, have probelsm with no mouse and keyboard bu i will attack that once i have ssh so i can post messages easier)

----------

## d2_racing

Ok, your /etc/conf.d/net should be like this :

```

modules=("wpa_supplicant")

wpa_supplicant_eth1="-Dwext" 

```

Remove the madwifi thing. That's not right.

----------

## d2_racing

 *h2sammo wrote:*   

> i am using just fluxbox (X is not running yet, have probelsm with no mouse and keyboard bu i will attack that once i have ssh so i can post messages easier)

 

Ok, when your wireless problem is solved, send me a pm and we will look at your Xorg problem.

----------

## h2sammo

i changed madwifi to wext as you instructed but there is no change.

iwconfig shows the same thing and so does ping www.google.com

still no network

----------

## mikegpitt

Can you post your entire /etc/conf.d/net?  From your above output it looks like eth1 has an ip address...  have you assigned this manually?

----------

## h2sammo

/etc/conf.d/net

```
config_eth1=( "dhcp" )

modules=("wpa_supplicant") 

wpa_supplicant_eth1="-Dwext" 
```

everything is dhcp no manual assignment

but it never grabs one, it times out if i do 

```
 dhcpcd eth1 
```

----------

## mikegpitt

It's odd that eth1 is reporting an ip address...  not sure what to make of that yet.

I noticed that in your net file, you don't have spaces before/after the quote marks in this line... not sure if it is necessary, but you might want to edit this line to look like this:

```
modules=( "wpa_supplicant" ) 
```

When you start eth1 with the init scripts now, do you see any errors?  What does the last few lines of dmesg report after you restart the net.eth1 service?

```
/etc/init.d/net.eth1 restart
```

----------

## d2_racing

Can you post this :

```

# cat /etc/resolv.conf

# ping www.google.com

```

----------

## h2sammo

```
 cat /etc/resolv.conf

Generated by dhcpcd

/etc/resolv.conf.head can replace this line

/etc/resolv.conf.tail can replace this line

ping www.google.com

ping: unknown host www.google.com

dhcpcd eth1

eth1 dhcpcd 4.0.15 starting

eth1: broadcasting for a lease

eth1: timed out

eth1: trying to use old lease in '/var/lib/dhcpcd/dhcpcd-eth1.lease'

eth1: checking 169.254.178.193 is available on attached networks

eth1: using IPv4LL address 169.254.178.193

```

i put the last command becasue i saw it before and i dont know what that IP address means because it is NOT connecting me to the network such so that i can use ping.

----------

## h2sammo

i keep reading on wpa_supplicant and i am unsure if there is an initialization step besides emerging it and creating those files i have posted.  if there is an initializations step i have NOT done it.  all i have done is create those files with nano.

also, i dont know what the wext driver does, but the name of the driver which enables my BCM4328 nic is called "wl.o" (thats an L).  see where drivers are enumerated: http://linux.die.net/man/8/wpa_supplicantLast edited by h2sammo on Mon Dec 14, 2009 9:00 pm; edited 1 time in total

----------

## mikegpitt

 *h2sammo wrote:*   

> i keep reading on wpa_supplicant and i am unsure if there is an initialization step besides emerging it and creating those files i have posted.  if there is an initializations step i have NOT done it.
> 
> also, i dont know what the wext driver does, but the name of the driver which enables my BCM4328 nic is called "wl" (thats an L).

 No other initialization is needed, except for creating your wpa_supplicant.conf and also editing your /etc/conf.d/net correctly.  In your above output, your resolv.conf hasn't been populated, since you haven't gotten an ip address from your dhcp server.

Have you tried to add the spaces into the `modules=( "wpa_supplicant" )` line yet?

Can you post the output of `dmesg | grep eth1`?

----------

## d2_racing

First thing first.

Are you using a router that give you an ip static or a dhcp address ?

Also, can you ping your router ?

Finally, can you access it with a LiveCD, like boot with the latest SystemRescueCD, and run this :

```

# dhcpcd eth0

# ping www.google.com

```

----------

## d2_racing

Also, can you post this :

```

# emerge -av dhcpcd

# rc-update show

```

----------

## h2sammo

 *mikegpitt wrote:*   

> It's odd that eth1 is reporting an ip address...  not sure what to make of that yet.
> 
> I noticed that in your net file, you don't have spaces before/after the quote marks in this line... not sure if it is necessary, but you might want to edit this line to look like this:
> 
> ```
> ...

 

i put the spaces as you suggested.  when i ran

```
 /etc/init.d/net.eth1 restart

Bash: /etc/init.d/net.eth1: No such file or directory 

dmesg | grep eth1

eth1: Broadcom BCM4328 802.11 Wireless Controller 5.10.91.9

```

d2_raacing

i do not have static addresses anywhere on my network.  i have dhcp on my gentoo box and there are mac laptops and windows laptops accessing ip addresses first come first served, no static ones.

pinging my router:

```
 ping 192.168.100.1

ping: Network is unreachable 
```

i cannot acces the appletv with anything coming from a disk because it does not have a cdrom.  i can chroot in it from my gentoo box.  which i have done and if i run 

```
 dhcpcd eth0

ping www.google.com 
```

  it pings just fine.

should i do the emerge command and rc-update show when i a chrooted from my gentoo box?  in that case it would not have any way of using the NIC i am having trouble with, but it would use my other box's NIC...right?

----------

## mikegpitt

It looks like you are missing the net.eth1 symlink... do this and post what you get:

```
ln -s /etc/init.d/net.lo /etc/init.d/net.eth1

/etc/init.d/net.eth1 restart

dmesg | grep eth1
```

----------

## h2sammo

```
 ln -s /etc/init.d/net.lo /etc/init.d/net.eth1

/etc/init.d/net.eth1 restart

Caching service deoendencies ...

Starting eth1

    Starting wpa_supplicant on eth1 ...

    Starting wpa_cli on eth1 ...

        Backgrounding ...

dmesg | grp eth1

eth1: Broadcom BCM4328 802.11 Wireless Controller 5.10.91.9

ping -c 3 www.gentoo.com

ping: unknown host www.gentoo.com

ping 192.168.100.1

Connect: Network is unreachable 
```

----------

## mikegpitt

I think we should make sure your wpa_supplicant.conf is correct.  I saw what you posted in the other thread, and didn't really see any problems, but automatic configuration is always easier than manual.  Do you have X installed on your box?  If yes, I recommend using wpa_gui to set up your wireless.  From wpa_gui you can scan for the appropriate network, and from there configure your settings.

EDIT:  It looks like from your scan results you are using WPA -- if so, you should have something like this in your wpa_supplicant.conf:

```
ctrl_interface=/var/run/wpa_supplicant

ctrl_interface_group=0

update_config=1

network={

        ssid="mynetworkname"

        psk="mypassword"

        priority=2

        disabled=1

}

```

Last edited by mikegpitt on Mon Dec 14, 2009 11:55 pm; edited 1 time in total

----------

## h2sammo

X starts but i have no mouse/keyboard... i was going to troubleshoot that next, once i have ssh so i can copy/paste terminal output instead of having to type incomplete outputs like i am doing now.

so i cannot use X yet.

----------

## h2sammo

 *mikegpitt wrote:*   

> I think we should make sure your wpa_supplicant.conf is correct.  I saw what you posted in the other thread, and didn't really see any problems, but automatic configuration is always easier than manual.  Do you have X installed on your box?  If yes, I recommend using wpa_gui to set up your wireless.  From wpa_gui you can scan for the appropriate network, and from there configure your settings.
> 
> EDIT:  It looks like from your scan results you are using WPA -- if so, you should have something like this in your wpa_supplicant.conf:
> 
> ```
> ...

 

i changed mine so it looks just like what you have posted with my network name and phrase password where they belong.  same result wheni try to ping router or google

EDIT: i wanna try the wl.o driver in /etc/init.d/net config file.  Do i have to put -D before it? also do i have to put the .o ?

here is a list of available drivers: http://man.he.net/man8/wpa_supplicant

 *Quote:*   

>  AVAILABLE DRIVERS
> 
>        A summary of available driver backends is below. Support  for  each  of
> 
>        the  driver  backends  is  chosen at wpa_supplicant compile time. For a
> ...

 

how can i put the wl.o driver in there, instead of wext, correctly, because thats the actual driver my NIC chipset is using?

----------

## mikegpitt

Just use the WEXT driver -- this let's your system pick the one that it thinks is best.  I've used it with success on a wide variety of systems.

Now sure what to make out of why your system isn't connecting to the ap listed in your config...  Do you see any messages in your /var/log/messages that would shed some light on the issue?

----------

## h2sammo

```
 kernel:eth0: link down

rc-scripts: Configuration not set for eth0 - assuming DHCP

dhclient: DHCPDISCOVER on eth0 to 255.255.255.255.255 port 67 interval 5

dhclient: DHCPDISCOVER on eth0 to 255.255.255.255.255 port 67 interval 13

dhclient: DHCPDISCOVER on eth0 to 255.255.255.255.255 port 67 interval 12

dhclient: DHCPDISCOVER on eth0 to 255.255.255.255.255 port 67 interval 20

dhclient: DHCPDISCOVER on eth0 to 255.255.255.255.255 port 67 interval 8

dhclient: DHCPDISCOVER on eth0 to 255.255.255.255.255 port 67 interval 3

dhclient: No DHCPOFFERS received

rc-scripts: ERROR: cannot start netmount as net.eth0 could not start 
```

dont know if it matters but i had dhclient instead of dhcpcd because i was using a different tutorial.  i emerged -C dhclient and emerged dhcpcd.  could this be causing this?

----------

## mikegpitt

I have never used dhclient, so I'm not sure how that would affect things, but it wouldn't hurt to move to dhcpcd.  No lines in your /var/log/messages that relate to eth1?

----------

## h2sammo

i am using dhcpcd now.

eth0 shows linked to the wired ethernet controller Realtek...etc

eth1 shows linked to the wireless NIC, Broadcom...etc

no matter how i add eth1 to rc-update it will NOT start at the beggining.  only eth0 will, even though i removed it from tc-update default level.  why?

i made a usbLIVE for gentoo.  i will try to run it and see if i get connected.

----------

## mikegpitt

The net.* services are automatically started unless prevented otherwise (see RC_PLUG_SERVICES section in your /etc/conf.d/rc).

When net.eth1 starts, it should also start wpa_supplicant (which looks like it is happening from your previous posts), and then start scanning through your config for ap's to connect to.

Here is something to check...  when you run the command `iwconfig eth1` do you see it scanning for the ap in your configuration?

----------

## d2_racing

Are you using baselayout 1.x or 2.x ?[/code]

----------

## h2sammo

mikegpitt

i will check if 'iwconfig eth1' is scanning for the ap in configuration when i get home for lunch.  

d2_racing

how can i check what baselayout i am using?

update on me trying to use usbLIVE.  FAIL

what was i thinking?  appletv does not use a BIOS but some sort of EFI counterpart.  so i cannot use lilo or grub directly (wont boot the gentoo usbLIVE).  there is a whole section dedicated to installing gentoo in a certain way while maintaining certain file formats and configurations so my gentoo grub loader on the HDD now can trick the appletv and boot as is. (http://code.google.com/p/atv-bootloader/wiki/InstallGentooVer1)

even if i had gotten the usbLIVE to boot, i would not have had keyboard or mouse, because the appletv only has 1 usb port and not other type of inputs.

----------

## mikegpitt

 *h2sammo wrote:*   

> 
> 
> how can i check what baselayout i am using?

 Run an `emerge -pv baselayout` and see what version is currently installed...  If you are running stable then you are likely on baselayout-1.x, unstable then 2.x.

----------

## h2sammo

iwconfig eth1 goes directly to 

```
 eth1    IEEE 802.11 abgn ESSID:"" Nickname: "" 

          Mode: Managed  Freq:2.412ghz    Access Point: Not Associated 

.

.

.
```

 it does not output any indication of scanning nor does it wait whatsoever. it goes directly to that message.  should the scan take a bit of time?

im running baselayout-1.12.13

----------

## NeddySeagoon

h2sammo,

What sort of encryption are you using on your wireless network?

If its WEP or none at all you can use wireless-tools and ifconfig to start your wireless network manually.

Read the man page for iwconfig.

From memory you may need 

```
ifconfig eth1 up
```

so the interface accepts commands.

Then you can use 

```
iwconfig eth1 txpower 30dBm
```

to ensure the transmitter is on.

Followed by 

```
iwconfig eth1 mode managed
```

and

```
iwconfig eth1 ssid "any"
```

so it will connect to any network

lastly, 

```
iwconfig eth1 ap <MAC_Addr of Access Point>
```

to get it to associate.

Notice I've not set any crypto key in there. Its one less thing to get right if you can test with a non encrypted AP.

If you are using any other encryption, you must use WPA_Supplicant, which I have not set up by hand.

----------

## h2sammo

i will take off the encryption when i get home and i will try it this way.  

also, when you say: "If you are using any other encryption, you must use WPA_Supplicant, which I have not set up by hand." does that mean wpa_supplicant CANNOT be setup by hand?

----------

## NeddySeagoon

h2sammo,

I'm not sure if WPA_Supplicant can be set up by hand. My WPA_supplicant.conf is

```
# This is a network block that connects to any unsecured access point.

# We give it a low priority so any defined blocks are preferred.

network={

        key_mgmt=NONE

        priority=-9999999

}

# The below line not be changed otherwise we refuse to work

ctrl_interface=/var/run/wpa_supplicant

# Ensure that only root can read the WPA configuration

ctrl_interface_group=0

# Let wpa_supplicant take care of scanning and AP selection

ap_scan=1

# Simple case: WPA-PSK, PSK as an ASCII passphrase, allow all valid ciphers

network={

  ssid="RadioNet"

  psk="<your_paas_phrase>"

  # The higher the priority the sooner we are matched

  priority=5

}

# IBSS/ad-hoc network with WPA-None/TKIP

network={

  ssid="RadioNet"

  mode=1

  proto=WPA

  key_mgmt=WPA-NONE

  pairwise=NONE

  group=TKIP

  psk="<pass_phrase>"

}
```

After I geot my AP to associate are work unencrypted with wireless-tools, this just worked

----------

## h2sammo

ok IT WORKED, lol.

wireless-tools works.  i am on network, etc.

wpa_supplicant - NOT.

instructions here: http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=4&chap=4#doc_chap3

thank you

----------

## d2_racing

Nice  :Razz: 

----------

## mikegpitt

Not sure why iwconfig would work and wpa_supplicant would fail, but if it works it works   :Smile: 

Once you get X working properly, you might want to try using wpa_gui to generate a new wpa_supplicant.conf, and see if it works better.

----------

