http://wiki.openmoko.org/api.php?action=feedcontributions&user=Stuart&feedformat=atomOpenmoko - User contributions [en]2024-03-19T11:06:26ZUser contributionsMediaWiki 1.19.24http://wiki.openmoko.org/wiki/Vala-terminalVala-terminal2009-12-10T10:20:29Z<p>Stuart: </p>
<hr />
<div>[[Image:Vala-terminal4.png|thumb| vala-terminal 1.1.1-r0.2 ]]<br />
<br />
== Overview ==<br />
Command Line Terminal. It is written in ([http://live.gnome.org/Vala/ vala]) programming-language. Vala produces c-code, which is then compiled binary form, so vala do not add any runtime requirements/dependeries.<br />
<br />
This is official successor of openmoko-terminal2 (https://kerneltrap.org/mailarchive/openmoko-community/2008/11/13/4084004/thread).<br />
<br />
Features:<br />
<br />
* Narrow toolbar<br />
* Tabs<br />
* Scrollbar<br />
* Toolbar can be oriented horizontaly or vertically<br />
* Zooming (Fontsize changing)<br />
* Paste selected text (not really clipboard)<br />
* handles -e parameter, like xterm and konsole in KDE (e.g. you can use it to start console applications with desktop-files: vala-terminal -e nano /etc/hosts)<br />
<br />
== Usage ==<br />
[[Image:Vala-terminal3.png|thumb| landscaped vala-terminal with toolbar vertically]]<br />
<br />
Buttons in toolbar are loaded from Systems stock, so they can look different than in screenshots (please add, if your distro shows it differently)<br />
=== Buttons ===<br />
Buttons left to rigth:<br />
* New - Open new tab<br />
* Del - Close current tab<br />
* + - Zoom in (raise font size)<br />
* - - Zoom out (lower font size)<br />
* Paste - Paste selected text (can be from another tab, not in another application)<br />
* <- - Go previous tab<br />
* -> - Go next tab<br />
* [1/2] - Current tab / Total number of tabs<br />
* Circle-arrow - Flips the toolbar to vertical (and vertical to horizontal)<br />
<br />
=== Commandline parameters===<br />
*--help : manual<br />
*-v : starts toolbar vertically<br />
*-h : starts toolbar horizontally<br />
*-fs size : starts with given fontsize<br />
*-fc r g b : color of font (values between 0...65535)<br />
*-bc r g b : color of background (values between 0...65535)<br />
*-f fontname : Used font<br />
*-e cmd : executes cmd (like xterm and konsole in KDE)<br />
<br />
=== Tips ===<br />
-e is very handy with desktop-files. You can start console applications from icons:<br />
<br />
vala-terminal -e nano /etc/hosts<br />
<br />
=== Examples ===<br />
vala-terminal -v -fs 3 -f Ariel -fc 0 65535 0 -bc 65535 0 0 -e nano<br />
<br />
Starts toolbar vertically (-v), fontsize 3 (-fs 3), using font Ariel (-f Ariel). Text is maximal green and background is maximal red. Executes automatically command 'nano'.<br />
<br />
== Download ==<br />
[[Image:Vala-terminal-Nethack.png|thumb| vala-terminal with toolbar vertically]]<br />
<br />
[http://www.opkg.org/package_112.html In opkg.org]<br />
<br />
opkg install http://www.opkg.org/packages/vala-terminal_1.1.1-r0.3_armv4t.opk<br />
<br />
<br />
== Building ==<br />
It can be builded with this bitbake-recipe, but you must have valac version 0.5.6 (released 18.January 2009) or newer installed ON YOUR HOST MACHINE.<br />
(e.g. Ubuntu has version 0.5.7, so this might be useless snippet)<br />
<br />
It is just: (Who will make step-by-step walktrought how to install this in toolchain?)<br />
<br />
wget http://download.gnome.org/sources/vala/0.5/vala-0.5.6.tar.bz2<br />
tar -xvf vala-0.5.6.tar.bz2<br />
cd vala-0.5.6<br />
./configure<br />
make<br />
make install<br />
<br />
Bitbake-recipe: <br />
DESCRIPTION = "The Openmoko Command Line Terminal"<br />
SECTION = "openmoko/applications"<br />
LICENSE = "GPL"<br />
HOMEPAGE = "http://git.freesmartphone.org/?p=vala-terminal.git"<br />
PKG_TAGS_${PN} = "group::applications"<br />
PV = "1.1.1"<br />
PR = "r0.4" <br />
<br />
<br />
#how to use git in bb?<br />
#SRC_URI = "git://git.freesmartphone.org/vala-terminal.git;proto=http" <br />
<br />
do_patch() {<br />
git clone git://git.freesmartphone.org/vala-terminal.git <br />
<br />
#so we first run autogen.sh (it will generate Makefile)<br />
mv vala-terminal vala-terminal-${PV}<br />
cd vala-terminal-${PV}<br />
./autogen.sh \<br />
--build=i486-linux-gnu \<br />
--host=${TARGET_SYS}<br />
<br />
#Now we have Makefile and we can patch it to use host-systems valac (it generates c-code)<br />
sed 's/$(VALAC) -c/\/usr\/local\/bin\/valac -C/g' Makefile > Makefile_new<br />
mv Makefile_new Makefile<br />
}<br />
<br />
do_compile() {<br />
make<br />
arm-angstrom-linux-gnueabi-strip .libs/vala-terminal<br />
}<br />
<br />
do_install() {<br />
install -d ${D}${bindir}<br />
install -d ${D}${datadir}/pixmaps<br />
install -d ${D}${datadir}/applications<br />
<br />
install ${WORKDIR}/vala-terminal-${PV}/.libs/vala-terminal ${D}${bindir}/<br />
install ${WORKDIR}/vala-terminal-${PV}/data/vala-terminal.png ${D}/${datadir}/pixmaps<br />
install ${WORKDIR}/vala-terminal-${PV}/data/vala-terminal.desktop ${D}${datadir}/applications<br />
}<br />
<br />
== Issues ==<br />
[[Image:Vala-terminal-debian.png|thumb| vala-terminal on Debian with white background]]<br />
If you have problems with the font on OM2008.12 (characters such as m, M, w, W, and @ overlap the character next to them), you probably missed ttf-liberation-mono -font. <br />
<br />
Any good font in repositories?<br />
<br />
How to use git in bitbake (rigth way)?<br />
<br />
How to install valac to the toolchain?<br />
<br />
Debians fontsize (5) is lots of smaller than OMs fontsize (5) (this can be handled with -fs size parameter)<br />
<br />
<onlyinclude><br />
{{ApplicationBox|<br />
Name=[[vala-terminal]]|<br />
Description=Terminal|<br />
Screenshot=Vala-terminal4.png|<br />
Homepage=http://git.freesmartphone.org/?p=vala-terminal.git|<br />
TestedOn=Om 2008.12, Debian|<br />
PackageName=[http://www.opkg.org/packages/vala-terminal_1.1.1-r0.1_armv4t.opk vala-terminal]<br />
}}<br />
</onlyinclude><br />
<br />
== Float Font Size ==<br />
<br />
The current verion of vala-terminal has integer font sizes. On a 284 dpi Freerunner I find that the best font size is somewhere between 3 and 4 (about 3.6 or 3.7 seems best). I wrote a patch for vala-terminal which makes the font size a floating point value and sets the default to 3.7. http://trac.hackable1.org/trac/ticket/340<br />
<br />
[[Category:System Applications]]</div>Stuarthttp://wiki.openmoko.org/wiki/Talk:TPO_TD028TTEC1Talk:TPO TD028TTEC12009-12-08T09:21:19Z<p>Stuart: </p>
<hr />
<div>The documentation for the TD028TTEC1 says "480xRGBx640". Does this mean that sub-pixels (red-green-blue-red-green-blue...) go across the screen when it is in portrait mode? Ie when the screen it is portait mode it is a RGB screen, when it is in landscape mode it is a VRGB screen?<br />
<br />
This could perhaps be noted as it is important to get the sub-pixel rendering right. I added "Xft.rgba:1" to my Xresources (for a FR in portrait mode) and found the characters to be better formed. I found these values in http://keithp.com/~keithp/talks/xtc2001/paper/. There are some screen shots http://trac.hackable1.org/trac/ticket/328</div>Stuarthttp://wiki.openmoko.org/wiki/Talk:TPO_TD028TTEC1Talk:TPO TD028TTEC12009-12-07T14:10:50Z<p>Stuart: 480xRGBx640 -> RGB/VRGB</p>
<hr />
<div>The documentation for the TD028TTEC1 says "480xRGBx640". Does this mean that sub-pixels (red-green-blue-red-green-blue...) go across the screen when it is in portrait mode? Ie when the screen it is portait mode it is a RGB screen, when it is in landscape mode it is a VRGB screen?<br />
<br />
This could perhaps be noted as it is important to get the sub-pixel aliasing right.</div>Stuarthttp://wiki.openmoko.org/wiki/Specialized_USB_cablesSpecialized USB cables2009-11-18T15:36:55Z<p>Stuart: /* Buy a USB cable for powering attached USB devices and charging the Freerunner while in host mode (aka Y-Cable) */</p>
<hr />
<div>{{note|work in progress}}<br />
<br />
== Attaching the Neo (acting as a USB host) to a USB device ==<br />
<br />
The USB port (5 position mini type B jack) on the Neo 1973 and Neo FreeRunner can be both a USB device or a USB host. The provided cable (5 position mini type B plug to type A plug) is used when attaching the Neo to a USB host.<br />
<br />
A specialized cable is required when attaching the Neo to a USB device. (The device has a USB type A jack).<br />
<br />
(picture)<br />
<br />
Alternately, an adapter capable of connecting two type A plugs will allow attaching the provided USB cable to the USB cable that came with the USB device. This adapter is also known as a gender changer.<br />
<br />
(picture)<br />
<br />
=== Ready-made mini type A plug to a type A jack adapter ===<br />
<br />
You can now purchase a proper [http://www.electronicproductonline.com/catalog/product_info.php?products_id=2043 custom-manufacturered mini-A to full-sized A USB adapter from here]. This adapter already has Pins 4 and 5 shorted together internally; the unique form factor also makes it very handy and eliminated the need for things like the double USB female adapter trick shown at the bottom of this page.<br />
<br />
[[Image:USBOTGSwivel.jpg]]<br />
<br />
=== Ready-made mini type B plug to a type A jack cable ===<br />
<br />
You can buy [[http://www.jaykang.com/usbafetousbm1.html this]] ready-made USB A-Type Female to USB Mini-B Type 5 Pin Male Adapter.<br />
[[Image:jaykang_usbafetousbm1.jpg|thumb|none]]<br />
<br />
It is available in Europe from Openmoko distributor Goldelico: http://www.handheld-linux.com/wiki.php?page=Neo%20Freerunner%3AUSB%20Adapter<br />
<br />
A Mini-B to Female-A cable is also available from [http://www.usbfirewire.com/Parts/rr-2mb-020.html www.usbfirewire.com].<br />
<br />
Adapter $1.45 including worldwide shipping, http://www.dealextreme.com/details.dx/sku.26783 --[[User:Schorhr|Schorhr]] 05:24, 16 September 2009 (UTC)<br />
<br />
=== How to make a mini type B plug to a type A jack cable ===<br />
<br />
(picture, as soon as I build it)<br />
<br />
Parts list:<br />
<br />
* Mini type B plug: Digi-Key [[http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail?name=H2958-ND H2958-ND]]<br />
* type A jack: I have not yet been able to find a source for these. Meanwhile, use the jack from a standard USB extension cord<br />
* Cable: Ideally, the data lines should be twisted and 28 AWG, the power lines should be 20 or 28 AWG, e.g. Hitachi Cable [[http://www.hcm.hitachi.com/electronic_round_cable/bulk-usb-cable.shtml 49248 ]]<br />
<br />
Construction instructions:<br />
<br />
(TBA)<br />
<br />
=== Ready-made type A jack to a type A jack adapter (gender changer) ===<br />
<br />
You can buy [[http://www.jaykang.com/usbtyfetotyf.html this]] ready-made USB Type A Female to Female Gender Changer.<br />
[[Image:jaykang_usbtyfetotyf.jpg|thumb|none]]<br />
<br />
=== How to make a type A jack to a type A jack adapter (gender changer) ===<br />
<br />
This community provided instruction shows how to build an adapter from a USB socket salvaged from a computer motherboard.<br />
<br />
Note that these instructions are provided in the hope that they are useful but without any warranty!<br />
<br />
[[Image:2-usb-receptables.jpg|thumb|none]]<br />
<br />
:#Find an old motherboard with a set of two USB receptacles as shown above.<br />
:#Desolder this set of receptacles from the motherboard. This can be bit tricky but it is doable at least with a desoldering gun. Solder braid (available at electronic parts stores including Radio Shack) works better than even a professional desoldering gun and is a lot cheaper.<br />
:#Each receptacle has four pins. Use a multimeter to verify that you have no short circuits between the pins or the shield.<br />
:#Solder adjacent pins together (GND to GND, D- to D-, D+ to D+, VCC to VCC).<br />
:#(Optional) Build a test cable. Cut an USB cable with A plug into half, connect it a receptacle and again measure that you have no short circuits. Then connect the test cable to PC and verify that you see<br />
*black GND<br />
*green 0V<br />
*white 0V<br />
*red +5V<br />
:#FreeRunner is shipped with a mini-B-to-A-plug cable. Connect this to a receptacle.<br />
:#(Optional)Connect test cable to the other receptacle and verify that you see<br />
*black GND<br />
*green 0V<br />
*white 0V<br />
*red 0V<br />
when freerunner acts as a device and<br />
*black GND<br />
*green 0V<br />
*white 0V<br />
*red +5V<br />
when it acts as a host.<br />
:#At your own risk, switch freerunner to USB host mode and connect an USB device to the other receptacle of the adapter. Here's how the setup should look like:<br />
<br />
<gallery><br />
Image:Usb-gender-changer1.jpg<br />
Image:Usb-gender-changer2.jpg<br />
</gallery><br />
<br />
=== How to make a type A jack to a type A jack adapter (gender changer) without soldering ===<br />
<br />
:#Find a 2-port USB front-panel with a 9-pin connector. Usually you can get one from a PC motherboard package box.<br />
:#Align it in a way so you see the connector pins as a 2 row 5 column matrix with one pin missing.<br />
:#Use 4 staples to short the pins residing in a same column.<br />
:#FreeRunner is shipped with a mini-B-to-A-plug cable. Use it to connect the first port of your panel with your FreeRunner.<br />
:#At your own risk, switch freerunner to USB host mode and connect an USB device to the other receptacle of the adapter.<br />
<br />
If you have a ASUS USB/MIR front panel, it is even easier - you can use jumpers to short the pins.<br />
<br />
[[Image:asususb.jpg]]<br />
<br />
=== Compatibility ===<br />
<br />
The adapter works with kingston data traveller 4G memory stick and aiptec pencam webcam. However, for some reason (probably the missing 15k resistors at D+ and D-) it did not work with any of the tested USB keyboards or mice:<br />
<pre><br />
usb 1-2: new full speed USB device using s3c2410-ohci and address 24<br />
usb 1-2: device descriptor read/64, error -62<br />
usb 1-2: device descriptor read/64, error -62<br />
usb 1-2: new full speed USB device using s3c2410-ohci and address 25<br />
usb 1-2: device descriptor read/64, error -62<br />
usb 1-2: device descriptor read/64, error -62<br />
usb 1-2: new full speed USB device using s3c2410-ohci and address 26<br />
usb 1-2: device not accepting address 26, error -62<br />
usb 1-2: new full speed USB device using s3c2410-ohci and address 27<br />
usb 1-2: device not accepting address 27, error -62<br />
</pre><br />
However, if I connect neo to small (unpowered) USB hub<br />
<pre><br />
usb 1-2: new full speed USB device using s3c2410-ohci and address 61<br />
usb 1-2: configuration #1 chosen from 1 choice<br />
hub 1-2:1.0: USB hub found<br />
hub 1-2:1.0: 4 ports detected<br />
</pre><br />
and connect the keyboard to the hub then it is correctly recognized:<br />
<pre><br />
usb 1-2.3: new low speed USB device using s3c2410-ohci and address 62<br />
usb 1-2.3: configuration #1 chosen from 1 choice<br />
input: USB Keyboard as /devices/platform/s3c2410-ohci/usb1/1-2/1-2.3/1-2.3:1.0/input/input13<br />
input: USB HID v1.10 Keyboard [ USB Keyboard] on usb-s3c24xx-2.3<br />
input: USB Keyboard as /devices/platform/s3c2410-ohci/usb1/1-2/1-2.3/1-2.3:1.1/input/input14<br />
input: USB HID v1.10 Device [ USB Keyboard] on usb-s3c24xx-2.3<br />
</pre><br />
With the hub I can also use both keyboard and usb memory stick at the same time.<br />
<br />
==== Power consumption ====<br />
<br />
When I unplug the USB hub (with only keyboard connected to it) the power consumption estimate at /sys/devices/platform/bq2700-battery.0/power_supply/bat/current_now decreases from 175000 to 145000 (are these microamperes?).<br />
<br />
== Buy a USB Y cable for powering USB devices and charging the Freerunner while in host mode ==<br />
<br />
You do not need to make a cable, you can just buy a "USB 2.0 Dual Power Cable, 2 x Type A to mini B" from [http://www.lindy.co.uk/1m-usb-2-dual-power-cable-2-x-type-a-50cm-apart-to-mini-b/31782.html lindy]. You then plug (via an adapter) the central plug of the Y cable into the upstream port (B socket or A plug) of your powered USB hub, the other A plug of the Y cable into one of the A sockets of your hub, and the mini-B plug of the Y cable into your Freerunner. Put your Freerunner into USB unpowered host mode. It will charge and you can plug a keyboard, a mouse, a disk, cable modem, etc, into the hub.<br />
<br />
Adapters, [http://www.rueducommerce.fr/Accessoires-Consommables/Cables-USB/Adaptateurs-convertisseurs/-/MO-35F4EM2168156-Adaptateur-Usb-type-A-Femelle-type-B-Male.htm A female to B male] or [http://www.rueducommerce.fr/Accessoires-Consommables/Cables-USB/Adaptateurs-convertisseurs/-/MO-B7A48M2167837-Changeur-Usb-type-A-Femelle-Femelle.htm A female to A female], are easy to find on the net. You will need a "A female to B male" if your hub has a type B socket or a "A female to A female" if your hub has a type A plug.<br />
<br />
== How to make a USB cable for powering attached USB devices and charging the Neo while in host mode (aka Y-Cable) ==<br />
<br />
{{note|work in progress}}<br />
<br />
This method was invented by [[User:JOERG|Joerg Reisenweber]], and was<br />
since implemented practically by many community members. See<br />
http://lists.openmoko.org/pipermail/community/2008-March/013978.html .<br />
<br />
---<br />
You can find some pictures (schematics, parts and part numbers<br />
at http://om.quatrox.org/om/ but be careful!!!<br />
Report any bugs to quatrox<br />
(irc #openmoko, #openmoko-cdevel, #ocp at freenode.org)<br />
---<br />
<br />
<br />
This cable might be necessary for a number of reasons, e.g.<br />
<br />
* The application requires that the Neo not become suspended<br />
* The application requires long run time<br />
* The attached USB device consumes a lot of power<br />
<br />
(However, as there is a wide range[http://permalink.gmane.org/gmane.comp.handhelds.openmoko.hardware/415]<br />
of USB hubs out there, one might find power (on a powered USB hub)<br />
is available already on the hub's mini USB 5 pin socket already, so not need a specialized cable after all!<br />
Check with a test meter.)<br />
<br />
These instructions will show you how to make a cable with 3 ends:<br />
<br />
* A mini-USB type B cable for the Neo itself<br />
* A cable of whatever type to go to your USB device.<br />
* A cable going to a +5V +/-10%(max!) power supply with enough power for your device and to charge the Neo. This could be a wall charger or even another USB plug.<br />
<br />
You connect the Data+ and Data- wires of the Neo and the device, and connect all of the ground wires together and all of the +5V wires together. This powers the Neo and the device, while letting the neo talk to the device.<br />
You have to connect 2 pcs 15k ohm resistors, one from D+ to ground, and one from D- to ground, to comply with USB-spec for hostmode, as Neo is switching off the internal resistors when you enable charging/powering over USB by asserting EN_USBHOST.<br />
See schematics, LOCATION:49XX<br />
<br />
Just for reference, the USB wires from left to right are:<br />
*Black: Power -<br />
*Green: Data -<br />
*White: Data +<br />
*Red: Power +<br />
<br />
The Mini_USB-B connector has a fifth pin, the ID-pin.<br />
This pin is supposed to be short to ground to signal FreeRunner to enter hostmode. For the Y-cable and enabling external power while in hostmode, you may connect a 47k ohm resistor from ID-pin to ground. This is the same trick the OM-wallcharger uses to signal to FreeRunner it can charge with 1A. Future kernels should switch to hostmode + external power when seeing this 47k resistor.<br />
<br />
===Parts===<br />
USB 2.0 Plug type A to mini 5 pin USB Plug type B that should include the ID signal, so that you can add the 47k ohm resistor to ID-pin to trigger fast charging<br />
<br />
# [http://www.firefold.com/Products/6-Foot-USB-20-Plug-type-A-to-mini-USB-Plug-type-B-5-pin-Cable---Black__USB-5PMINI-6.aspx firefold]<br />
# Belkin 5 pin (find reference)<br />
#https://www.argentdata.com/catalog/product_info.php?products_id=111<br />
#http://www.partsdata.de/USB_Mini-B-Verlaengerung_Kabel_1m_CU-XB05-10.html<br />
<br />
== USB hubs that can be used like a Y-cable without modifications ==<br />
<br />
[http://www.dealextreme.com/details.dx/sku.13526 Cable Style Dual-Power 1000mA USB 2.0 4-Port Hub]. Connect power source to the red upstream connector and openmoko to the black upstream connector. Then connect USB devices to the downstream ports. After settings usb_mode=host the openmoko will charge and will still be able to talk to the downstream ports.<br />
<br />
[[Category:USB]]<br />
[[Category:Neo FreeRunner Hardware]]</div>Stuarthttp://wiki.openmoko.org/wiki/Specialized_USB_cablesSpecialized USB cables2009-11-18T15:32:33Z<p>Stuart: </p>
<hr />
<div>{{note|work in progress}}<br />
<br />
== Attaching the Neo (acting as a USB host) to a USB device ==<br />
<br />
The USB port (5 position mini type B jack) on the Neo 1973 and Neo FreeRunner can be both a USB device or a USB host. The provided cable (5 position mini type B plug to type A plug) is used when attaching the Neo to a USB host.<br />
<br />
A specialized cable is required when attaching the Neo to a USB device. (The device has a USB type A jack).<br />
<br />
(picture)<br />
<br />
Alternately, an adapter capable of connecting two type A plugs will allow attaching the provided USB cable to the USB cable that came with the USB device. This adapter is also known as a gender changer.<br />
<br />
(picture)<br />
<br />
=== Ready-made mini type A plug to a type A jack adapter ===<br />
<br />
You can now purchase a proper [http://www.electronicproductonline.com/catalog/product_info.php?products_id=2043 custom-manufacturered mini-A to full-sized A USB adapter from here]. This adapter already has Pins 4 and 5 shorted together internally; the unique form factor also makes it very handy and eliminated the need for things like the double USB female adapter trick shown at the bottom of this page.<br />
<br />
[[Image:USBOTGSwivel.jpg]]<br />
<br />
=== Ready-made mini type B plug to a type A jack cable ===<br />
<br />
You can buy [[http://www.jaykang.com/usbafetousbm1.html this]] ready-made USB A-Type Female to USB Mini-B Type 5 Pin Male Adapter.<br />
[[Image:jaykang_usbafetousbm1.jpg|thumb|none]]<br />
<br />
It is available in Europe from Openmoko distributor Goldelico: http://www.handheld-linux.com/wiki.php?page=Neo%20Freerunner%3AUSB%20Adapter<br />
<br />
A Mini-B to Female-A cable is also available from [http://www.usbfirewire.com/Parts/rr-2mb-020.html www.usbfirewire.com].<br />
<br />
Adapter $1.45 including worldwide shipping, http://www.dealextreme.com/details.dx/sku.26783 --[[User:Schorhr|Schorhr]] 05:24, 16 September 2009 (UTC)<br />
<br />
=== How to make a mini type B plug to a type A jack cable ===<br />
<br />
(picture, as soon as I build it)<br />
<br />
Parts list:<br />
<br />
* Mini type B plug: Digi-Key [[http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail?name=H2958-ND H2958-ND]]<br />
* type A jack: I have not yet been able to find a source for these. Meanwhile, use the jack from a standard USB extension cord<br />
* Cable: Ideally, the data lines should be twisted and 28 AWG, the power lines should be 20 or 28 AWG, e.g. Hitachi Cable [[http://www.hcm.hitachi.com/electronic_round_cable/bulk-usb-cable.shtml 49248 ]]<br />
<br />
Construction instructions:<br />
<br />
(TBA)<br />
<br />
=== Ready-made type A jack to a type A jack adapter (gender changer) ===<br />
<br />
You can buy [[http://www.jaykang.com/usbtyfetotyf.html this]] ready-made USB Type A Female to Female Gender Changer.<br />
[[Image:jaykang_usbtyfetotyf.jpg|thumb|none]]<br />
<br />
=== How to make a type A jack to a type A jack adapter (gender changer) ===<br />
<br />
This community provided instruction shows how to build an adapter from a USB socket salvaged from a computer motherboard.<br />
<br />
Note that these instructions are provided in the hope that they are useful but without any warranty!<br />
<br />
[[Image:2-usb-receptables.jpg|thumb|none]]<br />
<br />
:#Find an old motherboard with a set of two USB receptacles as shown above.<br />
:#Desolder this set of receptacles from the motherboard. This can be bit tricky but it is doable at least with a desoldering gun. Solder braid (available at electronic parts stores including Radio Shack) works better than even a professional desoldering gun and is a lot cheaper.<br />
:#Each receptacle has four pins. Use a multimeter to verify that you have no short circuits between the pins or the shield.<br />
:#Solder adjacent pins together (GND to GND, D- to D-, D+ to D+, VCC to VCC).<br />
:#(Optional) Build a test cable. Cut an USB cable with A plug into half, connect it a receptacle and again measure that you have no short circuits. Then connect the test cable to PC and verify that you see<br />
*black GND<br />
*green 0V<br />
*white 0V<br />
*red +5V<br />
:#FreeRunner is shipped with a mini-B-to-A-plug cable. Connect this to a receptacle.<br />
:#(Optional)Connect test cable to the other receptacle and verify that you see<br />
*black GND<br />
*green 0V<br />
*white 0V<br />
*red 0V<br />
when freerunner acts as a device and<br />
*black GND<br />
*green 0V<br />
*white 0V<br />
*red +5V<br />
when it acts as a host.<br />
:#At your own risk, switch freerunner to USB host mode and connect an USB device to the other receptacle of the adapter. Here's how the setup should look like:<br />
<br />
<gallery><br />
Image:Usb-gender-changer1.jpg<br />
Image:Usb-gender-changer2.jpg<br />
</gallery><br />
<br />
=== How to make a type A jack to a type A jack adapter (gender changer) without soldering ===<br />
<br />
:#Find a 2-port USB front-panel with a 9-pin connector. Usually you can get one from a PC motherboard package box.<br />
:#Align it in a way so you see the connector pins as a 2 row 5 column matrix with one pin missing.<br />
:#Use 4 staples to short the pins residing in a same column.<br />
:#FreeRunner is shipped with a mini-B-to-A-plug cable. Use it to connect the first port of your panel with your FreeRunner.<br />
:#At your own risk, switch freerunner to USB host mode and connect an USB device to the other receptacle of the adapter.<br />
<br />
If you have a ASUS USB/MIR front panel, it is even easier - you can use jumpers to short the pins.<br />
<br />
[[Image:asususb.jpg]]<br />
<br />
=== Compatibility ===<br />
<br />
The adapter works with kingston data traveller 4G memory stick and aiptec pencam webcam. However, for some reason (probably the missing 15k resistors at D+ and D-) it did not work with any of the tested USB keyboards or mice:<br />
<pre><br />
usb 1-2: new full speed USB device using s3c2410-ohci and address 24<br />
usb 1-2: device descriptor read/64, error -62<br />
usb 1-2: device descriptor read/64, error -62<br />
usb 1-2: new full speed USB device using s3c2410-ohci and address 25<br />
usb 1-2: device descriptor read/64, error -62<br />
usb 1-2: device descriptor read/64, error -62<br />
usb 1-2: new full speed USB device using s3c2410-ohci and address 26<br />
usb 1-2: device not accepting address 26, error -62<br />
usb 1-2: new full speed USB device using s3c2410-ohci and address 27<br />
usb 1-2: device not accepting address 27, error -62<br />
</pre><br />
However, if I connect neo to small (unpowered) USB hub<br />
<pre><br />
usb 1-2: new full speed USB device using s3c2410-ohci and address 61<br />
usb 1-2: configuration #1 chosen from 1 choice<br />
hub 1-2:1.0: USB hub found<br />
hub 1-2:1.0: 4 ports detected<br />
</pre><br />
and connect the keyboard to the hub then it is correctly recognized:<br />
<pre><br />
usb 1-2.3: new low speed USB device using s3c2410-ohci and address 62<br />
usb 1-2.3: configuration #1 chosen from 1 choice<br />
input: USB Keyboard as /devices/platform/s3c2410-ohci/usb1/1-2/1-2.3/1-2.3:1.0/input/input13<br />
input: USB HID v1.10 Keyboard [ USB Keyboard] on usb-s3c24xx-2.3<br />
input: USB Keyboard as /devices/platform/s3c2410-ohci/usb1/1-2/1-2.3/1-2.3:1.1/input/input14<br />
input: USB HID v1.10 Device [ USB Keyboard] on usb-s3c24xx-2.3<br />
</pre><br />
With the hub I can also use both keyboard and usb memory stick at the same time.<br />
<br />
==== Power consumption ====<br />
<br />
When I unplug the USB hub (with only keyboard connected to it) the power consumption estimate at /sys/devices/platform/bq2700-battery.0/power_supply/bat/current_now decreases from 175000 to 145000 (are these microamperes?).<br />
<br />
== Buy a USB cable for powering attached USB devices and charging the Freerunner while in host mode (aka Y-Cable) ==<br />
<br />
You do not need to make a cable, you can just buy a "USB 2.0 Dual Power Cable, 2 x Type A to mini B" from [http://www.lindy.co.uk/1m-usb-2-dual-power-cable-2-x-type-a-50cm-apart-to-mini-b/31782.html lindy]. You then plug (via an adapter) the central plug of the Y cable into the upstream port (B socket or A plug) of your powered USB hub, the other A plug of the Y cable into one of the A sockets of your hub, and the mini-B plug of the Y cable into your Freerunner. Put your Freerunner into USB unpowered host mode. It will charge and you can plug a keyboard, a mouse, a disk, cable modem, etc, into the hub.<br />
<br />
Adapters, [http://www.rueducommerce.fr/Accessoires-Consommables/Cables-USB/Adaptateurs-convertisseurs/-/MO-35F4EM2168156-Adaptateur-Usb-type-A-Femelle-type-B-Male.htm A female to B male] or [http://www.rueducommerce.fr/Accessoires-Consommables/Cables-USB/Adaptateurs-convertisseurs/-/MO-B7A48M2167837-Changeur-Usb-type-A-Femelle-Femelle.htm A female to A female], are easy to find on the net. You will need a "A female to B male" if your hub has a type B socket or a "A female to A female" if your hub has a type A plug.<br />
<br />
== How to make a USB cable for powering attached USB devices and charging the Neo while in host mode (aka Y-Cable) ==<br />
<br />
{{note|work in progress}}<br />
<br />
This method was invented by [[User:JOERG|Joerg Reisenweber]], and was<br />
since implemented practically by many community members. See<br />
http://lists.openmoko.org/pipermail/community/2008-March/013978.html .<br />
<br />
---<br />
You can find some pictures (schematics, parts and part numbers<br />
at http://om.quatrox.org/om/ but be careful!!!<br />
Report any bugs to quatrox<br />
(irc #openmoko, #openmoko-cdevel, #ocp at freenode.org)<br />
---<br />
<br />
<br />
This cable might be necessary for a number of reasons, e.g.<br />
<br />
* The application requires that the Neo not become suspended<br />
* The application requires long run time<br />
* The attached USB device consumes a lot of power<br />
<br />
(However, as there is a wide range[http://permalink.gmane.org/gmane.comp.handhelds.openmoko.hardware/415]<br />
of USB hubs out there, one might find power (on a powered USB hub)<br />
is available already on the hub's mini USB 5 pin socket already, so not need a specialized cable after all!<br />
Check with a test meter.)<br />
<br />
These instructions will show you how to make a cable with 3 ends:<br />
<br />
* A mini-USB type B cable for the Neo itself<br />
* A cable of whatever type to go to your USB device.<br />
* A cable going to a +5V +/-10%(max!) power supply with enough power for your device and to charge the Neo. This could be a wall charger or even another USB plug.<br />
<br />
You connect the Data+ and Data- wires of the Neo and the device, and connect all of the ground wires together and all of the +5V wires together. This powers the Neo and the device, while letting the neo talk to the device.<br />
You have to connect 2 pcs 15k ohm resistors, one from D+ to ground, and one from D- to ground, to comply with USB-spec for hostmode, as Neo is switching off the internal resistors when you enable charging/powering over USB by asserting EN_USBHOST.<br />
See schematics, LOCATION:49XX<br />
<br />
Just for reference, the USB wires from left to right are:<br />
*Black: Power -<br />
*Green: Data -<br />
*White: Data +<br />
*Red: Power +<br />
<br />
The Mini_USB-B connector has a fifth pin, the ID-pin.<br />
This pin is supposed to be short to ground to signal FreeRunner to enter hostmode. For the Y-cable and enabling external power while in hostmode, you may connect a 47k ohm resistor from ID-pin to ground. This is the same trick the OM-wallcharger uses to signal to FreeRunner it can charge with 1A. Future kernels should switch to hostmode + external power when seeing this 47k resistor.<br />
<br />
===Parts===<br />
USB 2.0 Plug type A to mini 5 pin USB Plug type B that should include the ID signal, so that you can add the 47k ohm resistor to ID-pin to trigger fast charging<br />
<br />
# [http://www.firefold.com/Products/6-Foot-USB-20-Plug-type-A-to-mini-USB-Plug-type-B-5-pin-Cable---Black__USB-5PMINI-6.aspx firefold]<br />
# Belkin 5 pin (find reference)<br />
#https://www.argentdata.com/catalog/product_info.php?products_id=111<br />
#http://www.partsdata.de/USB_Mini-B-Verlaengerung_Kabel_1m_CU-XB05-10.html<br />
<br />
== USB hubs that can be used like a Y-cable without modifications ==<br />
<br />
[http://www.dealextreme.com/details.dx/sku.13526 Cable Style Dual-Power 1000mA USB 2.0 4-Port Hub]. Connect power source to the red upstream connector and openmoko to the black upstream connector. Then connect USB devices to the downstream ports. After settings usb_mode=host the openmoko will charge and will still be able to talk to the downstream ports.<br />
<br />
[[Category:USB]]<br />
[[Category:Neo FreeRunner Hardware]]</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-10-01T10:25:14Z<p>Stuart: /* Dropbear */</p>
<hr />
<div>Just a list of rather random comments used mainly as a bloc notes for me. Please send me any<br />
comments -- Stuart Pook.<br />
<br />
=== /etc/network/interfaces ===<br />
The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
I replaced dropbear with openssh-server.<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre><br />
<br />
=== mokomaze ===<br />
Mokomaze does not work if you are not root. To fix (let me know if this is not right)<br />
<pre><br />
chmod 666 /dev/input/event3 /sys/class/leds/neo1973:vibrator/brightness<br />
</pre><br />
<br />
=== rxvt-unicode ===<br />
to get a nice small font (but not too small), ~/.Xresources should contain<br />
<pre><br />
URxvt*font: xft:DejaVu Sans Mono:size=4.0<br />
</pre><br />
Vala-terminal is better.<br />
<br />
=== network configuration when USB pluged-in ===<br />
I want to run a program when I plug the USB in. This program will try to workout where<br />
I am and setup the domain and http proxy correctly. A script can be run my creating<br />
<code>/etc/udev/rules.d/00-usb-stuart.rules<code><br />
<pre><br />
ENV{POWER_SUPPLY_ONLINE}=="1", KERNEL=="usb", RUN+="/bin/sh -c /etc/network/proxy-setup&"<br />
</pre><br />
This script is run twice (and perhaps in parallel) so be careful.<br />
<br />
=== http proxy and /etc/resolv.conf setup ===<br />
This is my first script to automatically set the http and ftp proxies.<br />
It also sets the domain so that smtp resolves to a working smtp server.<br />
At the moment I am only using USB networking<br />
and this program will have to be modified if I want to use both at once.<br />
<pre><br />
#!/bin/dash<br />
# written by Stuart Pook<br />
#(/bin/date; echo "$@"; env) >> /tmp/RUN<br />
<br />
usb_ip=$(/sbin/ifconfig usb0 | sed -ne 's/ inet addr:\([0-9.]*\) .*/\1/p')<br />
[ "$usb_ip" ] || exit 1<br />
<br />
rule=OUTPUT<br />
table=nat<br />
<br />
domain1=example.org<br />
set -- $(host www-cache-in.$domain1)<br />
machine1=$4<br />
port1=3128<br />
if netcat -s $usb_ip -z $machine1 $port1<br />
then<br />
proxy=$machine1:$port1<br />
domain=$domain1<br />
else<br />
proxy=127.0.0.1:8888<br />
domain=free.fr<br />
fi<br />
date "+nameserver 192.168.0.200%ndomain $domain%n# %c $ACTION $POWER_SUPPLY_ONLINE $SUBSYSTEM $POWER_SUPPLY_NAME" > /etc/resolv.conf<br />
<br />
env=/etc/environment<br />
[ -r $env ] && . $env<br />
<br />
[ "$http_proxy" ] || exit 1<br />
<br />
set -- $(sed -n -e "s .* $http_proxy " -e 's@http://\([0-9][0-9.]*[0-9]\):\([0-9][0-9]*\)@\1 \2@p' -e q /etc/passwd)<br />
dest=$1<br />
port=$2<br />
[ "$dest" -a "$port" ] || exit 1<br />
iptables -t $table -F $rule<br />
iptables -t $table -I $rule --protocol tcp --dst $dest --dport $port -j DNAT --to-destination $proxy<br />
</pre><br />
<code>/etc/environment</code> contains a junk http proxy address and iptables is used to redirect this to a remote proxy if one is required or a proxy on the Freerunner. This avoids using the proxy on the Freerunner if a remote proxy is available and allows me to change the proxy for running programs.<br />
<pre><br />
http_proxy=http://14.255.14.250:542<br />
ftp_proxy=http://14.255.14.250:542<br />
</pre><br />
<br />
=== wicd Network Manager ===<br />
wicd works except thatit uses too much cpu time when the gui is open. [http://wicd.net/punbb/viewtopic.php?pid=2856 forum question]<br />
<br />
== references ==<br />
[[User:JohnSullivan]]</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-10-01T10:22:10Z<p>Stuart: /* Configuring Debian */</p>
<hr />
<div>Just a list of rather random comments used mainly as a bloc notes for me. Please send me any<br />
comments -- Stuart Pook.<br />
<br />
=== /etc/network/interfaces ===<br />
The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre><br />
<br />
=== mokomaze ===<br />
Mokomaze does not work if you are not root. To fix (let me know if this is not right)<br />
<pre><br />
chmod 666 /dev/input/event3 /sys/class/leds/neo1973:vibrator/brightness<br />
</pre><br />
<br />
=== rxvt-unicode ===<br />
to get a nice small font (but not too small), ~/.Xresources should contain<br />
<pre><br />
URxvt*font: xft:DejaVu Sans Mono:size=4.0<br />
</pre><br />
Vala-terminal is better.<br />
<br />
=== network configuration when USB pluged-in ===<br />
I want to run a program when I plug the USB in. This program will try to workout where<br />
I am and setup the domain and http proxy correctly. A script can be run my creating<br />
<code>/etc/udev/rules.d/00-usb-stuart.rules<code><br />
<pre><br />
ENV{POWER_SUPPLY_ONLINE}=="1", KERNEL=="usb", RUN+="/bin/sh -c /etc/network/proxy-setup&"<br />
</pre><br />
This script is run twice (and perhaps in parallel) so be careful.<br />
<br />
=== http proxy and /etc/resolv.conf setup ===<br />
This is my first script to automatically set the http and ftp proxies.<br />
It also sets the domain so that smtp resolves to a working smtp server.<br />
At the moment I am only using USB networking<br />
and this program will have to be modified if I want to use both at once.<br />
<pre><br />
#!/bin/dash<br />
# written by Stuart Pook<br />
#(/bin/date; echo "$@"; env) >> /tmp/RUN<br />
<br />
usb_ip=$(/sbin/ifconfig usb0 | sed -ne 's/ inet addr:\([0-9.]*\) .*/\1/p')<br />
[ "$usb_ip" ] || exit 1<br />
<br />
rule=OUTPUT<br />
table=nat<br />
<br />
domain1=example.org<br />
set -- $(host www-cache-in.$domain1)<br />
machine1=$4<br />
port1=3128<br />
if netcat -s $usb_ip -z $machine1 $port1<br />
then<br />
proxy=$machine1:$port1<br />
domain=$domain1<br />
else<br />
proxy=127.0.0.1:8888<br />
domain=free.fr<br />
fi<br />
date "+nameserver 192.168.0.200%ndomain $domain%n# %c $ACTION $POWER_SUPPLY_ONLINE $SUBSYSTEM $POWER_SUPPLY_NAME" > /etc/resolv.conf<br />
<br />
env=/etc/environment<br />
[ -r $env ] && . $env<br />
<br />
[ "$http_proxy" ] || exit 1<br />
<br />
set -- $(sed -n -e "s .* $http_proxy " -e 's@http://\([0-9][0-9.]*[0-9]\):\([0-9][0-9]*\)@\1 \2@p' -e q /etc/passwd)<br />
dest=$1<br />
port=$2<br />
[ "$dest" -a "$port" ] || exit 1<br />
iptables -t $table -F $rule<br />
iptables -t $table -I $rule --protocol tcp --dst $dest --dport $port -j DNAT --to-destination $proxy<br />
</pre><br />
<code>/etc/environment</code> contains a junk http proxy address and iptables is used to redirect this to a remote proxy if one is required or a proxy on the Freerunner. This avoids using the proxy on the Freerunner if a remote proxy is available and allows me to change the proxy for running programs.<br />
<pre><br />
http_proxy=http://14.255.14.250:542<br />
ftp_proxy=http://14.255.14.250:542<br />
</pre><br />
<br />
=== wicd Network Manager ===<br />
wicd works except thatit uses too much cpu time when the gui is open. [http://wicd.net/punbb/viewtopic.php?pid=2856 forum question]<br />
<br />
== references ==<br />
[[User:JohnSullivan]]</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-10-01T10:19:46Z<p>Stuart: /* rxvt-unicode */</p>
<hr />
<div>Just a list of rather random comments used mainly as a bloc notes for me. Please send me any<br />
comments -- Stuart Pook.<br />
<br />
=== /etc/network/interfaces ===<br />
The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre><br />
<br />
=== mokomaze ===<br />
Mokomaze does not work if you are not root. To fix (let me know if this is not right)<br />
<pre><br />
chmod 666 /dev/input/event3 /sys/class/leds/neo1973:vibrator/brightness<br />
</pre><br />
<br />
=== rxvt-unicode ===<br />
to get a nice small font (but not too small), ~/.Xresources should contain<br />
<pre><br />
URxvt*font: xft:DejaVu Sans Mono:size=4.0<br />
</pre><br />
Vala-terminal is better.<br />
<br />
=== network configuration when USB pluged-in ===<br />
I want to run a program when I plug the USB in. This program will try to workout where<br />
I am and setup the domain and http proxy correctly. A script can be run my creating<br />
<code>/etc/udev/rules.d/00-usb-stuart.rules<code><br />
<pre><br />
ENV{POWER_SUPPLY_ONLINE}=="1", KERNEL=="usb", RUN+="/bin/sh -c /etc/network/proxy-setup&"<br />
</pre><br />
This script is run twice (and perhaps in parallel) so be careful.<br />
<br />
=== http proxy and /etc/resolv.conf setup ===<br />
This is my first script to automatically set the http and ftp proxies.<br />
It also sets the domain so that smtp resolves to a working smtp server.<br />
At the moment I am only using USB networking<br />
and this program will have to be modified if I want to use both at once.<br />
<pre><br />
#!/bin/dash<br />
# written by Stuart Pook<br />
#(/bin/date; echo "$@"; env) >> /tmp/RUN<br />
<br />
usb_ip=$(/sbin/ifconfig usb0 | sed -ne 's/ inet addr:\([0-9.]*\) .*/\1/p')<br />
[ "$usb_ip" ] || exit 1<br />
<br />
rule=OUTPUT<br />
table=nat<br />
<br />
domain1=example.org<br />
set -- $(host www-cache-in.$domain1)<br />
machine1=$4<br />
port1=3128<br />
if netcat -s $usb_ip -z $machine1 $port1<br />
then<br />
proxy=$machine1:$port1<br />
domain=$domain1<br />
else<br />
proxy=127.0.0.1:8888<br />
domain=free.fr<br />
fi<br />
date "+nameserver 192.168.0.200%ndomain $domain%n# %c $ACTION $POWER_SUPPLY_ONLINE $SUBSYSTEM $POWER_SUPPLY_NAME" > /etc/resolv.conf<br />
<br />
env=/etc/environment<br />
[ -r $env ] && . $env<br />
<br />
[ "$http_proxy" ] || exit 1<br />
<br />
set -- $(sed -n -e "s .* $http_proxy " -e 's@http://\([0-9][0-9.]*[0-9]\):\([0-9][0-9]*\)@\1 \2@p' -e q /etc/passwd)<br />
dest=$1<br />
port=$2<br />
[ "$dest" -a "$port" ] || exit 1<br />
iptables -t $table -F $rule<br />
iptables -t $table -I $rule --protocol tcp --dst $dest --dport $port -j DNAT --to-destination $proxy<br />
</pre><br />
<code>/etc/environment</code> contains a junk http proxy address and iptables is used to redirect this to a remote proxy if one is required or a proxy on the Freerunner. This avoids using the proxy on the Freerunner if a remote proxy is available and allows me to change the proxy for running programs.<br />
<pre><br />
http_proxy=http://14.255.14.250:542<br />
ftp_proxy=http://14.255.14.250:542<br />
</pre><br />
<br />
== references ==<br />
[[User:JohnSullivan]]</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-09-25T10:28:28Z<p>Stuart: </p>
<hr />
<div>Just a list of rather random comments used mainly as a bloc notes for me. Please send me any<br />
comments -- Stuart Pook.<br />
<br />
=== /etc/network/interfaces ===<br />
The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre><br />
<br />
=== mokomaze ===<br />
Mokomaze does not work if you are not root. To fix (let me know if this is not right)<br />
<pre><br />
chmod 666 /dev/input/event3 /sys/class/leds/neo1973:vibrator/brightness<br />
</pre><br />
<br />
=== rxvt-unicode ===<br />
to get a nice small font (but not too small), ~/.Xresources should contain<br />
<pre><br />
URxvt*font: xft:DejaVu Sans Mono:size=4.0<br />
</pre><br />
<br />
=== network configuration when USB pluged-in ===<br />
I want to run a program when I plug the USB in. This program will try to workout where<br />
I am and setup the domain and http proxy correctly. A script can be run my creating<br />
<code>/etc/udev/rules.d/00-usb-stuart.rules<code><br />
<pre><br />
ENV{POWER_SUPPLY_ONLINE}=="1", KERNEL=="usb", RUN+="/bin/sh -c /etc/network/proxy-setup&"<br />
</pre><br />
This script is run twice (and perhaps in parallel) so be careful.<br />
<br />
=== http proxy and /etc/resolv.conf setup ===<br />
This is my first script to automatically set the http and ftp proxies.<br />
It also sets the domain so that smtp resolves to a working smtp server.<br />
At the moment I am only using USB networking<br />
and this program will have to be modified if I want to use both at once.<br />
<pre><br />
#!/bin/dash<br />
# written by Stuart Pook<br />
#(/bin/date; echo "$@"; env) >> /tmp/RUN<br />
<br />
usb_ip=$(/sbin/ifconfig usb0 | sed -ne 's/ inet addr:\([0-9.]*\) .*/\1/p')<br />
[ "$usb_ip" ] || exit 1<br />
<br />
rule=OUTPUT<br />
table=nat<br />
<br />
domain1=example.org<br />
set -- $(host www-cache-in.$domain1)<br />
machine1=$4<br />
port1=3128<br />
if netcat -s $usb_ip -z $machine1 $port1<br />
then<br />
proxy=$machine1:$port1<br />
domain=$domain1<br />
else<br />
proxy=127.0.0.1:8888<br />
domain=free.fr<br />
fi<br />
date "+nameserver 192.168.0.200%ndomain $domain%n# %c $ACTION $POWER_SUPPLY_ONLINE $SUBSYSTEM $POWER_SUPPLY_NAME" > /etc/resolv.conf<br />
<br />
env=/etc/environment<br />
[ -r $env ] && . $env<br />
<br />
[ "$http_proxy" ] || exit 1<br />
<br />
set -- $(sed -n -e "s .* $http_proxy " -e 's@http://\([0-9][0-9.]*[0-9]\):\([0-9][0-9]*\)@\1 \2@p' -e q /etc/passwd)<br />
dest=$1<br />
port=$2<br />
[ "$dest" -a "$port" ] || exit 1<br />
iptables -t $table -F $rule<br />
iptables -t $table -I $rule --protocol tcp --dst $dest --dport $port -j DNAT --to-destination $proxy<br />
</pre><br />
<code>/etc/environment</code> contains a junk http proxy address and iptables is used to redirect this to a remote proxy if one is required or a proxy on the Freerunner. This avoids using the proxy on the Freerunner if a remote proxy is available and allows me to change the proxy for running programs.<br />
<pre><br />
http_proxy=http://14.255.14.250:542<br />
ftp_proxy=http://14.255.14.250:542<br />
</pre><br />
<br />
== references ==<br />
[[User:JohnSullivan]]</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-09-25T10:27:47Z<p>Stuart: </p>
<hr />
<div>Just a list of rather random comments used mainly as a block notes for me. Please send me any<br />
comments -- Stuart Pook.<br />
<br />
=== /etc/network/interfaces ===<br />
The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre><br />
<br />
=== mokomaze ===<br />
Mokomaze does not work if you are not root. To fix (let me know if this is not right)<br />
<pre><br />
chmod 666 /dev/input/event3 /sys/class/leds/neo1973:vibrator/brightness<br />
</pre><br />
<br />
=== rxvt-unicode ===<br />
to get a nice small font (but not too small), ~/.Xresources should contain<br />
<pre><br />
URxvt*font: xft:DejaVu Sans Mono:size=4.0<br />
</pre><br />
<br />
=== network configuration when USB pluged-in ===<br />
I want to run a program when I plug the USB in. This program will try to workout where<br />
I am and setup the domain and http proxy correctly. A script can be run my creating<br />
<code>/etc/udev/rules.d/00-usb-stuart.rules<code><br />
<pre><br />
ENV{POWER_SUPPLY_ONLINE}=="1", KERNEL=="usb", RUN+="/bin/sh -c /etc/network/proxy-setup&"<br />
</pre><br />
This script is run twice (and perhaps in parallel) so be careful.<br />
<br />
=== http proxy and /etc/resolv.conf setup ===<br />
This is my first script to automatically set the http and ftp proxies.<br />
It also sets the domain so that smtp resolves to a working smtp server.<br />
At the moment I am only using USB networking<br />
and this program will have to be modified if I want to use both at once.<br />
<pre><br />
#!/bin/dash<br />
# written by Stuart Pook<br />
#(/bin/date; echo "$@"; env) >> /tmp/RUN<br />
<br />
usb_ip=$(/sbin/ifconfig usb0 | sed -ne 's/ inet addr:\([0-9.]*\) .*/\1/p')<br />
[ "$usb_ip" ] || exit 1<br />
<br />
rule=OUTPUT<br />
table=nat<br />
<br />
domain1=example.org<br />
set -- $(host www-cache-in.$domain1)<br />
machine1=$4<br />
port1=3128<br />
if netcat -s $usb_ip -z $machine1 $port1<br />
then<br />
proxy=$machine1:$port1<br />
domain=$domain1<br />
else<br />
proxy=127.0.0.1:8888<br />
domain=free.fr<br />
fi<br />
date "+nameserver 192.168.0.200%ndomain $domain%n# %c $ACTION $POWER_SUPPLY_ONLINE $SUBSYSTEM $POWER_SUPPLY_NAME" > /etc/resolv.conf<br />
<br />
env=/etc/environment<br />
[ -r $env ] && . $env<br />
<br />
[ "$http_proxy" ] || exit 1<br />
<br />
set -- $(sed -n -e "s .* $http_proxy " -e 's@http://\([0-9][0-9.]*[0-9]\):\([0-9][0-9]*\)@\1 \2@p' -e q /etc/passwd)<br />
dest=$1<br />
port=$2<br />
[ "$dest" -a "$port" ] || exit 1<br />
iptables -t $table -F $rule<br />
iptables -t $table -I $rule --protocol tcp --dst $dest --dport $port -j DNAT --to-destination $proxy<br />
</pre><br />
<code>/etc/environment</code> contains a junk http proxy address and iptables is used to redirect this to a remote proxy if one is required or a proxy on the Freerunner. This avoids using the proxy on the Freerunner if a remote proxy is available and allows me to change the proxy for running programs.<br />
<pre><br />
http_proxy=http://14.255.14.250:542<br />
ftp_proxy=http://14.255.14.250:542<br />
</pre><br />
<br />
== references ==<br />
[[User:JohnSullivan]]</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-09-25T10:22:21Z<p>Stuart: /* http proxy and /etc/resolv.conf setup */</p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre><br />
<br />
=== mokomaze ===<br />
Mokomaze does not work if you are not root. To fix (let me know if this is not right)<br />
<pre><br />
chmod 666 /dev/input/event3 /sys/class/leds/neo1973:vibrator/brightness<br />
</pre><br />
<br />
=== rxvt-unicode ===<br />
to get a nice small font (but not too small), ~/.Xresources should contain<br />
<pre><br />
URxvt*font: xft:DejaVu Sans Mono:size=4.0<br />
</pre><br />
<br />
=== network configuration when USB pluged-in ===<br />
I want to run a program when I plug the USB in. This program will try to workout where<br />
I am and setup the domain and http proxy correctly. A script can be run my creating<br />
<code>/etc/udev/rules.d/00-usb-stuart.rules<code><br />
<pre><br />
ENV{POWER_SUPPLY_ONLINE}=="1", KERNEL=="usb", RUN+="/bin/sh -c /etc/network/proxy-setup&"<br />
</pre><br />
This script is run twice (and perhaps in parallel) so be careful.<br />
<br />
=== http proxy and /etc/resolv.conf setup ===<br />
This is my first script to automatically set the http and ftp proxies.<br />
It also sets the domain so that smtp resolves to a working smtp server.<br />
At the moment I am only using USB networking<br />
and this program will have to be modified if I want to use both at once.<br />
<pre><br />
#!/bin/dash<br />
# written by Stuart Pook<br />
#(/bin/date; echo "$@"; env) >> /tmp/RUN<br />
<br />
usb_ip=$(/sbin/ifconfig usb0 | sed -ne 's/ inet addr:\([0-9.]*\) .*/\1/p')<br />
[ "$usb_ip" ] || exit 1<br />
<br />
rule=OUTPUT<br />
table=nat<br />
<br />
domain1=example.org<br />
set -- $(host www-cache-in.$domain1)<br />
machine1=$4<br />
port1=3128<br />
if netcat -s $usb_ip -z $machine1 $port1<br />
then<br />
proxy=$machine1:$port1<br />
domain=$domain1<br />
else<br />
proxy=127.0.0.1:8888<br />
domain=free.fr<br />
fi<br />
date "+nameserver 192.168.0.200%ndomain $domain%n# %c $ACTION $POWER_SUPPLY_ONLINE $SUBSYSTEM $POWER_SUPPLY_NAME" > /etc/resolv.conf<br />
<br />
env=/etc/environment<br />
[ -r $env ] && . $env<br />
<br />
[ "$http_proxy" ] || exit 1<br />
<br />
set -- $(sed -n -e "s .* $http_proxy " -e 's@http://\([0-9][0-9.]*[0-9]\):\([0-9][0-9]*\)@\1 \2@p' -e q /etc/passwd)<br />
dest=$1<br />
port=$2<br />
[ "$dest" -a "$port" ] || exit 1<br />
iptables -t $table -F $rule<br />
iptables -t $table -I $rule --protocol tcp --dst $dest --dport $port -j DNAT --to-destination $proxy<br />
</pre><br />
<code>/etc/environment</code> contains a junk http proxy address and iptables is used to redirect this to a remote proxy if one is required or a proxy on the Freerunner. This avoids using the proxy on the Freerunner if a remote proxy is available and allows me to change the proxy for running programs.<br />
<pre><br />
http_proxy=http://14.255.14.250:542<br />
ftp_proxy=http://14.255.14.250:542<br />
</pre><br />
<br />
== references ==<br />
[[User:JohnSullivan]]</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-09-25T10:19:54Z<p>Stuart: /* Configuring Debian */</p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre><br />
<br />
=== mokomaze ===<br />
Mokomaze does not work if you are not root. To fix (let me know if this is not right)<br />
<pre><br />
chmod 666 /dev/input/event3 /sys/class/leds/neo1973:vibrator/brightness<br />
</pre><br />
<br />
=== rxvt-unicode ===<br />
to get a nice small font (but not too small), ~/.Xresources should contain<br />
<pre><br />
URxvt*font: xft:DejaVu Sans Mono:size=4.0<br />
</pre><br />
<br />
=== network configuration when USB pluged-in ===<br />
I want to run a program when I plug the USB in. This program will try to workout where<br />
I am and setup the domain and http proxy correctly. A script can be run my creating<br />
<code>/etc/udev/rules.d/00-usb-stuart.rules<code><br />
<pre><br />
ENV{POWER_SUPPLY_ONLINE}=="1", KERNEL=="usb", RUN+="/bin/sh -c /etc/network/proxy-setup&"<br />
</pre><br />
This script is run twice (and perhaps in parallel) so be careful.<br />
<br />
=== http proxy and /etc/resolv.conf setup ===<br />
This is my first script to automatically set the http and ftp proxies.<br />
It also sets the domain so that smtp resolves to a working smtp server.<br />
At the moment I am only using USB networking<br />
and this program will have to be modified if I want to use both at once.<br />
<pre><br />
#!/bin/dash<br />
# written by Stuart Pook<br />
#(/bin/date; echo "$@"; env) >> /tmp/RUN<br />
<br />
usb_ip=$(/sbin/ifconfig usb0 | sed -ne 's/ inet addr:\([0-9.]*\) .*/\1/p')<br />
[ "$usb_ip" ] || exit 1<br />
<br />
rule=OUTPUT<br />
table=nat<br />
<br />
domain1=example.org<br />
set -- $(host www-cache-in.$domain1)<br />
machine1=$4<br />
port1=3128<br />
if netcat -s $usb_ip -z $machine1 $port1<br />
then<br />
proxy=$machine1:$port1<br />
domain=$domain1<br />
else<br />
proxy=127.0.0.1:8888<br />
domain=free.fr<br />
fi<br />
date "+nameserver 192.168.0.200%ndomain $domain%n# %c $ACTION $POWER_SUPPLY_ONLINE $SUBSYSTEM $POWER_SUPPLY_NAME" > /etc/resolv.conf<br />
<br />
env=/etc/environment<br />
[ -r $env ] && . $env<br />
<br />
[ "$http_proxy" ] || exit 1<br />
<br />
set -- $(sed -n -e "s .* $http_proxy " -e 's@http://\([0-9][0-9.]*[0-9]\):\([0-9][0-9]*\)@\1 \2@p' -e q /etc/passwd)<br />
dest=$1<br />
port=$2<br />
iptables -t $table -F $rule<br />
iptables -t $table -I $rule --protocol tcp --dst $dest --dport $port -j DNAT --to-destination $proxy<br />
</pre><br />
<code>/etc/environment</code> contains a junk http proxy address and iptables is used to redirect this to a remote proxy if one is required or a proxy on the Freerunner. This avoids using the proxy on the Freerunner if a remote proxy is available and allows me to change the proxy for running programs.<br />
<pre><br />
http_proxy=http://14.255.14.250:542<br />
ftp_proxy=http://14.255.14.250:542<br />
</pre><br />
<br />
== references ==<br />
[[User:JohnSullivan]]</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-21T15:03:20Z<p>Stuart: /* Configuring Debian */</p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre><br />
<br />
=== mokomaze ===<br />
Mokomaze does not work if you are not root. To fix (let me know if this is not right)<br />
<pre><br />
chmod 666 /dev/input/event3 /sys/class/leds/neo1973:vibrator/brightness<br />
</pre><br />
<br />
=== rxvt-unicode ===<br />
to get a nice small font (but not too small), ~/.Xresources should contain<br />
<pre><br />
URxvt*font: xft:DejaVu Sans Mono:size=4.0<br />
</pre><br />
<br />
== references ==<br />
[[User:JohnSullivan]]</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-21T13:32:52Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre><br />
<br />
=== mokomaze ===<br />
Mokomaze does not work if you are not root. To fix (let me know if this is not right)<br />
<pre><br />
chmod 666 /dev/input/event3 /sys/class/leds/neo1973:vibrator/brightness<br />
</pre><br />
<br />
== references ==<br />
[[User:JohnSullivan]]</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-21T13:22:36Z<p>Stuart: /* Configuring Debian */</p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre><br />
<br />
=== mokomaze ===<br />
Mokomaze does not work if you are not root. To fix (let me know if this is not right)<br />
<pre><br />
chmod 666 /dev/input/event3 /sys/class/leds/neo1973:vibrator/brightness<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-20T10:19:29Z<p>Stuart: /* Configuring Debian */</p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.<br />
<br />
Connman does not appears to start at boot. Try<br />
<pre>cd /etc/rc2.d && mv S01connman S10connman<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-20T09:35:53Z<p>Stuart: /* Configuring Debian */</p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626<br />
<br />
=== connman ===<br />
<br />
Install <code>connman</code> and edit /etc/dbus-1/system.d/connman.conf to replace <code>user="root"</code> with <code>group="messagebus"</code> otherwise you get the messages<br />
<pre><br />
wifi.py 98 wifi WARNING can't use wifi service : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
service.py 128 Service ERROR Can't init service Wifi : org.moblin.connman.Error.PermissionDenied: Permission denied<br />
</pre><br />
if you do not run as root.</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-18T08:13:21Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
=== Dropbear ===<br />
Dropbear looks for /usr/X11R6/bin/xauth [[http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532900 Debian bug]] but xauth is in /usr/bin/xauth and /usr/bin/X11/xauth. Make a symlink.<br />
<pre><br />
ln -s . /usr/X11R6<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T17:13:02Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre><br />
<br />
Need to read http://wiki.debian.org/DebianOnFreeRunnerTips and http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=500626</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T13:39:08Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T13:38:12Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a touchscreen that works.<br />
=== Cleanup ===<br />
<pre><br />
# apt-get remove xserver-xorg-input-wacom xserver-xorg-video-fbdev<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T13:34:02Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
=== Touchscreen ===<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests<br />
<pre><br />
# apt-get remove xserver-xorg-input-synaptics<br />
</pre><br />
<br />
Did <code>apt-get install xserver-xglamo</code> then ran /usr/bin/Xglamo which says<br />
<pre><br />
Failed to open TSLib device, tried /dev/ts /dev/touchscreen/0 .<br />
Try setting TSLIB_TSDEVICE to valid /dev entry?<br />
</pre><br />
Ok, a link <code>ln -s input/touchscreen0 /dev/ts</code>. /usr/bin/Xglamo works, update /etc/X11/xorg.conf [[Debian#Xglamo_acceleration]] and I have a toucscreen that works.</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T13:03:30Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Make a tar of /mnt/debian so that I don't have to go through all this agian.<br />
<br />
== Configuring Debian ==<br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<pre><br />
xres = 480, yres = 640<br />
</pre><br />
I can see the cross-hairs but clicking does nothing. Ok, you need to stop the Xserver before calibrating.<br />
<pre><br />
# /etc/init.d/nodm stop<br />
TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate<br />
xres = 480, yres = 640<br />
Took 15 samples...<br />
Top left : X = 858 Y = 201<br />
Took 2 samples...<br />
Top right : X = 854 Y = 840<br />
Took 9 samples...<br />
Bot right : X = 160 Y = 840<br />
Took 11 samples...<br />
Bot left : X = 162 Y = 196<br />
Took 18 samples...<br />
Center : X = 509 Y = 513<br />
-65.726501 -0.002131 0.592298<br />
717.045288 -0.776964 -0.003633<br />
Calibration constants: -4307452 -139 38816 46992280 -50919 -238 65536 <br />
# echo -4307452 -139 38816 46992280 -50919 -238 65536 > /etc/pointercal <br />
# /etc/init.d/nodm start<br />
</pre><br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests removing xserver-xorg-input-synaptics. Now Xorg.0.log says<br />
<pre><br />
(II) config/hal: Adding input device s3c2410 TouchScreen<br />
(**) s3c2410 TouchScreen: always reports core events<br />
(II) XINPUT: Adding extended input device "s3c2410 TouchScreen" (type: TOUCHSCREEN)<br />
</pre><br />
and tapping the screen switches it on but still no luck in doing any actions. Let's restore /etc/pointercal<br />
<pre><br />
# echo 557 38667 -4654632 -51172 121 46965312 65536 > /etc/pointercal<br />
# /etc/init.d/nodm restart<br />
</pre><br />
now I have a screen that works. It broke again. Reading http://lists.openmoko.org/nabble.html#nabble-td677811</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T13:01:05Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<pre><br />
xres = 480, yres = 640<br />
</pre><br />
I can see the cross-hairs but clicking does nothing. Ok, you need to stop the Xserver before calibrating.<br />
<pre><br />
# /etc/init.d/nodm stop<br />
TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate<br />
xres = 480, yres = 640<br />
Took 15 samples...<br />
Top left : X = 858 Y = 201<br />
Took 2 samples...<br />
Top right : X = 854 Y = 840<br />
Took 9 samples...<br />
Bot right : X = 160 Y = 840<br />
Took 11 samples...<br />
Bot left : X = 162 Y = 196<br />
Took 18 samples...<br />
Center : X = 509 Y = 513<br />
-65.726501 -0.002131 0.592298<br />
717.045288 -0.776964 -0.003633<br />
Calibration constants: -4307452 -139 38816 46992280 -50919 -238 65536 <br />
# echo -4307452 -139 38816 46992280 -50919 -238 65536 > /etc/pointercal <br />
# /etc/init.d/nodm start<br />
</pre><br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests removing xserver-xorg-input-synaptics. Now Xorg.0.log says<br />
<pre><br />
(II) config/hal: Adding input device s3c2410 TouchScreen<br />
(**) s3c2410 TouchScreen: always reports core events<br />
(II) XINPUT: Adding extended input device "s3c2410 TouchScreen" (type: TOUCHSCREEN)<br />
</pre><br />
and tapping the screen switches it on but still no luck in doing any actions. Let's restore /etc/pointercal<br />
<pre><br />
# echo 557 38667 -4654632 -51172 121 46965312 65536 > /etc/pointercal<br />
# /etc/init.d/nodm restart<br />
</pre><br />
now I have a screen that works. It broke again. Reading http://lists.openmoko.org/nabble.html#nabble-td677811</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T11:30:59Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, [http://pkg-fso.alioth.debian.org/freerunner/install.sh install.sh] - v3.0, from [http://wiki.debian.org/DebianOnFreeRunner wiki.debian.org] fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<pre><br />
xres = 480, yres = 640<br />
</pre><br />
I can see the cross-hairs but clicking does nothing. Ok, you need to stop the Xserver before calibrating.<br />
<pre><br />
# /etc/init.d/nodm stop<br />
TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate<br />
xres = 480, yres = 640<br />
Took 15 samples...<br />
Top left : X = 858 Y = 201<br />
Took 2 samples...<br />
Top right : X = 854 Y = 840<br />
Took 9 samples...<br />
Bot right : X = 160 Y = 840<br />
Took 11 samples...<br />
Bot left : X = 162 Y = 196<br />
Took 18 samples...<br />
Center : X = 509 Y = 513<br />
-65.726501 -0.002131 0.592298<br />
717.045288 -0.776964 -0.003633<br />
Calibration constants: -4307452 -139 38816 46992280 -50919 -238 65536 <br />
# echo -4307452 -139 38816 46992280 -50919 -238 65536 > /etc/pointercal <br />
# /etc/init.d/nodm start<br />
</pre><br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests removing xserver-xorg-input-synaptics. Now Xorg.0.log says<br />
<pre><br />
(II) config/hal: Adding input device s3c2410 TouchScreen<br />
(**) s3c2410 TouchScreen: always reports core events<br />
(II) XINPUT: Adding extended input device "s3c2410 TouchScreen" (type: TOUCHSCREEN)<br />
</pre><br />
and tapping the screen switches it on but still no luck in doing any actions. Let's restore /etc/pointercal<br />
<pre><br />
# echo 557 38667 -4654632 -51172 121 46965312 65536 > /etc/pointercal<br />
# /etc/init.d/nodm restart<br />
</pre><br />
now I have a screen that works.</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T11:26:35Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, install.sh - v3.0, fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<pre><br />
xres = 480, yres = 640<br />
</pre><br />
I can see the cross-hairs but clicking does nothing. Ok, you need to stop the Xserver before calibrating.<br />
<pre><br />
# /etc/init.d/nodm stop<br />
TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate<br />
xres = 480, yres = 640<br />
Took 15 samples...<br />
Top left : X = 858 Y = 201<br />
Took 2 samples...<br />
Top right : X = 854 Y = 840<br />
Took 9 samples...<br />
Bot right : X = 160 Y = 840<br />
Took 11 samples...<br />
Bot left : X = 162 Y = 196<br />
Took 18 samples...<br />
Center : X = 509 Y = 513<br />
-65.726501 -0.002131 0.592298<br />
717.045288 -0.776964 -0.003633<br />
Calibration constants: -4307452 -139 38816 46992280 -50919 -238 65536 <br />
# echo -4307452 -139 38816 46992280 -50919 -238 65536 > /etc/pointercal <br />
# /etc/init.d/nodm start<br />
</pre><br />
Let's read http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01205.html which suggests removing xserver-xorg-input-synaptics. Now Xorg.0.log says<br />
<pre><br />
(II) config/hal: Adding input device s3c2410 TouchScreen<br />
(**) s3c2410 TouchScreen: always reports core events<br />
(II) XINPUT: Adding extended input device "s3c2410 TouchScreen" (type: TOUCHSCREEN)<br />
</pre><br />
and tapping the screen switches it on but still no luck in doing any actions. Let's restore /etc/pointercal<br />
<pre><br />
# echo 557 38667 -4654632 -51172 121 46965312 65536 > /etc/pointercal<br />
# /etc/init.d/nodm restart<br />
</pre><br />
now I have a screen that works.</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T11:09:05Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, install.sh - v3.0, fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<pre><br />
xres = 480, yres = 640<br />
</pre><br />
I can see the cross-hairs but clicking does nothing. Ok, you need to stop the Xserver before calibrating.<br />
<pre><br />
# /etc/init.d/nodm stop<br />
TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate<br />
xres = 480, yres = 640<br />
Took 15 samples...<br />
Top left : X = 858 Y = 201<br />
Took 2 samples...<br />
Top right : X = 854 Y = 840<br />
Took 9 samples...<br />
Bot right : X = 160 Y = 840<br />
Took 11 samples...<br />
Bot left : X = 162 Y = 196<br />
Took 18 samples...<br />
Center : X = 509 Y = 513<br />
-65.726501 -0.002131 0.592298<br />
717.045288 -0.776964 -0.003633<br />
Calibration constants: -4307452 -139 38816 46992280 -50919 -238 65536 <br />
# echo -4307452 -139 38816 46992280 -50919 -238 65536 > /etc/pointercal <br />
# /etc/init.d/nodm start<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T10:57:39Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, install.sh - v3.0, fails.<br />
<br />
<pre># HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<pre><br />
xres = 480, yres = 640<br />
</pre><br />
I can see the cross-hairs but clicking does nothing.</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T10:56:42Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
Well, install.sh - v3.0, fails.<br />
<br />
<pre>HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
[...]<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root/install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<pre><br />
xres = 480, yres = 640<br />
</pre><br />
I can see the cross-hairs but clicking does nothing.</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T10:55:27Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
Well, install.sh - v3.0, fails.<br />
<br />
<code>HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all</code><br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
<code>apt-get install libts-bin</code><br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<pre><br />
xres = 480, yres = 640<br />
</pre><br />
I can see the cross-hairs but clicking does nothing.</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T10:54:28Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
Well, install.sh - v3.0, fails.<br />
<br />
<code>HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all</code><br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
apt-get install libts-bin <br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<pre><br />
xres = 480, yres = 640<br />
</pre><br />
I can see the cross-hairs but clicking does nothing.</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T10:52:59Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
Well, install.sh - v3.0, fails.<br />
<br />
<code>HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all</code><br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.<br />
apt-get install libts-bin <br />
<code>TSLIB_TSDEVICE=/dev/input/touchscreen0 DISPLAY=:0 /usr/bin/ts_calibrate</code><br />
<pre><br />
xres = 480, yres = 640<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T08:19:00Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
== Installing Debian ==<br />
<br />
I partitioned by hand because of a problem with fdisk. Changing the type of a partition seems to block with the fdisk from Om 2007.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
Well, install.sh - v3.0, fails.<br />
<br />
<code>HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all</code><br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T08:15:55Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /30 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
== Installing Debian ==<br />
<br />
Well, install.sh - v3.0, fails.<br />
<br />
<code>HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all</code><br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html explains<br />
that you have to download install-info_4.13a.dfsg.1-4_armel.deb in the middle of the installation.<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
<br />
Now I have debian on my SD card but the touchscreen doesn't work. <br />
http://neil.brown.name/blog/20090212205404 says that it might just be a calibration problem.</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T07:00:35Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
<br />
install.sh - v3.0<br />
<br />
HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html<br />
<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre><br />
http://neil.brown.name/blog/20090212205404</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-17T06:17:37Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
<br />
install.sh - v3.0<br />
<br />
HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
http://www.mail-archive.com/smartphones-userland@linuxtogo.org/msg01544.html<br />
<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T21:35:03Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
<br />
install.sh - v3.0<br />
<br />
HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T21:33:16Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have a local nameserver.<br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
<br />
install.sh - v3.0<br />
<br />
HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
<pre><br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 format mount<br />
mkdir /mnt/debian/var /mnt/debian/var/cache /mnt/debian/var/cache/bootstrap/<br />
wget http://ftp.debian.org/debian/pool/main/t/texinfo/install-info_4.13a.dfsg.1-4_armel.deb<br />
mv install-info_4.13a.dfsg.1-4_armel.deb /mnt/debian/var/cache/bootstrap/<br />
HOSTNAME=stuart QI=true INST_MIRROR=http://ftp.fr.debian.org/debian LOCALEPURGE=true /home/root//install.sh --no-partitioning --swap-size 128 --part1-fs ext3 debian apt fso tasks configuration kernel cleanup unmount<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T12:40:34Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have local nameserver.<br />
<br />
<pre><br />
</pre><br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
<br />
install.sh - v3.0<br />
<br />
HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre><br />
<br />
I even switched the swap on just after the mkswap</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T10:01:02Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have local nameserver.<br />
<br />
<pre><br />
</pre><br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
<br />
<br />
HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
<br />
<pre><br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T10:00:10Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have local nameserver.<br />
<br />
<pre><br />
</pre><br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
<br />
<br />
HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all<br />
<br />
P: Configuring package apt<br />
P: Configuring helper cdebootstrap-helper-apt<br />
E: Internal error: install</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T09:40:28Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have local nameserver.<br />
<br />
<pre><br />
</pre><br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
<br />
<br />
OSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T09:39:36Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have local nameserver.<br />
<br />
<pre><br />
allow-hotplug eth7<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE<br />
</pre><br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
<br />
<br />
OSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T09:37:41Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have local nameserver.<br />
<br />
<pre><br />
allow-hotplug eth7<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE<br />
</pre><br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre><br />
<br />
I partitioned by hand because of a problem with fdisk.<br />
<br />
<pre><br />
Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes<br />
4 heads, 16 sectors/track, 62032 cylinders<br />
Units = cylinders of 64 * 512 = 32768 bytes<br />
<br />
Device Boot Start End Blocks Id System<br />
/dev/mmcblk0p1 1 57984 1855480 83 Linux<br />
/dev/mmcblk0p2 57985 62032 129536 82 Linux swap<br />
</pre><br />
<br />
<br />
HOSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --with-tasks GAMES,NET,WEB,WIFI,COM all</div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T09:08:18Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have local nameserver.<br />
<br />
<pre><br />
allow-hotplug eth7<br />
address 192.168.0.200<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE<br />
</pre><br />
<br />
<pre><br />
iptables -A FORWARD --in-interface eth7 -j ACCEPT<br />
iptables -A FORWARD --out-interface eth7 -j ACCEPT<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T08:54:10Z<p>Stuart: </p>
<hr />
<div>The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24<br />
<br />
<pre><br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.201<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE<br />
</pre></div>Stuarthttp://wiki.openmoko.org/wiki/User:StuartUser:Stuart2009-08-16T08:52:07Z<p>Stuart: New page: The entry in /etc/network/interfaces <code> allow-hotplug eth7 iface eth7 inet static address 192.168.0.201 netmask 255.255.255.252 up iptables -A POSTROUTING -t nat -s 1...</p>
<hr />
<div>The entry in /etc/network/interfaces<br />
<br />
<code><br />
allow-hotplug eth7<br />
iface eth7 inet static<br />
address 192.168.0.201<br />
netmask 255.255.255.252<br />
up iptables -A POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE<br />
up echo 1 > /proc/sys/net/ipv4/ip_forward<br />
down iptables -D POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE<br />
</code></div>Stuart