WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Introduction, plus: my ACX wireless card is online!  (Read 8186 times)

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Introduction, plus: my ACX wireless card is online!
« on: April 05, 2009, 11:40:38 PM »
Hello!  I go by 'Mike Lockmoore'.  I develop embedded Linux professionally (currently using Fedora 7 as my development host).  I use Puppy Linux a lot at home, but I wanted to try out Tiny Core.  I've frugally installed TC 1.3rc1 on my ~5 year-old Dell P4 laptop.  I need wireless for this laptop to be useful, so I've managed to build the open-source driver for my TI ACX111 chipset-based Linsys W54Gv2 PCCard wireless adapter.  I'm posting from this setup using Opera.   :)  But it was not easy!

I first tried the NDISWrapper_full extension and the Windows .INF for my wireless adapter, but that did not work.  I was not surprised, I could not get the NDISWrapper working very well in Puppy Linux either.

The latest versions of Puppy Linux include the acx driver module, so I thought I should be able to build and load it in TC.  Here's roughly how I did it.

I loaded the following extensions:
* Wireless kernel modules (noticed the driver for acx was not included)
* Wireless_tools
* Linux headers
* GCC
* CompileTC (to get make and some other tools useful in building software)

I downloaded the acx driver source "acx-20080210.tar.bz2" from http://acx100.sourceforge.net/ and unpacked it.

I ran the make file to build the acx.ko kernal module file.

I created a /lib/firmware folder and added it to my .filetool.lst file

I copied the acx.ko module there (I'm sure there's a more appropriate place) and also the wireless chipset firmware (FwRad16.fw in the Windows device driver installation), renamed to 'tiacx111c16' as expected by the kernel module. 

With much experimentation, I came up with the following startup commands (which will be different for your access point or public access points), which I put in a script file 'wireless_start.sh':
Code: [Select]
#!/bin/sh
# commands to associate with wireless access point
sudo insmod /lib/firmware/acx.ko
sudo ifconfig wlan0 up
sleep 1
sudo iwconfig wlan0 essid "{{MY ESSID}}"
sudo iwconfig wlan0 key restricted
sudo iwconfig wlan0 key "{{MY WEP KEY}}"
sleep 1
sudo udhcpc -i wlan0
sleep 1

This script was placed in my /opt folder.  The script has been added to my .filetool.lst.
The script is now invoked by my /opt/bootlocal.sh script. EDIT: hmmm, after reboot, my wireless_start.sh script is not automatically successful, but if I run it in a terminal, it complains that the acx module already exists, but then proceeds to associate with the access point sucessfully.  Maybe I need longer sleep periods to let things stabalize?

There's probably a few things I could have done easier or better, but it seems to be working well so far, and I can surf wirelessly in TC like I wanted!  Maybe my compiled acx.ko can be added to the wireless extensions?
--
Mike Lockmore
« Last Edit: April 05, 2009, 11:56:12 PM by MikeLockmore »

Offline roberts

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 7361
  • Founder Emeritus
Re: Introduction, plus: my ACX wireless card is online!
« Reply #1 on: April 06, 2009, 12:06:41 AM »
Try adding full path to iwconfig command when run from /opt/bootlocal.sh
10+ Years Contributing to Linux Open Source Projects.

Offline jpeters

  • Restricted
  • Hero Member
  • *****
  • Posts: 1017
Re: Introduction, plus: my ACX wireless card is online!
« Reply #2 on: April 06, 2009, 12:28:36 AM »
If I recall, when using wireless both from dsl and tc, I have to 'reconnect'  even after a suspend.
No need to reinstall the module, of course, just the iwconfig info and the udhcpc command (in dsl, pump -i).   

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Re: Introduction, plus: my ACX wireless card is online!
« Reply #3 on: April 06, 2009, 12:35:48 AM »
Robert:  That did it!  I now see that you have told others to do the same thing.  Here is my wireless_start.sh script now:

Code: [Select]
#!/bin/sh
# commands to associate with wireless access point
sudo insmod /lib/firmware/acx.ko
sudo /sbin/ifconfig wlan0 up
sudo /usr/local/sbin/iwconfig wlan0 essid "{{MY ESSID}}" key restricted "{{ MY WEP KEY }}"
sleep 3
sudo /sbin/udhcpc -i wlan0

Robert, note that the iwconfig statements were combined into one, which is also recommended by you, correct?

Thanks! 
--
Mike Lockmoore

Offline giac_fab

  • Newbie
  • *
  • Posts: 24
Re: Introduction, plus: my ACX wireless card is online!
« Reply #4 on: October 16, 2011, 06:26:00 AM »
Hi

I know this topic is very old.

I'm trying to compile the same module for microcore 4.0.1

I get the following errors :
 
tc@box:/usr/src/acx-20080210$ make -C /lib/modules/`uname -r`/build M=`pwd`
make: Entering directory `/usr/local/src/linux-headers-3.0.3-tinycore'
  CC [M]  /usr/src/acx-20080210/wlan.o
In file included from /usr/src/acx-20080210/acx.h:2:0,
                 from /usr/src/acx-20080210/wlan.c:49:
/usr/src/acx-20080210/wlan_compat.h:224:14: error: conflicting types for 'irqreturn_t'
include/linux/irqreturn.h:16:24: note: previous declaration of 'irqreturn_t' was here
In file included from /usr/src/acx-20080210/acx.h:6:0,
                 from /usr/src/acx-20080210/wlan.c:49:
/usr/src/acx-20080210/acx_func.h:109:0: warning: "printk_ratelimited" redefined [enabled by default]
include/linux/printk.h:244:0: note: this is the location of the previous definition
make[1]: *** [/usr/src/acx-20080210/wlan.o] Error 1
make: *** [_module_/usr/src/acx-20080210] Error 2
make: Leaving directory `/usr/local/src/linux-headers-3.0.3-tinycore'


Is kernel uncompatible ?
Should I waste my old card ???

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11675
Re: Introduction, plus: my ACX wireless card is online!
« Reply #5 on: October 16, 2011, 09:21:35 AM »
Hi giac_fab
I found the following which may help
Quote
To solve this problem just change line 221 in wlan_compat.h
from
#ifndef IRQ_NONE
to
#if (! (defined(_LINUX_IRQRETURN_H) || defined(IRQ_NONE)))
Open the file  /usr/src/acx-20080210/wlan_compat.h  and find the above mentioned line and change
it. The line number might not be the same. Then try again.
This fix was found at:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=545367#10

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11675
Re: Introduction, plus: my ACX wireless card is online!
« Reply #6 on: October 16, 2011, 10:36:32 AM »
Hi giac_fab
It seems the network API changed since this driver was released so you will probably get other
compiler errors. You might want to check out this wiki:
http://sourceforge.net/apps/mediawiki/acx100/index.php?title=Main_Page
They list a newer driver called  acx-mac80211  that you may have better luck with. To download it
you have to install the  git  extension.

Offline giac_fab

  • Newbie
  • *
  • Posts: 24
Re: Introduction, plus: my ACX wireless card is online!
« Reply #7 on: October 16, 2011, 12:08:17 PM »
@Rich
Quote
To solve this problem just change line 221 in wlan_compat.h
from
#ifndef IRQ_NONE
to
#if (! (defined(_LINUX_IRQRETURN_H) || defined(IRQ_NONE)))

I already tried that .... different kinds of errors show up

Quote
They list a newer driver called  acx-mac80211  that you may have better luck with.

with acx-mac80211
fatal error: net/ieee80211.h: No such file or directory .....
I have

tc@box:/usr/local/src/linux-headers-3.0.3-tinycore/include/net$ ./ieee8021
ieee80211_radiotap.h  ieee802154.h          ieee802154_netdev.h


After some years of linux i can say that my biggest problems were and are  wireless drivers :-P



Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 7183
    • My Community Forum
Re: Introduction, plus: my ACX wireless card is online!
« Reply #8 on: October 16, 2011, 12:53:49 PM »
Did you try ndiswrapper?
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11675
Re: Introduction, plus: my ACX wireless card is online!
« Reply #9 on: October 16, 2011, 06:14:27 PM »
Hi giac_fab
The header file is located here:
/usr/local/src/linux-headers-2.6.33.3-tinycore/include/linux/ieee80211.h

Offline giac_fab

  • Newbie
  • *
  • Posts: 24
Re: Introduction, plus: my ACX wireless card is online!
« Reply #10 on: October 20, 2011, 04:34:16 PM »
I did a symlink in /net of the header you indicated

Code: [Select]
1-20080210/common.c:4482:5: error: conflicting types for 'acx_net_get_tx_stats'
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/acx_func.h:633:5: note: previous declaration of 'acx_net_get_tx_stats' was here
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c: In function 'acx_net_get_tx_stats':
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4492:16: error: dereferencing pointer to incomplete type
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4492:16: error: request for member 'data' in something not a structure or union
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4492:7: warning: assignment from incompatible pointer type [enabled by default]
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4493:6: error: dereferencing pointer to incomplete type
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4493:6: error: request for member 'len' in something not a structure or union
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4493:2: warning: statement with no effect [-Wunused-value]
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4494:6: error: dereferencing pointer to incomplete type
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4494:6: error: request for member 'limit' in something not a structure or union
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4494:2: warning: statement with no effect [-Wunused-value]
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4495:6: error: dereferencing pointer to incomplete type
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4495:6: error: request for member 'count' in something not a structure or union
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4495:2: warning: statement with no effect [-Wunused-value]
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c: In function 'acx_key_write':
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4642:36: error: 'ALG_WEP' undeclared (first use in this function)
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4642:33: warning: comparison between pointer and integer [enabled by default]
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c: In function 'acx_net_set_key':
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4706:13: error: 'struct ieee80211_key_conf' has no member named 'alg'
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4712:9: error: 'ALG_WEP' undeclared (first use in this function)
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4718:7: error: 'ALG_TKIP' undeclared (first use in this function)
/usr/local/src/linux-headers-3.0.3-tinycore/drivers/net/wireless/acx/acx-mac80211-20080210/common.c:4721:7: error: 'ALG_CCMP' undeclared (first use in this function)



A lot of errors ....  ( the ones above are only some )
« Last Edit: October 20, 2011, 04:37:40 PM by giac_fab »

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Re: Introduction, plus: my ACX wireless card is online!
« Reply #11 on: November 02, 2011, 03:56:28 PM »
Hi giac_fab.

I've been delaying upgrading to TC 4.0, partly due to being busy with many other things and partly because I have been dreading problems like this from the kernel upgrade to the 3.0 series.  If/when I get sufficient time to work on this, I'll post whatever I find or figure out.  However, if you or some other people figure it out first, I thank you in advance.  ;)

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Re: Introduction, plus: my ACX wireless card is online!
« Reply #12 on: February 19, 2012, 10:31:51 PM »
All: I have an ACX driver working (kinda mostly  :-\) in TC 4.3 with the Linux 3.0.3 kernel.  It is not the older acx.ko module, but a newer "acx-mac80211.ko" version that also requires the mac80211.ko module to be loaded first.  However, it has been very touchy about associating with my access point, and sometimes after connecting, it seems to have an internal error and drops the connection.   

If anyone wants to duplicate what I did... I loaded compiletc.tcx, linux-headers-3.0.3-tinycore.tcz, xz.tcz,and git.  I downloaded the Core-patche linux source archive and decompressed it with xz -d and then unpacked it with tar -xf.  I changed to the [work area]/linux-3.0.3/drivers/net/wireless directory.  I fetched the acx driver source with:

  git clone git://acx100.git.sourceforge.net/gitroot/acx100/acx-mac80211

I then changed to the ./acx-mac80211 subdirectory and issued
  make

To run the new driver, I have the following in my /opt/bootlocal.sh
Code: [Select]
sudo modprobe mac80211
sudo insmod /home/tc/drivers/acx-mac80211.ko

Like I said, getting it to associate can be very frustrating... sometimes it connects right up, sometimes it refuses many many times in a row.  I use dmesg to see the status and error messages after each step of my attempts to connect using iwconfig.  Not for the feint of heart.  :P

I don't know if it is possible to build the older acx.ko to run in the 3.0.x kernels.  Maybe, but that version stopped being maintained in the Linux 2.6.x era.


Offline sm8ps

  • Sr. Member
  • ****
  • Posts: 338
Re: Introduction, plus: my ACX wireless card is online!
« Reply #13 on: September 24, 2012, 06:24:35 PM »
Hello all,

I have pondered on starting a new thread but since I am basically just re-writing things from this thread, I thought this might be a nice pool of information that is easy to find by search-engines.

My last tries with TinyCore go back quite a while and were not highly successful. Now I am trying to get my Compaq/HP TC1000 up on the road again. After some hardware issues, I got the machine running and installed CorePlus 4.6.1 on a IDE-to-CompactFlash-to-SDCard-to-MicroSDCard (!) adapter combo.

Next step was to replace the 802.11b wireless card. All I had was a refurbished Mini PCI card from a now useless ISDN router which -- we are getting closer to the landing point of this all -- happened to be a TI-ACX111 model. Thanks to the information in this thread, I was able to get it up and running within a short amount of time. Since I was uncertain about how to add the firmware I thought I would add this information here.

My kernel version is 3.0.21. I did as suggested by MikeLockmoore in his previous post from February 2012. I got firmware 1.2.1.34 via a link on the Sourceforge site of the acx100 project (http://sourceforge.net/apps/mediawiki/acx100/index.php?title=Firmware). After un-packing the archive, I extracted the file acx111_1.2.1.34/tiacx111c16 and put it into the newly created folder /lib/firmware.

After that the insmod command worked (if not then check dmesg) and I could easily connect to my WLAN. In fact, I am connected right now as I am posting.

Cheers!
St. Mueller

Offline MikeLockmoore

  • Hero Member
  • *****
  • Posts: 525
  • Good software needn't be big!
Re: Introduction, plus: my ACX wireless card is online!
« Reply #14 on: October 02, 2012, 01:13:17 PM »
sm8ps:  I'm glad it worked for you, especially for Tiny Core version 4.6. 

My ACX-based WiFi system is still at version 4.3 of Tiny Core.  I'm planning to retire that machine soon, and since it is working well enough and the change in the Linux Kernel version for Tiny Core 4.4 and later would probably require a rebuild of the ACX driver module, I'm not likely to upgrade at this point.  I'll pass the ACX-sage baton to you, if you care to accept.  ;)