http://openmoko.org/api.php?action=feedcontributions&user=Plaicy&feedformat=atomOpenmoko - User contributions [en]2024-03-29T11:23:46ZUser contributionsMediaWiki 1.19.24http://openmoko.org/wiki/User_talk:PlaicyUser talk:Plaicy2009-08-23T21:12:19Z<p>Plaicy: spp</p>
<hr />
<div>== Universal Keyboard Hacking ==<br />
<br />
Using the om2008.12 release + a fresh freedom keyboard (i do not possess any of the working smartphones as of date). It is a no-go at the moment. I saw your recent comment on http://wiki.openmoko.org/wiki/Talk:Manually_using_Bluetooth#Bluetooth_keyboards_which_doesn.27t_support_HID:_tested_a_keyboard<br />
<br />
On that page you are hinting about getting this keyboard to work. Is it possible to post more details on what you do to get to the situation you describe? So far I have done the following (reading from http://wiki.openmoko.org/wiki/Manually_using_Bluetooth):<br />
<br />
i switch on my keyboard with SPP, as you posted it would work with.<br />
<br />
then on the moko<br />
<pre><br />
root@om-gta02:~# echo 1 > /sys/bus/platform/devices/neo1973-pm-bt.0/power_on<br />
root@om-gta02:~# echo 0 > /sys/bus/platform/devices/neo1973-pm-bt.0/reset<br />
root@om-gta02:~# hciconfig<br />
hci0: Type: USB<br />
BD Address: 00:00:00:00:00:00 ACL MTU: 0:0 SCO MTU: 0:0<br />
DOWN <br />
RX bytes:0 acl:0 sco:0 events:0 errors:0<br />
TX bytes:0 acl:0 sco:0 commands:0 errors:0<br />
root@om-gta02:~# hciconfig hci0 up<br />
root@om-gta02:~# hcitool scan<br />
Scanning ...<br />
00:0B:0D:FF:FF:FF FREEDOM KEYBOARD<br />
<br />
root@om-gta02:~# modprobe uinput<br />
root@om-gta02:~# hidd --connect 00:0B:0D:FF:FF:FF<br />
Can't create HID control channel: Connection reset by peer<br />
</pre><br />
<br />
Can you shed some light on this sequence? And possibly reveal the details of the script you are the only to use?<br />
<br />
Bye,--[[User:Ivo|Ivo]] 22:19, 5 January 2009 (UTC) Ivo<br />
<br />
> Just to add to this info: I have not followed the unlock sequence offered through http://www.freedominput.com/unlock.html. I don't know if this really matters, but since I don't own compatible hardware (i have just the moko) i cannot get an unlock code :/<br />
<br />
: Sorry for late reply, but I do not watch my personal page. You should ether reply exactly where I wrote or use my discussion page. Using "SPP" you do not need any "hci*" commands. "rfcomm connect 0". If you send me an email I can sent you the python code. But I can not test it at the moment because I have no working distribution on my phone.--[[User:Plaicy|plaicy]] 21:12, 23 August 2009 (UTC)</div>Plaicyhttp://openmoko.org/wiki/User:PlaicyUser:Plaicy2009-08-23T21:09:45Z<p>Plaicy: see wikipedia</p>
<hr />
<div>see http://en.wikipedia.org/wiki/User:Plaicy</div>Plaicyhttp://openmoko.org/wiki/User:PlaicyUser:Plaicy2009-08-23T21:08:22Z<p>Plaicy: User:Plaicy moved to User talk:Plaicy</p>
<hr />
<div>#REDIRECT [[User talk:Plaicy]]</div>Plaicyhttp://openmoko.org/wiki/User_talk:PlaicyUser talk:Plaicy2009-08-23T21:08:22Z<p>Plaicy: User:Plaicy moved to User talk:Plaicy</p>
<hr />
<div>== Universal Keyboard Hacking ==<br />
<br />
Using the om2008.12 release + a fresh freedom keyboard (i do not possess any of the working smartphones as of date). It is a no-go at the moment. I saw your recent comment on http://wiki.openmoko.org/wiki/Talk:Manually_using_Bluetooth#Bluetooth_keyboards_which_doesn.27t_support_HID:_tested_a_keyboard<br />
<br />
On that page you are hinting about getting this keyboard to work. Is it possible to post more details on what you do to get to the situation you describe? So far I have done the following (reading from http://wiki.openmoko.org/wiki/Manually_using_Bluetooth):<br />
<br />
i switch on my keyboard with SPP, as you posted it would work with.<br />
<br />
then on the moko<br />
<pre><br />
root@om-gta02:~# echo 1 > /sys/bus/platform/devices/neo1973-pm-bt.0/power_on<br />
root@om-gta02:~# echo 0 > /sys/bus/platform/devices/neo1973-pm-bt.0/reset<br />
root@om-gta02:~# hciconfig<br />
hci0: Type: USB<br />
BD Address: 00:00:00:00:00:00 ACL MTU: 0:0 SCO MTU: 0:0<br />
DOWN <br />
RX bytes:0 acl:0 sco:0 events:0 errors:0<br />
TX bytes:0 acl:0 sco:0 commands:0 errors:0<br />
root@om-gta02:~# hciconfig hci0 up<br />
root@om-gta02:~# hcitool scan<br />
Scanning ...<br />
00:0B:0D:FF:FF:FF FREEDOM KEYBOARD<br />
<br />
root@om-gta02:~# modprobe uinput<br />
root@om-gta02:~# hidd --connect 00:0B:0D:FF:FF:FF<br />
Can't create HID control channel: Connection reset by peer<br />
</pre><br />
<br />
Can you shed some light on this sequence? And possibly reveal the details of the script you are the only to use?<br />
<br />
Bye,--[[User:Ivo|Ivo]] 22:19, 5 January 2009 (UTC) Ivo<br />
<br />
> Just to add to this info: I have not followed the unlock sequence offered through http://www.freedominput.com/unlock.html. I don't know if this really matters, but since I don't own compatible hardware (i have just the moko) i cannot get an unlock code :/</div>Plaicyhttp://openmoko.org/wiki/BackupBackup2009-05-10T10:46:25Z<p>Plaicy: weblink</p>
<hr />
<div>== Backing up just PIM data ==<br />
<br />
The following applies to all Qtopia PIM suite based derivations (FDOM, 2008.8, Qtopia). PIM data covers:<br />
<br />
* Contacts, calendar appointments, and tasks<br />
* E-Mails and text messages<br />
<br />
To make a backup which can be easily restored later on use secure copy:<br />
<br />
scp -pr root@192.168.0.202:~/Applications/ .<br />
scp -pr root@192.168.0.202:~/Documents/ .<br />
<br />
To restore do the reverse:<br />
<br />
scp -pr Applications root@192.168.0.202:~/<br />
scp -pr Documents root@192.168.0.202:~/<br />
<br />
Make sure you restart to allow the Qtopia PIM suite to see the changes:<br />
<br />
reboot<br />
<br />
This way we can flash applicable distributions with minimal effort without loosing important data. To access the PIM data on the computer take a look at the following files and folders:<br />
<br />
* Contacts, calendar appointments, and tasks are kept in <tt>~/Applications/Qtopia/qtopia_db.sqlite</tt>.<br />
* E-Mails and text messages are kept in <tt>~/Applications/qtmail/mail/</tt>.<br />
<br />
== Backing up just /home/root ==<br />
<br />
To backup the home folder (all your personal files in theory).<br />
<br />
From the desktop pc run:<br />
<br />
ssh root@phone 'tar -cpz /home/root' > moko-home-`date +%Y%m%d-%H%M%S`.tar.gz<br />
<br />
Where phone is the ip address of your phone (192.168.0.202).<br />
<br />
Personally I added an entry to /etc/hosts so the above works for me. I also added the desktop key to /home/root/.ssh/authorized_keys on the phone as per the instructions in [[USB_Networking#SSH_Keys]].<br />
<br />
If you want to check what is in the backup, run the following, replacing the filename with what was just created.<br />
<br />
tar -tzf moko-home-20080802-203108.tar.gz | less<br />
<br />
[http://timwise.wikispaces.com/my+neo+freerunner reference]<br />
<br />
== Backing up everything ==<br />
<br />
You may either :<br />
* Backup the flash contents, in order to be able to restore (see below)<br />
* or move the system to SD to be able to boot it from SD in case of need. See [[Moving current system from flash to SD]]<br />
<br />
=== Backing-up flash images ===<br />
<br />
{{note|Upload support is currently broken - [http://docs.openmoko.org/trac/ticket/676 #676], [http://docs.openmoko.org/trac/ticket/1843 #1843]}}<br />
<br />
You will need the [[Dfu-util]] to make a backup of your existing image.<br />
<br />
As when [[Flashing_the_Neo_FreeRunner|flashing]], you will need to be in [[Booting_the_Neo_FreeRunner#Log_into_U-Boot_in_the_NOR_Flash|U-Boot in the NOR Flash]]. Log into the NOR uBoot menu and select ''Set console to USB'' (for FreeRunner just stay in NOR uBoot menu, do not select or enter anything). Now you will be able to flash, make backups of your FreeRunner or query the FreeRunner with [[Dfu-util|dfu-util]]. Backup is fairly slow; it took over ten minutes to back up a 247 MB rootfs.<br />
<br />
It is important that you connect the USB cable directly from your computer to your phone. If there is a hub between them, backup (and flashing) will mostly likely fail.<br />
<br />
{{note|On a Windows host, omit the "./" or "sudo ./" that precedes the commands listed on this page}}<br />
<br />
<pre><br />
sudo ./dfu-util -a kernel -R -U good-kernel.bin<br />
sudo ./dfu-util -a rootfs -R -U good-rootfs.jffs2<br />
sudo ./dfu-util -a splash -R -U good-splash.bin<br />
sudo ./dfu-util -a u-boot -R -U good-u-boot.bin<br />
sudo ./dfu-util -a u-boot_env -R -U good-u-boot_env.bin<br />
</pre><br />
<br />
Here is what a successful dfu-util backup run looks like:<br />
<br />
on the host PC:<br />
<pre><br />
$ sudo ./dfu-util -a kernel -R -U good-kernel.img<br />
dfu-util - (C) 2007 by Openmoko Inc.<br />
This program is Free Software and has ABSOLUTELY NO WARRANTY<br />
<br />
Opening USB Device 0x0000:0x0000...<br />
Claiming USB DFU Runtime Interface...<br />
Determining device status: state = appIDLE, status = 0<br />
Device really in Runtime Mode, send DFU detach request...<br />
Resetting USB...<br />
Opening USB Device...<br />
Found Runtime: [0x1d50:0x5119] devnum=12, cfg=0, intf=0, alt=3, name="kernel"<br />
Claiming USB DFU Interface...<br />
Setting Alternate Setting ...<br />
Determining device status: state = dfuIDLE, status = 0<br />
dfuIDLE, continuing<br />
Transfer Size = 0x1000<br />
Resetting USB to switch back to runtime mode<br />
</pre><br />
<br />
on the FreeRunner:<br />
<pre><br />
DFU: Switching to DFU Mode<br />
DEVICE_CONFIGURED: 1<br />
Starting DFU Upload of partition 'kernel'<br />
</pre><br />
<br />
A failed run of dfu-util looks like this:<br />
<pre><br />
dfu-util - (C) 2007 by Openmoko Inc.<br />
This program is Free Software and has ABSOLUTELY NO WARRANTY<br />
<br />
Opening USB Device 0x0000:0x0000...<br />
Claiming USB DFU Runtime Interface...<br />
Determining device status: state = appIDLE, status = 0<br />
Device really in Runtime Mode, send DFU detach request...<br />
Resetting USB...<br />
Opening USB Device...<br />
Found Runtime: [0x1d50:0x5119] devnum=20, cfg=0, intf=0, alt=6, name="rootfs"<br />
Claiming USB DFU Interface...<br />
Setting Alternate Setting ...<br />
Determining device status: state = dfuIDLE, status = 0<br />
dfuIDLE, continuing<br />
Transfer Size = 0x1000<br />
dfu_upload error -110<br />
</pre><br />
And shows demsg errors like this:<br />
<pre><br />
usb 5-2: usbfs: USBDEVFS_CONTROL failed cmd dfu-util rqt 161 rq 2 len 4096 ret -110<br />
</pre><br />
This error is detected within the Linux USB stack (drivers/usb/core/message.c) and looking at<br />
errno.h for the negatived error status number, the reason is e.g.<br />
{|<br />
| 110 || ETIMEDOUT || Connection timed out<br />
|-<br />
| 84 || EILSEQ || Illegal byte sequence<br />
|-<br />
| 108 || ESHUTDOWN || Cannot send after transport endpoint shutdown<br />
|-<br />
| ... || ||<br />
|}<br />
Insure yourself, that you connect the FR directly to the computer (without any USB hubs), if you experience timed out connections<br />
and use the<br />
<pre><br />
dfu-util -d 0x1d50:0x5119 ...<br />
</pre><br />
option, if the FR is not detected properly.<br />
<br />
=== Backing-up flash images (alternative) ===<br />
<br />
On the device:<br />
<pre><br />
mkdir /var/tmp/root<br />
mount /dev/root /var/tmp/root<br />
</pre><br />
<br />
If you have om2008.9 you have to use:<br />
<pre><br />
mount -t jffs2 /dev/mtdblock6 /var/tmp/root<br />
</pre><br />
<br />
On your workstation:<br />
<pre><br />
ssh root@192.168.0.202 "mkfs.jffs2 -d /var/tmp/root -e 128 --pad --no-cleanmarkers -x lzo" | pv -W > rootfs.jffs2<br />
</pre><br />
(The "| pv -W" is optional, it just gives you something to watch as the bytes fly by.)<br />
<br />
On the device:<br />
<pre><br />
umount /var/tmp/root<br />
</pre><br />
<br />
=== Backing-up in a tar archive ===<br />
<br />
ssh root@192.168.0.202 "tar c /bin /etc /home /lib /opt /sbin /tmp /usr /var" | pv -W > rootfs.tar<br />
(The "| pv -W" is optional, it just gives you something to watch as the bytes fly by.)<br />
<br />
Extract it and use <code>mkfs.jffs2</code> if you want convert it to a jffs2 image.<br />
<br />
==Backup Scripts==<br />
<br />
If you plan on backing up frequently, using a script will simplify the process:<br />
<br />
===Simple backup script===<br />
<br />
This script works well if you want to configure it to backup always the same device.<br />
<br />
<pre><br />
#!/bin/sh<br />
#<br />
# Back up all partitions of the phone to a backup directory,<br />
# adding today's date to the saved filenames.<br />
<br />
DATE=`date +%Y-%m-%d`<br />
DFU=./dfu-util<br />
BACKUP_DIR=bak/<br />
<br />
${DFU} -a kernel -R -U ${BACKUP_DIR}kernel-${DATE}.bin<br />
${DFU} -a rootfs -R -U ${BACKUP_DIR}rootfs-${DATE}.jffs2<br />
${DFU} -a splash -R -U ${BACKUP_DIR}splash-${DATE}.bin<br />
${DFU} -a u-boot -R -U ${BACKUP_DIR}u-boot-${DATE}.bin<br />
${DFU} -a u-boot_env -R -U ${BACKUP_DIR}u-boot_env-${DATE}.bin<br />
</pre><br />
<br />
===Interactive script===<br />
<br />
This script is based on the above "Simple backup script" (by unknown). It does the backup of what you want and choose promting you for choices. Enjoy it! test it! contribute! You can find us at /server irc.freenode.net /j #openmoko and we'll be pleased to accept you help (ideas || code). <br />
<br />
NOTE that the script works for me(tm) but it still needs some love. especially on traps and catches for wrong choices.<br />
<br />
<pre><br />
#!/bin/bash<br />
<br />
#############################################################################################################<br />
## ##<br />
## This script is Free Software, it's licensed under the GPLv3 and has ABSOLUTELY NO WARRANTY ##<br />
## you can find and read the complete version of the GPLv3 @ http://www.gnu.org/licenses/gpl.html ##<br />
## ##<br />
## Q: what does this script do? ##<br />
## A: the script back up all partitions of the phone to a backup directory, interactively, ## <br />
## adding today's date to the saved filenames. ##<br />
## ##<br />
## IMPORTANT:!!! REMEMBER TO RUN THIS SCRIPT AS ROOT SINCE dfu-util HAS TO BE USED AS ROOT!!! ##<br />
## ##<br />
## based on the orginal simple backup script at http://wiki.openmoko.org/wiki/Backup ##<br />
## ##<br />
## this version has been conceived and written by cga, x77686d, Infoport, jomat at /server irc.freenode.net##<br />
## /j #openmoko,#bash and my collegue aubba @ work. ##<br />
## ##<br />
## for any suggestions and contributions contact cga (or one of the above) in the #openmoko channel ##<br />
## ##<br />
#############################################################################################################<br />
<br />
## let's roll!!<br />
<br />
## sets the date format for the date in the backup file, change accordingly to your local custom if you need<br />
DATE=`date +%d-%m-%Y`<br />
<br />
## here the scripts try to find the dfu-util binary and set it as the DFU var:<br />
if which dfu-util >/dev/null ; then<br />
echo<br />
echo "dfu-util found in your path"<br />
echo<br />
## 1 the function use this if you placed/linked dfu-util in your $PATH<br />
DFU=dfu-util<br />
<br />
elif ls dfu-util >/dev/null ; then<br />
echo<br />
echo "dfu-util found in current directory" <br />
echo<br />
## or 2 use following line if dfu-util is placed in the same directory where you run the script<br />
DFU=./dfu-util<br />
<br />
else<br />
## or 3 if the script doesn't find dfu-util shows the link for installing it and exit<br />
echo<br />
echo "dfu-util NOT found! install and use howto @ http://wiki.openmoko.org/wiki/Dfu-util"<br />
echo<br />
exit 1<br />
fi<br />
<br />
## here we get the hex code for devices found with dfu-util --list <br />
## the hex code is grabbed and the name of the device is shown accordingly and you are prompetd to chose the right one:<br />
echo<br />
echo 'these are the devices i found:' <br />
echo<br />
for device in `${DFU} --list | grep 0x | cut -f3 -d' ' | tr -d '[]'` ; do<br />
if [ "$device" == '0x1457:0x5119' ] ; then<br />
echo 'Neo 1973'<br />
elif [ "$device" == '0x1d50:0x5119' ] ; then<br />
echo "Neo FreeRunner"<br />
else<br />
echo 'other device found, DO NOT use dfu-util on this!!! it might bork it...'<br />
exit 1<br />
fi<br />
done | nl<br />
echo<br />
echo 'choose the device to backup:' <br />
echo<br />
read selection<br />
HEX=$(${DFU} --list | grep 0x | head -n $selection | tail -1 | cut -f3 -d' ' | tr -d '[]') <br />
<br />
## use the built-in read command to ask you and use the directory for the backup<br />
while [ -z "$BACKUP_DIR" ] ; do<br />
echo<br />
read -e -p $"enter the directory for the backup:" BACKUP_DIR<br />
echo<br />
<br />
## chek wether the dir exist and proceed, else create it and proceed.<br />
if [ ! -d "$BACKUP_DIR" ] ; then<br />
echo<br />
echo -n "$BACKUP_DIR does not exist, create it? [Y/n] "<br />
echo<br />
read CREATE_DIR<br />
if [ x"$CREATE_DIR" = xy -o x"$CREATE_DIR" = xY -o -z "$CREATE_DIR" ] ; then<br />
mkdir -p -v "${BACKUP_DIR}"<br />
else<br />
BACKUP_DIR=<br />
fi<br />
fi<br />
done<br />
<br />
## here you get prompted to chose the backup you want, you can backup single files or all of them.<br />
echo<br />
echo 'choose the component to backup from the list:'<br />
echo<br />
<br />
select howto in kernel splash u-boot u-boot_env rootfs all quit; do<br />
if [ "$howto" == "kernel" -o "$howto" == "all" ] ; then<br />
${DFU} -d ${HEX} -a kernel -R -U ${BACKUP_DIR}/kernel-${DATE}.bin<br />
fi<br />
if [ "$howto" == "splash" -o "$howto" == "all" ] ; then<br />
${DFU} -d ${HEX} -a splash -R -U ${BACKUP_DIR}/splash-${DATE}.bin<br />
fi<br />
if [ "$howto" == "u-boot" -o "$howto" == "all" ] ; then<br />
${DFU} -d ${HEX} -a u-boot -R -U ${BACKUP_DIR}/u-boot-${DATE}.bin<br />
fi<br />
if [ "$howto" == "u-boot_env" -o "$howto" == "all" ] ; then<br />
${DFU} -d ${HEX} -a u-boot_env -R -U ${BACKUP_DIR}/u-boot_env-${DATE}.bin<br />
fi<br />
if [ "$howto" == "rootfs" -o "$howto" == "all" ] ; then<br />
${DFU} -d ${HEX} -a rootfs -R -U ${BACKUP_DIR}/rootfs-${DATE}.jffs2<br />
fi<br />
if [ "$howto" == "quit" ] ; then<br />
exit 0<br />
fi<br />
echo<br />
echo 'the component(s) has/have been backed up, what next? (press enter for menu)'<br />
echo<br />
done<br />
<br />
exit 0<br />
<br />
</pre><br />
<br />
=== Pretty GUI Script ===<br />
<br />
[[NeoTool]] is a zenity-based script which allows you to both backup and Flash your device from a pretty GUI. It uses both the dfu-util method and the alternate method described on this page, and can produce flashable images of everything including rootfs. Check it out.<br />
<br />
== Backing up the incremental rsync hardlink way ==<br />
<br />
Following is a very simple implementation of<br />
[http://www.mikerubel.org/computers/rsync_snapshots/ incremental rsync<br />
snapshots with hardlinks]. Just put it to /etc/cron.daily/backup-neo<br />
on your PC and setup ssh keys between your PC and neo. It will then<br />
daily try to backup all files in the / partition. Each successful<br />
backup is hardlinked under a timestamped directory so you can access<br />
old backups easily. In fact, you can even NFS mount /backup/neo to<br />
phone and then chroot inside the backups to run programs in the<br />
backup'ed environment.<br />
#!/bin/bash<br />
# /etc/cron.daily/backup-neo<br />
rsync --delete -ax --numeric-ids 192.168.0.202:/ /backup/neo/latest 2> /dev/null<br />
ret=$?<br />
<br />
case $ret in<br />
0)<br />
# backup done, let's save it<br />
cp -al /backup/neo/latest /backup/neo/`date -I`<br />
;;<br />
12)<br />
# neo was not at home<br />
;;<br />
*)<br />
echo "backup failed with return value $ret"<br />
;;<br />
esac<br />
<br />
<br />
== Backing up internal flash when booted on external SD-card ==<br />
<br />
#Freerunner<br />
mkdir internal_flash<br />
mount /dev/mtdblock6 internal_flash -t jffs2<br />
<br />
Now you can pack directory or copy selected files out from it.<br />
<br />
(This mounting is usefull also if your internal operating system is non-bootable. You can get files out or even repair the system using operating system on external card.)<br />
<br />
== Weblinks ==<br />
* [http://www.oesf.org/forum/index.php?showtopic=25994#entry178835 read jffs file system on pc]<br />
<br />
[[category:Advanced End User]]<br />
[[Category:Flashing Openmoko]]</div>Plaicyhttp://openmoko.org/wiki/MokoMakefile/deMokoMakefile/de2009-01-11T13:31:34Z<p>Plaicy: /* MokoMakefile */ typo</p>
<hr />
<div>{{Languages|MokoMakefile}}<br />
==MokoMakefile==<br />
Das MokoMakefile ist ein wertvolles Tool um neuen Entwicklern möglichst schnell eine einheitliche Entwicklungsumgebung an die Hand zu geben. Es garantiert die einfache Reproduzierbarkeit und Wartung der Entwicklungsumbgebung ähnlich wie OpenEmbedded eine generelle Plattform zur Entwicklung von Embedded-Distributionen darstellt.<br />
<br />
'''Hinweis:'''<br />
*Das MokoMakefile ist '''kein''' Ersatz für bitbake, SVN, monotone, OpenEmbedded, qmake und dergleichen. Es dient vielmehr als Rahmen für die einfache Wartung und Instandhaltung einer Entwicklungsumgebung die den Regeln des Openmoko-Projekts entspricht.<br />
*Die Entwicklungsumgebung benötigt ca. 7GB Festplattenspeicher<br />
*MokoMakefile wird von [[User:RodWhitby|Rod Whitby]] entwickelt und ist kein offizielles Produkt von Openmoko. Sollte es Widersprüche bzw. Probleme zwischen der [[Openmoko2007.2/de|offiziellen Build Openmoko Anleitung]] ([[Openmoko2007.2|eng]]) und der MokoMakefile selbst geben gilt die offizielle Anleitung als Standard.<br />
<br />
<br />
=== Vor dem Start ===<br />
'''Stelle sicher dass der Befehl /bin/sh (ls -l /bin/sh) nicht mit dash sondern bash verlinkt ist.''' Mit dash wird's keinen Spass machen!<br />
<br />
Falls du bereits mit dash (als /bin/sh) gearbeitet haben solltes ist die Perl-Komponente vermutlich defekt. Indizien dafür sind:<br />
* Das Build-System wirft wegen einem 'Unterminated quote string' eine Fehlermeldung aus<br />
* Die Fehlermeldung 'You haven't done a "make depend" yet!'<br />
Sollte eine dieser Fehlermeldung auftreten sind folgende Schritte notwendig:<br />
make clean-package-perl<br />
make clean-package-perl-native<br />
mit anschließendem Rebuild.<br />
<br />
Sollte alles nichts helfen dann bleibt nur noch ein 'rm -rf' auf das Perl-Verzeichnis und die Perl-Projektstempel loszulassen. Hier ein Beispiel für einen i686-Rechner:<br />
rm -rf build/tmp/work/i686-linux/perl-native-5.8.7-r3<br />
rm -f build/tmp/stamps/i686-linux/perl*<br />
<br />
=== Installation ===<br />
So läufts:<br />
<br />
1 - Überprüfe ob dein Rechner den folgenden Anforderungen entspricht:<br />
[http://wiki.openembedded.net/index.php/OEandYourDistro http://wiki.openembedded.net/index.php/OEandYourDistro]<br />
2 - Erstelle das $OMDIR Verzeichnis:<br />
mkdir /home/moko ; cd /home/moko<br />
3 - Hole das MokoMakefile:<br />
wget http://www.rwhitby.net/files/openmoko/Makefile<br />
4 - Die Entwicklungsumgebung erstellen:<br />
make setup<br />
5 - Mit dem kompilieren anfangen (bevor du mit dem langen Kompilierprozess anfängst solltest du dich in der [[#Tips|Tips]]-Sektion darüber schlau machen wie man Multicore aktiviert):<br />
make openmoko-devel-image<br />
<br />
<br />
Das Makefile erstellt die Ordnerstruktur wie sie in [[Openmoko2007.2/de|Openmoko2007.2]] vorgegeben ist, lädt die benötigten Programme (von den richtigen Quellen und in der richtigen Version) herunter und fängt sofort an das Image zu bauen.<br />
<br />
Danach kannst du das MokoMakefile dazu verwenden nachträgliche Builds laufen zu lassen oder im build-Verzeichnis mit ''bitbake'' die einzelnen Schritte durchführen.<br />
<br />
===Entwicklungsumgebung updaten===<br />
Zur einfachen Wartung der Entwicklungsumgebung stehen folgende Befehle zur Verfügung:<br />
<br />
1 - Um das MokoMakfile auf die neuste Version zu bringen:<br />
make update-makefile<br />
<br />
2 - Um den Paket-Pool zu aktualisieren und die entsprechenden Patches herunterzuladen:<br />
make update<br />
<br />
3 - Um sicherzustellen dass kürzlich vorgenommene Änderungen an der Build-Verzeichnisstruktur übernommen wurden:<br />
make setup<br />
<br />
Eine Möglichkeit ein neues Image mit den aktuellen Updates zu bauen:<br />
make update-makefile && make update && make setup && make openmoko-devel-image<br />
<br />
<br />
===Fehler melden===<br />
<br />
Überprüfe, ob der Fehler wiederholt auftritt und reproduzierbar ist:<br />
make update-makefile ; make update ; make setup<br />
<br />
danach:<br />
make clean-package-<foo><br />
<br />
(<foo> ist der Name des defekten Pakets)<br />
<br />
danach:<br />
make all<br />
<br />
Wenn der Fehler nach dem diese Sequenz zum dritten Mal '''in Folge''' durchlaufen wurde auftritt, bitte bei rwhitby in #openmoko [http://wiki.openmoko.org/wiki/Development_resources#IRC IRC] melden.<br />
<br />
===Work-arounds===<br />
<br />
Work-arounds für vorübergehende oder isolierte Probleme können auf der [[Talk:MokoMakefile|Diskussions-Seite]] gefunden bzw hinzugefügt werden. Wenn das Problem behoben wurde wird das entsprechende Work-around entfernt.<br />
<br />
<br />
===Tips===<br />
* Die Menge an benötigten Festplattenspeicher kann durch hinzufügen folgender Zeile in der 'local.conf' (idR /home/moko/build/conf/local.conf) erheblich verringert werden:<br />
INHERIT += "rm_work"<br />
Diese Einstellung bewirkt dass der Inhalt jedes build/tmp/work/*/<package>-Verzeichnisses gelöscht wird wenn das Packet erfolgreich erstellt wurde.<br />
<br />
* Sollte ein Fehler im Zusammenhang mit Monotone auftreten der in etwa so aussieht:<br />
mtn: misuse: database /home/moko/OE.mtn is laid out according to an old schema<br />
Muss OE.mtn mit dem folgendem Befehl, ausgeführt in /home/moko geupdated werden:<br />
mtn --db OE.mtn db migrate<br />
<br />
* Sollte ein Paket wegen eines kaputten Downloads etc nicht kompiliert werden können hilft es normalerweise wenn man die Quellen löscht und es per Hand versucht:<br />
rm sources/<package>*<br />
cd build<br />
. ../setup-env<br />
bitbake -crebuild <package><br />
danach sollte der Build-Vorgang wieder normal ablaufen<br />
<br />
* Für Maschinen mit mehreren Prozessoren (bzw Dual-Core) sollten diese zwei Zeilen in der local.conf das ganze etwas beschleunigen:<br />
PARALLEL_MAKE = "-j 4"<br />
BB_NUMBER_THREADS = "4"<br />
<br />
''Sollte der Rechner das nicht verkraften kann man die Werte auch verringern.''<br />
<br />
* AMD64-Maschinen benötigen den Patch von http://bugs.openembedded.org/show_bug.cgi?id=1765 für das Paket db3-native<br />
<br />
<br />
===QEMU===<br />
Das MokoMakefile unterstützt jetzt auch das automatische Kompilieren, Flashen und Starten des neuen [[Openmoko under QEMU/de|Neo1973 Emulators]] ([[Openmoko under QEMU|eng]] - basierend auf QEMU).<br />
<br />
make qemu<br />
<br />
kompiliert qemu-neo1973, lädt die neusten offiziellen Openmoko-Images herunter, brennt sie in den virtuellen NAND-Speicher und startet den Emulator.<br />
''Die Makefiles müssen trotzdem wie oben beschrieben installiert werden''<br />
<br />
<br />
Weitere make-Ziele sind:<br />
* Lädt die aktuellen Official-Images herunter:<br />
make download-images<br />
* Images in den virtuellen Speicher flahen:<br />
make flash-qemu-official<br />
* Die lokal erzeugten Images in den Emulator-Speicher flashen:<br />
make flash-qemu-local<br />
* Den Emulator starten<br />
make run-qemu<br />
bzw<br />
make run-qemu-snapshot<br />
<br />
'''Hinweis''':<br />
Die Pakete "lynx" und "netpbm" müssen auf dem Build-Rechner installiert sein bevor der Emulator gestartet werden kann.<br />
<br />
Weitere Informationen über QEMU gibt es in der Sektion [[Openmoko under QEMU/de|Openmoko unter QEMU]] ([[Openmoko under QEMU|eng]])<br />
<br />
===Entwickeln mit MokoMakefile===<br />
<br />
Um im Pakete-Pool Veränderungen zu übernehmen, kompiliern und in QEMU einzuspielen benötigt man folgende Befehle:<br />
<br />
*Übernehmen<br />
cd /home/moko/openmoko<br />
quilt new beschreibender-name.patch<br />
quilt add trunk/src/Name-der-zu-ändernden-Datei<br />
(Schritte für jede geänderte Datei wiederholen)<br />
...Änderungen JETZT machen...<br />
quilt refresh<br />
''(Erstellt eine neue Datei in /home/moko/patches/openmoko-HEAD/ und<br />
aktualisiert die quilt-Serien)''<br />
<br />
*Kompilieren und in QEMU einspielen:<br />
make build-qemu<br />
make flash-qemu-local<br />
make run-qemu<br />
<br />
<br />
===Anhang===<br />
<br />
Project page:<br />
http://mokomakefile.projects.openmoko.org/<br />
<br />
[[Category:System Developers]]<br />
[[Category:Application Developer]]</div>Plaicyhttp://openmoko.org/wiki/Talk:Manually_using_BluetoothTalk:Manually using Bluetooth2008-12-31T21:32:43Z<p>Plaicy: /* Bluetooth keyboards which doesn't support HID: tested a keyboard */ typo</p>
<hr />
<div>== Bluetooth keyboards which doesn't support HID ==<br />
<br />
There exists several bluetooth keyboards which doesn't support the normal HID protocol.<br />
This means you can not simply use "hidd --connect 11:22:33:44:55:66".<br />
I've searched the net a bit and found this: http://www.handhelds.org/moin/moin.cgi/kbdd. The program kbdd seems like the thing to use. The source code is available. I'm not able to test this program myself as I do not have a Neo yet. [[User:EsbenDamgaard|EsbenDamgaard]] 22:10, 16 August 2007 (CEST)<br />
<br />
I have tried it and it works ok for me, there is even an ipkg package for kbdd in Angstrom, see the details in http://n2.nabble.com/Non-HID-Bluetooth-keyboard.-Success%21-td1496389ef1958.html#a1496389 . --[[User:Glownan|Glownan]] 10:56, 14 November 2008 (UTC)<br />
<br />
== Phone does not detect laptop ==<br />
If running hcitool scan on the phone does not detect your laptop, check if ISCAN is enabled on the laptop by typing hciconfig and seeing the output.Like in the following output ISCAN is not enabled.<br />
<br />
hci0: Type: USB<br />
BD Address: 00:19:7E:E5:C2:2F ACL MTU: 1017:8 SCO MTU: 64:8<br />
UP RUNNING PSCAN <br />
RX bytes:1651 acl:0 sco:0 events:42 errors:0<br />
TX bytes:368 acl:0 sco:0 commands:31 errors:0<br />
<br />
It is not enabled by default on Ubuntu Edgy systems.<br />
<br />
If it is not then either type : hciconfig hci0 piscan<br />
<br />
Also you can permanently fix this bug by doing the following steps on the laptop: <br />
<br />
1. Add "discovto 0;" to the device section of hcid.conf file in /etc/bluetooth.<br />
<br />
2. Remove all the files present in /var/lib/bluetooth<br />
<br />
3. Restart Bluetooth<br />
<br />
4. Check hciconfig and ISCAN will be enabled.[[User:Deepank|Deepank]] 20:21, 22 August 2007<br />
<br />
== This does not work with 2007.2 / .08 image plus ipkg updates up until August 24? ==<br />
<br />
After starting everything as described, I only get error messages:<br />
<br />
root@fic-gta01:~$ hciconfig<br />
Can't open HCI socket.: Address family not supported by protocol<br />
<br />
root@fic-gta01:~$ modprobe gta01-pm-bt<br />
FATAL: Module gta01_pm_bt not found.<br />
<br />
root@fic-gta01:~$ modprobe hci_usb <br />
WARNING: Could not open '/lib/modules/2.6.21.5-moko10/kernel/net/bluetooth/bluetooth.ko': No such file or directory<br />
FATAL: Could not open '/lib/modules/2.6.21.5-moko10/kernel/drivers/bluetooth/hci_usb.ko': No such file or directory<br />
<br />
Can someone let me know if BT is supposed to work with 2007.2 / .08 plus updates? <br />
<br />
This issue is SOLVED, in a way: kernel 2.6.21.6 seems to be required.<br />
<br />
[[user:hhf423]]<br />
<br />
== Bluetooth keyboards which doesn't support HID: tested a keyboard ==<br />
<br />
I've tested a "Freedom Universal Keyboard", model G912. Wiki says it should work but...<br />
<br />
Doesn't connect on HID mode (connection reset by peer), while on SPP just gives wrong characters, and also keeps sending chars even when not typing.<br />
<br />
Used kbdd too, this time on my desktop with usb dongle. Same thing as above, maybe this model is incompatible/needs special driver?<br />
<br />
[[User:Kiantis|Kiantis]] - 31 Aug 2008<br />
<br />
:I configured the G912 (Freedom Universal Keyboard²) in SPP and directly read serial input. There you get for each typed key a byte. If the MSB is not set (0x80) the key is pressed. With python I managed to feed this keys to /dev/input/uinput. But in the moment I think the script is only usable by myself.--[[User:Plaicy|Plaicy]] 21:31, 31 December 2008 (UTC)</div>Plaicyhttp://openmoko.org/wiki/Talk:Manually_using_BluetoothTalk:Manually using Bluetooth2008-12-31T21:31:27Z<p>Plaicy: /* Bluetooth keyboards which doesn't support HID: tested a keyboard */ should work in SPP</p>
<hr />
<div>== Bluetooth keyboards which doesn't support HID ==<br />
<br />
There exists several bluetooth keyboards which doesn't support the normal HID protocol.<br />
This means you can not simply use "hidd --connect 11:22:33:44:55:66".<br />
I've searched the net a bit and found this: http://www.handhelds.org/moin/moin.cgi/kbdd. The program kbdd seems like the thing to use. The source code is available. I'm not able to test this program myself as I do not have a Neo yet. [[User:EsbenDamgaard|EsbenDamgaard]] 22:10, 16 August 2007 (CEST)<br />
<br />
I have tried it and it works ok for me, there is even an ipkg package for kbdd in Angstrom, see the details in http://n2.nabble.com/Non-HID-Bluetooth-keyboard.-Success%21-td1496389ef1958.html#a1496389 . --[[User:Glownan|Glownan]] 10:56, 14 November 2008 (UTC)<br />
<br />
== Phone does not detect laptop ==<br />
If running hcitool scan on the phone does not detect your laptop, check if ISCAN is enabled on the laptop by typing hciconfig and seeing the output.Like in the following output ISCAN is not enabled.<br />
<br />
hci0: Type: USB<br />
BD Address: 00:19:7E:E5:C2:2F ACL MTU: 1017:8 SCO MTU: 64:8<br />
UP RUNNING PSCAN <br />
RX bytes:1651 acl:0 sco:0 events:42 errors:0<br />
TX bytes:368 acl:0 sco:0 commands:31 errors:0<br />
<br />
It is not enabled by default on Ubuntu Edgy systems.<br />
<br />
If it is not then either type : hciconfig hci0 piscan<br />
<br />
Also you can permanently fix this bug by doing the following steps on the laptop: <br />
<br />
1. Add "discovto 0;" to the device section of hcid.conf file in /etc/bluetooth.<br />
<br />
2. Remove all the files present in /var/lib/bluetooth<br />
<br />
3. Restart Bluetooth<br />
<br />
4. Check hciconfig and ISCAN will be enabled.[[User:Deepank|Deepank]] 20:21, 22 August 2007<br />
<br />
== This does not work with 2007.2 / .08 image plus ipkg updates up until August 24? ==<br />
<br />
After starting everything as described, I only get error messages:<br />
<br />
root@fic-gta01:~$ hciconfig<br />
Can't open HCI socket.: Address family not supported by protocol<br />
<br />
root@fic-gta01:~$ modprobe gta01-pm-bt<br />
FATAL: Module gta01_pm_bt not found.<br />
<br />
root@fic-gta01:~$ modprobe hci_usb <br />
WARNING: Could not open '/lib/modules/2.6.21.5-moko10/kernel/net/bluetooth/bluetooth.ko': No such file or directory<br />
FATAL: Could not open '/lib/modules/2.6.21.5-moko10/kernel/drivers/bluetooth/hci_usb.ko': No such file or directory<br />
<br />
Can someone let me know if BT is supposed to work with 2007.2 / .08 plus updates? <br />
<br />
This issue is SOLVED, in a way: kernel 2.6.21.6 seems to be required.<br />
<br />
[[user:hhf423]]<br />
<br />
== Bluetooth keyboards which doesn't support HID: tested a keyboard ==<br />
<br />
I've tested a "Freedom Universal Keyboard", model G912. Wiki says it should work but...<br />
<br />
Doesn't connect on HID mode (connection reset by peer), while on SPP just gives wrong characters, and also keeps sending chars even when not typing.<br />
<br />
Used kbdd too, this time on my desktop with usb dongle. Same thing as above, maybe this model is incompatible/needs special driver?<br />
<br />
[[User:Kiantis|Kiantis]] - 31 Aug 2008<br />
<br />
:I configured the G912 (Freedom Universal Keyboard²) in SPP and directly read serial input. There you get for each typed key a byte. If the MSB is not set (0x80) the key is pressed. With python a managed to feed this keys to /dev/input/uinput. But in the moment I think the script is only usable by myself.--[[User:Plaicy|Plaicy]] 21:31, 31 December 2008 (UTC)</div>Plaicyhttp://openmoko.org/wiki/WiFi_support_in_OpenMokoWiFi support in OpenMoko2008-10-30T09:50:34Z<p>Plaicy: linkfix</p>
<hr />
<div>#redirect [[Neo FreeRunner Wifi]]</div>Plaicy