User:Historybuff/notes

From Openmoko

< User:Historybuff(Difference between revisions)
Jump to: navigation, search
(Note possible clock bug)
(Possible bug: Short summaries for games)
Line 2: Line 2:
  
 
==Possible bug==
 
==Possible bug==
Clock display doesn't update with Timezone display change. (ie TZ change from Standard to Daylight -- ''date"" returns right value, clock no)
+
Clock display doesn't update with Timezone display change. (ie TZ change from Standard to Daylight -- ''date"returns right value, clock no) -- oddly, some weirdness, I had the system clock set wrong (?) and the date bar under the clock was ahead (it was 11 something pm, but should have shown today's date, but instead showed tomorrows)
 +
 
 +
==Software info==
 +
I've been literally playing with my Moko lately, and figured I'd put fingers to keyboard with a little overview. Some of this is just stubs, and some are more informative. The first round of this is a recent (Jan?) build of OM.
 +
 
 +
===Black Box===
 +
Played on a checkerboard type grid. The central board is where the discs(?) are hiding. There is some information displayed surrounding the board, in a flap like extension of the board. More research needed.
 +
 
 +
===Bridges===
 +
A classic bridge building game, I think. A bunch of circles (islands?) populate the playing area, with the inside of each circle denoting how many connections that circle supports. You can't cross connections, and only two connections are permitted directly between each pair of circles. Connect pairs by dragging a connection between them. Drag a third time to reset connections to zero.
 +
Seems to "get mad" sometimes, and turns a circle red and stops allowing any drawing, and means you have to restart that map. Overall fun and easy to play.
 +
 
 +
===Cube===
 +
Giant cube rolls around, picking up blue paint and depositing it on different squares. More research needed
 +
 
 +
===Dominosa===
 +
Grid of numbers, which you are allowed to pick in pairs. Goal is apparently to use all of the pairs up with none left over. More research needed.
 +
 
 +
===Fifteen===
 +
One of those little moving tile puzzles from when you were a kid. Features 15 tiles which interlock, with one free space so that you can slide the tiles around. Goal is to arrange the numbers from lowest to highest, starting with the top left and then going left to right and then down each row. Lots of fun.
 +
 
 +
===Flip===
 +
Grid with a picture, which shows how the "flipping" works. Tiles are two sided, with a grey and a white side, and clicking "flips" the tile. Unsure of the goal. More research needed.
 +
 
 +
===Guess===
 +
Akin to Mastermind. You are trying to figure out the 4 choices, in the correct order, from a possible choice of 6 different colored pegs. The pegs may be repeated. Each "guess" results in clues -- black pegs mean correct color and position, white pegs denote proper color in the wrong position. You drag a color to the position you want to try -- either from a color palette on the side, or from another guessed peg. Click on the 4 small side pegs to see the results of your guess. 10 guesses to get it right. Very good, quite playable.
 +
 
 +
===Inertia===
 +
Played in a crossword like grid, there are diamonds, mines and dotted circles scattered around the board. Mines kill you, diamonds are the treasure you seek. The dotted circles capture you, as the name of the game implies, from  your inertia, as do walls. The surface is akin to ice, in that if you start to move, you'll continue to do so until you stop. Trickier then it seems at first glance, it's good for a few minutes of fun.
 +
 
 +
===Lightup===
 +
Seems like a Sodoku inspired game, of some sort. More research needed.
 +
 
 +
===Loopy===
 +
 
 +
===Map===
 +
The classic computer science problem - given a map with n areas and 4 colors, paint the areas in such a way such that no two adjoining areas have the same color. Simply drag colors from the pre-existing areas to color new areas. If you color an area wrong, just drag the new replacement on top. Easy to play, and can be entertaining.
 +
 
 +
===Mines===
 +
Ever heard of Minesweeper? Same game, different name. I haven't figured out how to mark mines, but other then that, this is a great timewaster.
 +
 
 +
===Net===
 +
Grid, where the grid elements rotate 90 degrees by being tapped. The idea behind this game is to get the source node (box in center) connected by a network of pipes to the sink nodes (blue boxes). Very playable, quite fun.
 +
 
 +
===Netslide===
 +
A variation of Net, this time the tiles around the source slide around, and walls prevent direct connections between some adjacent tiles. More involved then Net, but very playable and still fun.
 +
 
 +
===Pattern===
 +
More research needed.
 +
 
 +
===Pegs===
 +
I played this game as Hi-Q (or some similar name. In the rough shape of a plus sign, you are supposed to use one peg to jump another peg. While this is easy to understand, you are supposed to have as few pegs remaining when you are done as possible. Simply drag to jump pegs. Playable, and still fun, after all these years.
 +
 
 +
===Rect===
 +
More research needed.
 +
 
 +
===Same Game===
 +
3 different color tiles are combined. Goal is to eliminate all of the tiles, but you can only eliminate tiles where there are 2 or more of the same color adjacent to each other.  As you eliminate some tiles, remaining ones "collapse" together.
 +
 
 +
===Sixteen===
 +
Variation of Fifteen, but the tiles all slide horizontal or vertically in a row.
 +
 
 +
===Slant===
 +
More research needed.
 +
 
 +
===Solo===
 +
Sudoku game. No Idea how to get the numbers in.
 +
 
 +
===Tents===
 +
Grid, where you have to layout tents. Numbers along the side tell you how many tents go in each row/column, and there are trees where you can't place tents. Simple, yet can be fun.
 +
 
 +
===Twiddle===
 +
More research needed.
 +
 
 +
===Untangle===
 +
Lines are all tangled up between various points. Your job is to untangle the web, ensuring that no lines cross between the points. Mostly entertaining, but picking the point with your finger can be a little fiddly.
  
 
== Build info ==
 
== Build info ==

Revision as of 20:34, 10 March 2008

These are my scribbles. Should be cleaned up and moved into real pages if useful.

Contents

Possible bug

Clock display doesn't update with Timezone display change. (ie TZ change from Standard to Daylight -- date"returns right value, clock no) -- oddly, some weirdness, I had the system clock set wrong (?) and the date bar under the clock was ahead (it was 11 something pm, but should have shown today's date, but instead showed tomorrows)

Software info

I've been literally playing with my Moko lately, and figured I'd put fingers to keyboard with a little overview. Some of this is just stubs, and some are more informative. The first round of this is a recent (Jan?) build of OM.

Black Box

Played on a checkerboard type grid. The central board is where the discs(?) are hiding. There is some information displayed surrounding the board, in a flap like extension of the board. More research needed.

Bridges

A classic bridge building game, I think. A bunch of circles (islands?) populate the playing area, with the inside of each circle denoting how many connections that circle supports. You can't cross connections, and only two connections are permitted directly between each pair of circles. Connect pairs by dragging a connection between them. Drag a third time to reset connections to zero. Seems to "get mad" sometimes, and turns a circle red and stops allowing any drawing, and means you have to restart that map. Overall fun and easy to play.

Cube

Giant cube rolls around, picking up blue paint and depositing it on different squares. More research needed

Dominosa

Grid of numbers, which you are allowed to pick in pairs. Goal is apparently to use all of the pairs up with none left over. More research needed.

Fifteen

One of those little moving tile puzzles from when you were a kid. Features 15 tiles which interlock, with one free space so that you can slide the tiles around. Goal is to arrange the numbers from lowest to highest, starting with the top left and then going left to right and then down each row. Lots of fun.

Flip

Grid with a picture, which shows how the "flipping" works. Tiles are two sided, with a grey and a white side, and clicking "flips" the tile. Unsure of the goal. More research needed.

Guess

Akin to Mastermind. You are trying to figure out the 4 choices, in the correct order, from a possible choice of 6 different colored pegs. The pegs may be repeated. Each "guess" results in clues -- black pegs mean correct color and position, white pegs denote proper color in the wrong position. You drag a color to the position you want to try -- either from a color palette on the side, or from another guessed peg. Click on the 4 small side pegs to see the results of your guess. 10 guesses to get it right. Very good, quite playable.

Inertia

Played in a crossword like grid, there are diamonds, mines and dotted circles scattered around the board. Mines kill you, diamonds are the treasure you seek. The dotted circles capture you, as the name of the game implies, from your inertia, as do walls. The surface is akin to ice, in that if you start to move, you'll continue to do so until you stop. Trickier then it seems at first glance, it's good for a few minutes of fun.

Lightup

Seems like a Sodoku inspired game, of some sort. More research needed.

Loopy

Map

The classic computer science problem - given a map with n areas and 4 colors, paint the areas in such a way such that no two adjoining areas have the same color. Simply drag colors from the pre-existing areas to color new areas. If you color an area wrong, just drag the new replacement on top. Easy to play, and can be entertaining.

Mines

Ever heard of Minesweeper? Same game, different name. I haven't figured out how to mark mines, but other then that, this is a great timewaster.

Net

Grid, where the grid elements rotate 90 degrees by being tapped. The idea behind this game is to get the source node (box in center) connected by a network of pipes to the sink nodes (blue boxes). Very playable, quite fun.

Netslide

A variation of Net, this time the tiles around the source slide around, and walls prevent direct connections between some adjacent tiles. More involved then Net, but very playable and still fun.

Pattern

More research needed.

Pegs

I played this game as Hi-Q (or some similar name. In the rough shape of a plus sign, you are supposed to use one peg to jump another peg. While this is easy to understand, you are supposed to have as few pegs remaining when you are done as possible. Simply drag to jump pegs. Playable, and still fun, after all these years.

Rect

More research needed.

Same Game

3 different color tiles are combined. Goal is to eliminate all of the tiles, but you can only eliminate tiles where there are 2 or more of the same color adjacent to each other. As you eliminate some tiles, remaining ones "collapse" together.

Sixteen

Variation of Fifteen, but the tiles all slide horizontal or vertically in a row.

Slant

More research needed.

Solo

Sudoku game. No Idea how to get the numbers in.

Tents

Grid, where you have to layout tents. Numbers along the side tell you how many tents go in each row/column, and there are trees where you can't place tents. Simple, yet can be fun.

Twiddle

More research needed.

Untangle

Lines are all tangled up between various points. Your job is to untangle the web, ensuring that no lines cross between the points. Mostly entertaining, but picking the point with your finger can be a little fiddly.

Build info

Get your daily Snapshot_review -- find out if a snapshot works before you flash it.

GPS stuff

GPS Sight - seems to be a basic track visualizer

Ugly hack to get Time info from a GPS stream: (UNTESTED)

awk -F',' '/^\$GPRMC/{print "date "substr($10,3,2) substr($10,1,2) 
substr($2,1,2) substr($2,3,2) 2000+substr($10,5)"."substr($2,5)}'

(all on one line, cut for readability)

[1] contains some good info for decoding, and [2] is a good link for getting started. Another good link is here at OSM

There are some reasonable packages which can help with GPS now, such as Navit and Pyroute (thanks User:Wurp. I'll have to hack at them a bit when I get a chance.

I've done some hacking with awk scripts, so I know a bit about the layout and format of the various NMEA bits. For one bit that is undocumented, here is a ref to the OM repo - the bit I was looking for was the $PGLOR sentence.

Power/PM/tray icon

Module for mb_panel -- should use /proc/apm to look at Power remaining. Reference is here

Getting Battery status: cat `find /sys/ -name battvolt` the output is in millivolts. ~4224 millivolts is completely charged (observed 3568 lowest, 4207 highest)

exact location is /sys/devices/platform/s3c2410-i2c/i2c-adapter/i2c-0/0-0008/

nicer script (cwd must be above)- CHARGE=`cat battvolt` && awk -v charge=${CHARGE} 'BEGIN {print charge/4224*100" "charge }'

A nice script that allows you to up the charger speed -- Make sure your charging device won't be smoked! CheckFastCharge-script

uncatted now

This is a mess right now, but undergoing cleaning.

There is a project to get FreeBSD working on the Neo. Might be something to look at later in March.

Setting the timezone: [3] (I had to use a hard link, but a symlink should work. Remember to log out (remote) or cycle the GUI/reboot to get this to take effect).

Development with Eclipse - have to check it out.

The essential GSM_850_test

Orientation of screen:

xrandr -o 1 turns screen to landscape mode (xrandr -o 0 to go back to ordinary portrait)


GTA01_gsm_modem for AT commands; Gsmd for manual AT stuff

To get sound working: alsactl -f /etc/alsa/gsmhandset.state restore

Trying to record sound from the mic:

cat /dev/dsp does sample the ADC It's then 'simply' a case of setting the mixer controls so that the sound is routed from the mic to the adc See the nice simple explanatory block diagram in the middle of http://wiki.openmoko.org/wiki/Neo1973_Audio_Subsystem for guidance. In principle. You need to find which mic input the mic is connected to, setup the input gain and mic selector appropriately,setup the ALC mixer right, then set it up to route to the left or right ADC alsactl can do it (alsamixer)

alsactl -f /etc/alsa/capturehandset.state restore
arecord -f cd -t wav -d 10 foo.wav
Make noise for 10 seconds
alsactl -f /etc/alsa/stereoout.state restore
aplay foo.wav

Note from User:Wurp: You'll need to shut down pulseaudio before aplay will work (you also need to do this to get mplayer to play audio). Use '/etc/init.d/pulseaudio stop' before 'aplay foo.wav'. There is probably a better way to do this, but I don't know it.

Booting: Old boot noise documented here

more GPS:

Note from User:Wurp: I got an awk script, I think from SpeedEvil, that deciphers /tmp/nmeaNP. Here it is:

BEGIN{FS=","}
/GPRMC/{v=$8*1.1507}
/PGRME/{herr=sqrt($2^2+$4^2); err=$6}
/GPGGA/{
h=substr($2,1,2)
m=substr($2,3,2)
s=substr($2,5,2)
ndeg=substr($3,1,2)
nmin=substr($3,3)
wdeg=substr($5,1,3)
wmin=substr($5,4)}
/GPRMC/{print substr($10,1,2)"/"substr($10,3,2)"/"substr($10,5,2), h":"m":"s,(h*3600)+(m*60)+s,ndeg,nmin,wdeg,wmin, ndeg+(nmin/60),wdeg+(wmin/60), $10,$9,herr+0,err+0,v }

I prefer to use gpsd output, though, via pygps.

Personal tools
These are my scribbles. Should be cleaned up and moved into real pages if useful.

Possible bug

Clock display doesn't update with Timezone display change. (ie TZ change from Standard to Daylight -- date"returns right value, clock no) -- oddly, some weirdness, I had the system clock set wrong (?) and the date bar under the clock was ahead (it was 11 something pm, but should have shown today's date, but instead showed tomorrows)

Software info

I've been literally playing with my Moko lately, and figured I'd put fingers to keyboard with a little overview. Some of this is just stubs, and some are more informative. The first round of this is a recent (Jan?) build of OM.

Black Box

Played on a checkerboard type grid. The central board is where the discs(?) are hiding. There is some information displayed surrounding the board, in a flap like extension of the board. More research needed.

Bridges

A classic bridge building game, I think. A bunch of circles (islands?) populate the playing area, with the inside of each circle denoting how many connections that circle supports. You can't cross connections, and only two connections are permitted directly between each pair of circles. Connect pairs by dragging a connection between them. Drag a third time to reset connections to zero. Seems to "get mad" sometimes, and turns a circle red and stops allowing any drawing, and means you have to restart that map. Overall fun and easy to play.

Cube

Giant cube rolls around, picking up blue paint and depositing it on different squares. More research needed

Dominosa

Grid of numbers, which you are allowed to pick in pairs. Goal is apparently to use all of the pairs up with none left over. More research needed.

Fifteen

One of those little moving tile puzzles from when you were a kid. Features 15 tiles which interlock, with one free space so that you can slide the tiles around. Goal is to arrange the numbers from lowest to highest, starting with the top left and then going left to right and then down each row. Lots of fun.

Flip

Grid with a picture, which shows how the "flipping" works. Tiles are two sided, with a grey and a white side, and clicking "flips" the tile. Unsure of the goal. More research needed.

Guess

Akin to Mastermind. You are trying to figure out the 4 choices, in the correct order, from a possible choice of 6 different colored pegs. The pegs may be repeated. Each "guess" results in clues -- black pegs mean correct color and position, white pegs denote proper color in the wrong position. You drag a color to the position you want to try -- either from a color palette on the side, or from another guessed peg. Click on the 4 small side pegs to see the results of your guess. 10 guesses to get it right. Very good, quite playable.

Inertia

Played in a crossword like grid, there are diamonds, mines and dotted circles scattered around the board. Mines kill you, diamonds are the treasure you seek. The dotted circles capture you, as the name of the game implies, from your inertia, as do walls. The surface is akin to ice, in that if you start to move, you'll continue to do so until you stop. Trickier then it seems at first glance, it's good for a few minutes of fun.

Lightup

Seems like a Sodoku inspired game, of some sort. More research needed.

Loopy

Map

The classic computer science problem - given a map with n areas and 4 colors, paint the areas in such a way such that no two adjoining areas have the same color. Simply drag colors from the pre-existing areas to color new areas. If you color an area wrong, just drag the new replacement on top. Easy to play, and can be entertaining.

Mines

Ever heard of Minesweeper? Same game, different name. I haven't figured out how to mark mines, but other then that, this is a great timewaster.

Net

Grid, where the grid elements rotate 90 degrees by being tapped. The idea behind this game is to get the source node (box in center) connected by a network of pipes to the sink nodes (blue boxes). Very playable, quite fun.

Netslide

A variation of Net, this time the tiles around the source slide around, and walls prevent direct connections between some adjacent tiles. More involved then Net, but very playable and still fun.

Pattern

More research needed.

Pegs

I played this game as Hi-Q (or some similar name. In the rough shape of a plus sign, you are supposed to use one peg to jump another peg. While this is easy to understand, you are supposed to have as few pegs remaining when you are done as possible. Simply drag to jump pegs. Playable, and still fun, after all these years.

Rect

More research needed.

Same Game

3 different color tiles are combined. Goal is to eliminate all of the tiles, but you can only eliminate tiles where there are 2 or more of the same color adjacent to each other. As you eliminate some tiles, remaining ones "collapse" together.

Sixteen

Variation of Fifteen, but the tiles all slide horizontal or vertically in a row.

Slant

More research needed.

Solo

Sudoku game. No Idea how to get the numbers in.

Tents

Grid, where you have to layout tents. Numbers along the side tell you how many tents go in each row/column, and there are trees where you can't place tents. Simple, yet can be fun.

Twiddle

More research needed.

Untangle

Lines are all tangled up between various points. Your job is to untangle the web, ensuring that no lines cross between the points. Mostly entertaining, but picking the point with your finger can be a little fiddly.

Build info

Get your daily Snapshot_review -- find out if a snapshot works before you flash it.

GPS stuff

GPS Sight - seems to be a basic track visualizer

Ugly hack to get Time info from a GPS stream: (UNTESTED)

awk -F',' '/^\$GPRMC/{print "date "substr($10,3,2) substr($10,1,2) 
substr($2,1,2) substr($2,3,2) 2000+substr($10,5)"."substr($2,5)}'

(all on one line, cut for readability)

[1] contains some good info for decoding, and [2] is a good link for getting started. Another good link is here at OSM

There are some reasonable packages which can help with GPS now, such as Navit and Pyroute (thanks User:Wurp. I'll have to hack at them a bit when I get a chance.

I've done some hacking with awk scripts, so I know a bit about the layout and format of the various NMEA bits. For one bit that is undocumented, here is a ref to the OM repo - the bit I was looking for was the $PGLOR sentence.

Power/PM/tray icon

Module for mb_panel -- should use /proc/apm to look at Power remaining. Reference is here

Getting Battery status: cat `find /sys/ -name battvolt` the output is in millivolts. ~4224 millivolts is completely charged (observed 3568 lowest, 4207 highest)

exact location is /sys/devices/platform/s3c2410-i2c/i2c-adapter/i2c-0/0-0008/

nicer script (cwd must be above)- CHARGE=`cat battvolt` && awk -v charge=${CHARGE} 'BEGIN {print charge/4224*100" "charge }'

A nice script that allows you to up the charger speed -- Make sure your charging device won't be smoked! CheckFastCharge-script

uncatted now

This is a mess right now, but undergoing cleaning.

There is a project to get FreeBSD working on the Neo. Might be something to look at later in March.

Setting the timezone: [3] (I had to use a hard link, but a symlink should work. Remember to log out (remote) or cycle the GUI/reboot to get this to take effect).

Development with Eclipse - have to check it out.

The essential GSM_850_test

Orientation of screen:

xrandr -o 1 turns screen to landscape mode (xrandr -o 0 to go back to ordinary portrait)


GTA01_gsm_modem for AT commands; Gsmd for manual AT stuff

To get sound working: alsactl -f /etc/alsa/gsmhandset.state restore

Trying to record sound from the mic:

cat /dev/dsp does sample the ADC It's then 'simply' a case of setting the mixer controls so that the sound is routed from the mic to the adc See the nice simple explanatory block diagram in the middle of http://wiki.openmoko.org/wiki/Neo1973_Audio_Subsystem for guidance. In principle. You need to find which mic input the mic is connected to, setup the input gain and mic selector appropriately,setup the ALC mixer right, then set it up to route to the left or right ADC alsactl can do it (alsamixer)

alsactl -f /etc/alsa/capturehandset.state restore
arecord -f cd -t wav -d 10 foo.wav
Make noise for 10 seconds
alsactl -f /etc/alsa/stereoout.state restore
aplay foo.wav

Note from User:Wurp: You'll need to shut down pulseaudio before aplay will work (you also need to do this to get mplayer to play audio). Use '/etc/init.d/pulseaudio stop' before 'aplay foo.wav'. There is probably a better way to do this, but I don't know it.

Booting: Old boot noise documented here

more GPS:

Note from User:Wurp: I got an awk script, I think from SpeedEvil, that deciphers /tmp/nmeaNP. Here it is:

BEGIN{FS=","}
/GPRMC/{v=$8*1.1507}
/PGRME/{herr=sqrt($2^2+$4^2); err=$6}
/GPGGA/{
h=substr($2,1,2)
m=substr($2,3,2)
s=substr($2,5,2)
ndeg=substr($3,1,2)
nmin=substr($3,3)
wdeg=substr($5,1,3)
wmin=substr($5,4)}
/GPRMC/{print substr($10,1,2)"/"substr($10,3,2)"/"substr($10,5,2), h":"m":"s,(h*3600)+(m*60)+s,ndeg,nmin,wdeg,wmin, ndeg+(nmin/60),wdeg+(wmin/60), $10,$9,herr+0,err+0,v }

I prefer to use gpsd output, though, via pygps.