Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > More E-Book Readers > iRex

Notices

Reply
 
Thread Tools Search this Thread
Old 01-06-2008, 06:13 PM   #1
synerr
Junior Member
synerr began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Jan 2008
Device: iRex Iliad
Network Control Scripts

I put together some simple scripts to connect/disconnect to wireless networks.

This scripts use iLiad network profiles file to find your list of preferred networks. (/mnt/settings/registry/nwprofiles.xml) They will then scan for any of these networks. If they available, They it will use any WEP keys you provided the iLiad and try to connect. If they cannot connect to or find any of these networks, they will try to connect to any open network it can find.

Use is really simple. You just unzip the file and transfer it to your iLiad. Since they are .sh script files, you can run them from the iLiad interface just by "opening" them, so you don't have to run them from the shell.

There are two scripts:
  • start_network.sh
  • stop_network.sh

Once they run start_network.sh, you will see some new files:
  • preferred_networks.txt: the list of the networks it found listed in the iLiad
  • scanned_networks.txt: the list of networks it could find
  • open_networks.txt: any open (unsecured) networks it could find
  • last_connection_status.sh: the network it could connect to and your ip address, dns, and so forth.

If anyone has any comments, suggestion, etc; thanks!
Attached Files
File Type: zip network.zip (4.6 KB, 560 views)
synerr is offline   Reply With Quote
Old 01-11-2008, 04:05 PM   #2
Martijn
Connoisseur
Martijn has learned how to read e-booksMartijn has learned how to read e-booksMartijn has learned how to read e-booksMartijn has learned how to read e-booksMartijn has learned how to read e-booksMartijn has learned how to read e-booksMartijn has learned how to read e-books
 
Martijn's Avatar
 
Posts: 68
Karma: 855
Join Date: Jan 2007
Location: Netherlands
Device: iLiad
Hi,

This looks very interesting. Being able to reliable bring up the wireless (and shut it down afterwards) in combination with the Feedbooks downloader would be great.

Unfortunately I ran into a problem: I couldn't bring my wireless connection up.

I think it is because I use WPA encryption. I tried replacing the line:
export COMMAND="$WLAN_SCRIPT start '$1' enc $2"
with:
export COMMAND="$WLAN_SCRIPT start '$1' wpa $2"
but that did not seem to be enough.

My wireless does come up when I manually use:
wireless.sh start MySSID wpa MyPassPhrase

Furthermore my passphrase is shown correctly in the prefered_networks.txt line. (Though that file also contains some empty lines and a line containing "-1").
And my network is shown in the scanned_networks.txt file.

However, when I run the start_network.sh script the last_connection_status.txt file shows:
Starting Network
=====================
No Network Found

I could dig into the script myself, but I figure you know it better.
(Also I haven't setup ssh yet, so testing would be a pain.)

Oh, I do have a feature request:
Opening a small txt file takes ridiculous amount of time, so could you put the network status (connected to .../disconnected) in the name of a file or in a manifest.xml for the last_connection_status.txt file ?
That way it is possible to see the status directly in the content listener.

Thanks.
Martijn is offline   Reply With Quote
Advert
Old 01-12-2008, 11:26 AM   #3
dkm365
Junior Member
dkm365 began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Jan 2008
Location: Iowa, USA
Device: iLiad, Palm T|X
Wouldn't WPA require more info, as there is more than just the WPA1 & WPA2 variable? I haven't looked at the script, but it would seem likely that more than one line would need altered to make the change from WEP to WPA. Also, if you have the broadcast SSID turned off on your router it may take multiple attempts to connect and an automated script may have difficulty with that. I know on my linux laptop on a network that is not broadcasting the SSID, I often have to manually attempt a connection once or twice when the automated script fails.

I'm interested to see whether you get it to work with WPA.
dkm365 is offline   Reply With Quote
Old 01-13-2008, 06:54 AM   #4
Martijn
Connoisseur
Martijn has learned how to read e-booksMartijn has learned how to read e-booksMartijn has learned how to read e-booksMartijn has learned how to read e-booksMartijn has learned how to read e-booksMartijn has learned how to read e-booksMartijn has learned how to read e-books
 
Martijn's Avatar
 
Posts: 68
Karma: 855
Join Date: Jan 2007
Location: Netherlands
Device: iLiad
You might be right that there is more to it.
wireless.sh start MySSID wpa MyPassPhrase
Does start my wireless connection but not reliably it seems.

However, I found another set of scripts that suit my needs:
https://www.mobileread.com/forums/showthread.php?t=14718

Those scripts do not automatically connect to any available wireless network, but I'm fine with that (for now ).
Martijn is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Any Page Turner Scripts Out There? Barney Kindle Formats 0 09-26-2009 05:36 PM
PDF formatting scripts for eee PC zupapa Alternative Devices 11 02-19-2009 07:09 PM
Problem with News scripts Derry Calibre 4 08-19-2008 05:08 AM
Fox Searchlight scripts available in PDF jckatz Reading Recommendations 1 02-23-2008 11:39 PM
Television scripts for your handheld Bob Russell Lounge 2 01-07-2006 06:22 PM


All times are GMT -4. The time now is 02:50 PM.


MobileRead.com is a privately owned, operated and funded community.