Wireless printer, ad-hoc, WEP

I can't figure out how to connect to my wireless printer (HP LJ 1022nw) through my Linksys WUSB600N adapter. The driver (run) seems to work as it should.
Code:
dmesg | grep -i linksys:
run0: <Linksys Linksys WUSB600N Wireless-N USB Network Adapter with Dual-Band ver. 2, class 0/0, rev 2.00/1.01, addr 2> on usbus0
Of course, I have read the chapter in the Handbook, but I can't put the pieces together. I can set up wlan0 by:
Code:
/etc/rc.conf:
wlans_run0="wlan0"
Since my printer is using its own DHCP server (and WEP), I have tried:
Code:
/etc/rc.conf:
ifconfig wlan0="WPA DHCP"
And I have made a wpa_supplicant.conf file:
Code:
/etc/wpa_supplicant.conf:
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=wheel
network={
  scan_ssid=1
  mode=1
  ssid="lj1022nw"
  key_mgmt=NONE
  wep_key0="secret ASCII code"
  wep_tx_keyidx=0
}
I don't know if wpa_supplicant should be invoked by that. I doesn't seem so. I have also tried putting this into rc.conf:
Code:
/etc/rc.conf:
ifconfig wlan0 create wlandev run0 wlanmode adhoc
No matter what I try, the connection is never established. And even worse, for som strange reason, the wlan0 gets my public IP address and my ethernet adapter loses its route to the gateway.

I can give more details on my configuration, but to begin with I just need to be helped in the right direction. I guess that the DHCP declaration for the wireless adapter is part of the explanation. But I think I need that, since I want to be able to connect more than one computer to the printer at the same time.

I would appreciate some guidance here.

Thank you in advance.

Regards,
Jon
 
I have some additional information. I haven't shown all of the content of my /etc/rc.conf. And I wonder if some of the other network related stuff could be part of the problem.
Code:
hostname="FQDN"
ifconfig_xl0="inet 192.168.1.21 netmask 255.255.255.0"
defaultrouter="192.168.1.5"

##wlans_run0="wlan0"
##ifconfig wlan0="WPA SYNCDHCP"

ipv6_enable="YES"
gateway_enable="YES"
arpproxy_all="YES"
router_enable="YES"
For the moment, I have commented the wireless settings, but that is just as a mean to avoid troubles while I am updating a lot of ports. I changed "DHCP" to "SYNCDHCP" after searching for solutions, but I haven't tested that option yet. If you need more information to help me, please ask for it.

Regards,
Jon
 
Back
Top