Friday, November 12, 2010

Jlime for Nanonote

Jlime in Nanonote

(source: www.jlime.com) The current image brings a X Environment, Matchbox window and desktop manager, and several useful applications (video player, music player, image viewer, text editor, terminal, pdf viewer, dictionary, games….)

Desktop DOCUMENTATION

root password : root

Shortcuts to control the Desktop
ALT+F1 : Hide all windows and focus desktop ALT+F2 : Move backwards between windows immediately ALT+F3 : Move between windows immediately ALT+F4 : Close a window

KEEP THIS LIST OF SHORTCUTS ON HAND! :) or you will have to reboot your system when some application runs fullscreen and you don't know what to press.

Number keys: fn key + number.

Vol keys react as Page up/down on X. But for video player and music player these work as Volume.


NETWORKING

Your muffinman system have already configured its usb0 network interface (IP 192.168.1.202).

Example to set your usb0 on your Linux PC:

ifconfig usb0 192.168.1.200 // set pc usb0 ip, to give your host an IP address which is in the same subnet as your NanoNote.

To review that, you can use ifconfig as well

$ ifconfig usb0

and should get the following:

usb0      Link encap:Ethernet  HWaddr 71:BF:F1:B2:8A:E8
inet addr:192.168.1.200 Bcast:192.168.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:5998 errors:0 dropped:0 overruns:0 frame:0
TX packets:7357 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:357275 (348.9 Kb) TX bytes:9340199 (8.9 Mb)


Modify /etc/network/interfaces as below:

$ sudo gedit /etc/network/interfaces

auto lo

iface lo inet loopback

auto usb0

iface usb0 inet static

address 192.168.1.200

netmask 255.255.255.0

network 192.168.254.0

up iptables -A POSTROUTING -t nat -j MASQUERADE -s 192.168.254.0/24 &

up echo 1 > /proc/sys/net/ipv4/ip_forward &

up iptables -P FORWARD ACCEPT &

down iptables -D POSTROUTING -t nat -j MASQUERADE -s 192.168.254.0/24 &


$ sudo /etc/init.d/networking restart


Do the following to enable internet on the Nanonote

You will most likely need to replace the /etc/resolv.conf nameservers on your nanonote with the proper ones (just use the ones inside your pc's /etc/resolv.conf).


In Nanonote, do following:


Jlime$ cat /etc/resolv.conf
nameserver 10.48.49.25

nameserver 10.32.52.21


Jlime$ route add default gw 192.168.1.200


Now, your Jlime system has internet connection.

After this configuration, next time you boot your Nanonote, you can ssh to Nanonote directly.


PACKAGE MANAGEMENT

NEW!. Now there is a new tool to install packages. It is a script to avoid the swap problems with opkg. The name is jlime-pkg

opkg is already configured to use Jlime repositories.

After you have gotten your internet connection going, its time to grab an list of available packages.

opkg update <-- syncs package database

Examples of actions:

jlime-pkg search  <-- will search some package. Example: jlime-pkg search game jlime-pkg install bash  <--will download and install bash opkg remove bash <--will remove bash from your nanonote

So use jlime-pkg to search and install packages. Use opkg to update and remove packages.

SET DATE and TIME

Use date and hwclock commands.

For example (we are setting 31th of August 2010, at 20:00pm):

date -s 20100831
date -s 20:00 hwclock -w
SHUTDOWN - REBOOT

Use the power ON/OFF button to shutdown the device, always..

APPLICATIONS USAGE

If you want to see/play your files easily:

  • Copy the video files under ~/videos/

  • Copy the music files under ~/music/

  • Copy the image files under ~/image/

  • For text files and other kind of formats use ~/documents/


To transfer file:

Password is 'root'. 

Jlime$ ls

documents images music videos

To transfer PC_FILE to documents folder:

$ scp PC_FILE root@192.168.254.101:~/documents 
To copy NANONOTE_FILE FROM documents folder to you computer:
$ scp root@192.168.254.101:~/documents/NANONOTE_FILE ./
VIDEO PLAYER

Video player is MPlayer.

Keys:
q : quit
o : OSD ON/OFF
0,9 : Volume ( + + )
arrows : backward/forward
space : pause

HOW TO ENCODE : In order to watch 320×240 videos encode your videos on PC with :

 ffmpeg -i your_video_file -ac 1 -ar 22050 -s 320x240 output.mpg
scp output.mpg root@192.168.1.202:
(And then use the video player.)
MUSIC PLAYER

Music player is GMU. Their usage is pretty easy because there is a help at bottom. Main keys :

Keys:
ALT+ENTER : quit
TAB : move between playlist/file selector/etc
IMAGE VIEWER

Image Viewer shows the image files under ~/images/ folder. You can browse them using arrows. “Q key” quits.

DESKTOP LOOK AND FEEL

Muffinman is fully theme-able, because it uses both, Matchbox Window Manager and Matchbox Desktop.

If you want to replace the WALLPAPER, just replace the /etc/muffinman-extras/wallpaper.png file with your wallpaper.png file.

To modify the theme, icons and folders just read the Matchbox Desktop and Window Manager documentation

It is easy, because Matchbox, like others Linux Desktop/Window Managers, uses freedesktop.org specifications.

How to RECORD and PLAY sound files (using mic/speaker)

You can use the “Audio Recorder” application on Desktop. But, if you need manual settings or work done follow the below instructions.

In order to record, the device's “capture” switch must be set. To do so, run alsamixer (Audio Settings), select your microphone (maybe you need to press TAB) and press space. Something like…

 CAPTUR  L    R

should appear. Set the level of the Mic there with arrow keys :33% is okey for good quality.

Then we record a while using the mic with (CD quality, 8 seconds, wav) :

 arecord -d 8 -f cd -t wav test.wav 

Then listen your file with :

 aplay test.wav

No comments :