Wednesday, April 27, 2011

Fun with old Siemens Cellular Phones



I still use a Siemens M55 phone and this article describes how one can use this phone for data transfers, GRPS modem and several other things in Linux.

Background

In 2004 I was an intern at the University of Waterloo. I was doing my research term there that was actually part of my undergraduate curriculum at my home university in Germany.
The first thing to do in Canada was to stay connected, so I got a prepaid SIM card from Fido at the time. I always loved pay as you go tariffs from Germany so I wanted to have something similar there too. Sticking it into my beloved Nokia 3310 at that time, I had to find out that this phone did not support the North American frequency band. So I had to get a new phone. What I got was a very nice Siemens M55 phone at the time for about 185$. It served me well during my internship. Unfortunately it was SIM-locked, so I left it with my cousin at that time and returned back to Germany… 3 years later in 2007, I started my PhD studies in Canada again and got it back. It was kind of cute to switch it on after it has been unused for 3 years and find out that it was still working. I really fell in love with that phone and still use it today. It is the most dependable mobile phone I had so far. I had a brief affair with a Blackberry Tour that was given to me by a friend to write some software for it, but after I gave it back, I fell back to using my M55 again.
Even though Siemens is not making anymore mobile phones for quite a while already, spare parts are still widely available. The other thing to note is the dependability of the phone. The phone is currently about 7 years old, still has the original Lithium Ion battery that still lasts about 2.5 days. It survived several falls on stairs and walkways so far.
These days I got back to Europe for a few weeks and decided to unlock the phone for a local carrier, because Fido roaming is just overkill over here. As it turns out buying a used and unlocked M55 on eBay Germany with all the extras turned out to be cheaper (5 EUR + shipping). So I got a second nice one.
Since I have to travel around a lot here I actually want to use the phone to its full extend, including mobile internet connectivity via GRPS. Here is the story how to revive some untouched open source software projects and configure a more recent Linux to work all the features of this phone, including file system access, sending short messages, synchronizing calendars and synchronizing phone books. You can download all the features at the end.

The Phone Specifications

(bottom left is a Pour-le-Merite Zippo
to get an idea of the size of the phone and camera)

If you see these specs below, you might think that I am anachronistic person; but as the old saying goes a craftsman is judged by the quality of his work not by his tools. This also applies somewhat to computer engineers like me. If you want to use a cellular phone for phone calls, “texting”, and as modem… you do not need an expensive bloated I-Phone, Blackberry or other prestigious smart phones. This one is just fine; plus you safe significant amounts of money on the data plan.
2G Network
GSM 900, 1800, 1900
Announced
Q2 2003… nowadays discontinued
Display
CSTN 4096 colours, 101x80px, 7 lines
(yes that is old-school!!!)
Sound
Vibration, polyphonic ring-tones, voice notes (Intel ADPCM codec)
Memory
500 phone book entries @ 14 fields,
Call records: 10 dialled, 10 received, 10 missed
Calendar entries: 999
A simple file system to manage profiles, pictures, and audio.
And all of just within 1.8 MBs.
(Today you can buy more than 16GB of micro SD-cards for your I-Phone/Blackberry)
Battery
Standard Li-Ion 700 mAh (up to 250h standby, 6h talking)
…. Mine still lasts about 2.5 days after 7 years of use… Try to get that out of an I-Phone or Blackberry battery made in China
Java
MIDP-1.0, CLDC-1.0
with close to none of the useful JSRs implemented.
More info here
Camera
This is the really fun part…
EXTERNAL!
Siemens QuickPic Camera IQP-510
CMOS 640 x 480 24 bit
Focus: 40 cm – infinity
Automatic shutter: 1/4000 – 1/8 second
with LED flash
(each picture is about 60kb JPEG / 6kb QVGA)
In 2003 this was top notch and in terms of features and usability more than enough for a general purpose cell phone. Yes and it is still usable if you want to use it as phone and a little bit beyond.
In the following sections I will not talk about making phone calls or how to take pictures but elaborate on some of the data integration problems when you want to use this phone in Linux.

Data Connectivity
This phone came with USB cable. As it turns out this cable is just a simple USB-Serial adapter. Once you connect it, it shows up as serial port in Ubuntu.
treideme@PROBLEM:~$ dmesg
[15212.672612] usb 5-2: new full speed USB device using uhci_hcd and address 14
[15212.835492] usb 5-2: configuration #1 chosen from 1 choice
[15212.837416] pl2303 5-2:1.0: pl2303 converter detected
[15212.853324] usb 5-2: pl2303 converter now attached to ttyUSB0
treideme@PROBLEM:~$ lsusb
Bus 005 Device 014: ID 067b:2303 Prolific Technology, Inc. PL2303 Serial Port

Phone records management
Since I have now two phones I need to move the data from one phone to the other. As it turns out SCMxx a tool that was widely used in the past to manage Siemens phones still ships with Ubuntu. This one allows you to manage text messages, call logs, phone books and the calendar on the command line. You can also inquire the phone specs and the state of the memory banks.

Phone info:
treideme@PROBLEM:~$ scmxx -d /dev/ttyUSB0 --info
Accessing device /dev/ttyUSB0...done
OK, a modem device is present.
Phone related information:
Vendor:       SIEMENS
Model:        M55
Revision:     11
IMEI:         xxx
Battery:      70%
Charsets:     GSM, UCS2
Time:         Wed 27 Apr 2011 12:41:44 PM EDT

SIM card related information:
IMSI:         xxx
card ID:      xxx

Network related information:
Status:       registered, roaming
Area code:    017C
Cell ID:      0CC9
Operator:     Vodafone D2
SMS server:   +15149931123
Signal:       -51 dBm
GPRS class:   B
GRPS status:  not registered, not searching, detached

Available memories:
Binary files:  bmp, mid, vcf, vcs, t9d
Phonebooks:    FD, SM, ON, LD, MC, RC, OW, SD, MS, CD, BL, MB, RD, CS, VCF
SMS storages:  MT, SM, ME

Settings:
Locks: CS, PS, PF, SC, AO, OI, OX, AI, IR, AB, AG, AC, FD, PN, PU, PP, PC

Memory info:
treideme@PROBLEM:~$ scmxx -d /dev/ttyUSB0 --mem-info
Accessing device /dev/ttyUSB0...done
Detected SIEMENS M55
Binary files: 
mem  readable  writable  description 
---  --------  --------  ----------- 
bmp     0-2       0-4    bitmap
mid    0-10      0-10    midi
vcf    0-500     0-500   vCard (address book)
vcs    1-500     0-500   vCalendar
t9d    none        0     T9 database

Phonebooks:   
mem  slots   writable  digits  chars  description 
---  ------  --------  ------  -----  ----------- 
FD    1-20      yes      20      18   SIM fix-dialing phonebook
SM    1-255     yes      20      18   SIM phonebook
ON     1-4      yes      20      18   own numbers
LD    1-10      no       20      18   last calls (SIM)
MC    1-10      no       20      18   missed calls
RC    1-10      no       20      18   callback numbers
OW     1-4      no       20      18   own numbers
SD     1-5      no       20      18   service numbers
MS    1-10      no       20      18   missed calls
CD    1-10      no       20      18   callback numbers
BL     1-8      no       20      0    blacklist numbers
MB     1-2      no       20      10   mailbox numbers
RD    none      no       20      31   red book (VIP in CS)
CS     1-2      no       20      31   common sortable (FD+SM+ME)
VCF    1-2      no                    address book numbers

SMS storages: 
mem   slots     used    description 
---  ------  ---------  ----------- 
MT    1-150    14/150   ME + SM
SM    1-50      0/50    SIM memory
ME    1-100    14/100   mobile equipment memory

To download the phonebook records into a CSV file use this one:
treideme@PROBLEM:~$ scmxx -d /dev/ttyUSB0 --get -P --out=pbook.pb
Using "UTF-8" as system character set.
Accessing device /dev/ttyUSB0...done
OK, a modem device is present.
Detected SIEMENS M55
Receiving phonebook entries...
SM(1-255) [===] 100%

The format of the phonebook is
{ID},”{PHONE NUMBER}”,”{NAME}

The phonebook can be re-imported this way:
treideme@PROBLEM:~$ scmxx -d /dev/ttyUSB0 --send -P pbook.pb
Accessing device /dev/ttyUSB0...done
Detected SIEMENS M55
Updating entries SM(1-255) [===] 100%
done

One should note that this is a very crude way to update the phone book. I think this format is kind of the greatest common denominator when it comes to exchanging the records. With a little bit of tweaking one can actually import and export the raw phone records as vcf, as follows:

treideme@PROBLEM:~$ scmxx -d /dev/ttyUSB0 --get --binary --mem="vcf" --out=record_
Using "UTF-8" as system character set.
Accessing device /dev/ttyUSB0...done
OK, a modem device is present.
Detected SIEMENS M55
vcf slot 0 [===] 100%

vcf slot 500 [===] 100%

This approach preserves the individual fields and exports the records as individual VCF files. It will only create VCF files for records that are taken out of the 500. In my case I had just 10 records to be backed up that ended up being record_000.vcf to record_009.vcf.
Each of those files can then be imported with (or better script this in a bash for loop). Note you explicitly need to address a particular slot to update. This makes cross-device data integration a bit complicated. For replacing the first 10 records of the “new-old phone” with those ten records of my “old-old phone”, I just used:

treideme@PROBLEM:~$ for i in `seq 0 9`
> do
> scmxx -d /dev/ttyUSB0 --send --binary --mem="vcf" --slot ${i} record_00${i}.vcf
> done
Accessing device /dev/ttyUSB0...done
OK, a modem device is present.
Detected SIEMENS M55
Using slot 0
File transfer...
Waiting for data request...Sending data...Packet 1 sent
File transfer complete.

Updating and managing the calendar records (VCS) works likewise. However, I did not have to back anything up. Writing a script that synchronizes the records with Google calendar is on the list for future hacks. So far I was fine to have Google Calendar send me notifications via SMS.

File Management (Ring-tones, Pictures, …)

While SCMxx is a nice tool to manage the records of the phone, it does not provide enough functionality to actually transfer files on and off it. A bit of searching on Google revealed that someone in the past wrote a user file system driver for Siemens phones. SIEFS theoretically allows you to mount the file system of the phone directly. That way you can upload and download files off it; and that is only from memory banks that are not locked. If you use scmxx –info (see previous section) it will show you which memory banks are locked.
The bad news, this project has not been maintained for over 6 years. The latest working configuration used fuse-2.0 and kernel-2.4.x. Being brave I downloaded it and attempted to build it. After fixing some issues manually in the code (most notably outdated autoconf/automake references, missing libraries and some legacy system calls), I finally managed to get it run. I can send you a patch for the 0.5 version for Ubuntu karmic 9.10 upon request. As shown below this code is still quite buggy and occasionally crashes.
Once you managed to build and install it, you can mount the plugged into the USB jack as follows:
treideme@PROBLEM:~$ sudo mount -t siefs /dev/ttyUSB0 /mnt1/
[sudo] password for treideme:
treideme@PROBLEM:~$ sudo ls /mnt1
ls: reading directory /mnt1: Input/output error
# Yes above one of those random crashes I’m talking about
# Unplug the usbcable, remount and then try again and it works…
treideme@PROBLEM:~$ sudo ls -l /mnt1
total 0
drwxrwxrwx 1 root root 0 2003-01-01 00:00 Address book
drwxrwxrwx 1 root root 0 2003-01-01 00:08 apo
drwxrwxrwx 1 root root 0 2003-01-01 00:08 Cache
drwxrwxrwx 1 root root 0 2003-01-01 00:00 Colour scheme
drwxrwxrwx 1 root root 0 2003-01-01 00:00 Customization
drwxrwxrwx 1 root root 0 2003-01-01 00:08 Data inbox
drwxrwxrwx 1 root root 0 2003-01-01 00:10 email
drwxrwxrwx 1 root root 0 2003-01-01 00:08 Internet
drwxrwxrwx 1 root root 0 2003-01-01 00:00 Java
drwxrwxrwx 1 root root 0 2003-01-01 00:00 PersistentData
drwxrwxrwx 1 root root 0 2003-01-01 00:00 Pictures
drwxrwxrwx 1 root root 0 2003-01-01 00:00 Sounds

To unmount just use:
treideme@PROBLEM:~$ sudo umount /mnt1

The pictures taken from the camera have an average size of about 60KB and reside in “Data Inbox”. Ring-tones and event messages are in “Sounds”. Apparently, this phone can also record voice memos in its own format. SIEFS has a tool to convert those files into uncompressed WAV.
Looking at the existing WAV files for event notifications it turns out that this phone actually supports Intel’s ADPCM encoding (but not MP3), which can compress WAV files by a fair bit. All existing wav files were encoded as Mono, 16000Hz, 32bit float, Intel ADPCM files. I added some custom ring tones by converting them (from 32 bit, Mono, 16000Hz Microsoft uncompressed WAV) to Intel ADPCM using ffmpeg as follows.

treideme@PROBLEM:~$ ffmpeg -i licht.wav -acodec adpcm_ima_wav licht2.wav

Please keep things small and short. Remember this phone only has 1.8 MB of total storage. Once you take a few pictures and have some ring-tones that space is gone.

GPRS Modem
As it turns out the USB-Serial connector that serves as data cable can be directly used as modem in Linux. Hacking around with Mincom, I realized that it actually accepts valid Hayes AT commands. Playing around with them you can associate the phone with GRPS and dial into IP services. Here some hacks explained.

First set-up Mincom:
treideme@PROBLEM:~$ minicom -s


Go to serial port set-up and put in the appropriate port. My settings are shown below

Now “exit” and start hacking. A “#” is a comment that explains the individual AT commands.

Welcome to minicom 2.3                                                        
                                                                              
OPTIONS: I18n                                                                 
Compiled on Sep 25 2009, 23:45:34.                                            
Port /dev/ttyUSB0                                                             
                                                                              
                 Press CTRL-A Z for help on special keys                                    
                                                                                            
AT S7=45 S0=0 L1 V1 X4 &c1 E1 Q0                                                             
OK                                                                                          
# Above was the default minicom modem init sequence
# below here you start to enter stuff
# let’s see if it actually accepts AT commands
AT                                                                                           
OK
# Look if we are already associated with GRPS?
AT+CGATT?                                                                     
+CGATT: 0                                                                      
                                                                              
OK    
# +CGATT: 0 = Nope we are not...
# So lets do it
AT+CGATT=1                                                                    
OK
# Wait a couple seconds and check again
AT+CGATT?                                                                     
+CGATT: 1                                                                     
                                                                               
OK
# Yay!!!

Ok now things become provider specific. When I did this I still had my SIM card from Fido sitting in the phone. Below you see the Fido configuration for the GPRS service call. In general you specify this command as

AT+CGDCONT=,"IP","{APN}"

The list of APNs can be obtained here for individual providers. The config num enumerates the devices APN configuration index. I usually use 1, if you have multiple providers you can use other indexes as well. Once you dial the GPRS service you need to remember that index again.
For Fido and the first configuration index it ends up being:
AT+CGDCONT=1,"IP","internet.fido.ca"
OK

Now dial the appropriate index to become connected and see if the configuration works.
# ATD *99***#
# so for configuration index 1… wait a couple seconds
ATD*99***1#
CONNECT

Now that we validated that the phone supports GRPS modem and we also paid for GPRS services, we can configure wvdial with it and use it for Internet connectivity.
/etc/wvdial.conf:
[Dialer Defaults]
Modem = /dev/ttyUSB0
Baud = 115200
Init1 = AT+CGDCONT=1,"IP","internet.fido.ca"
Init2 =
Init3 =
Area Code =
Phone = *99***1#
Username = internet
Password = internet
Ask Password = 0
Dial Command = ATD
Stupid Mode = 1
Compuserve = 0
Force Address =
Idle Seconds = 0
DialMessage1 =
DialMessage2 =
ISDN = 0
Auto DNS = 1
Check Def Route = 1


Just issuing wvdial connects us with the Internet:
treideme@PROBLEM:~$ sudo wvdial
--> WvDial: Internet dialer version 1.60
--> Cannot get information for serial port.
--> Initializing modem.
--> Sending: AT+CGDCONT=1,"IP","internet.fido.ca"
AT+CGDCONT=1,"IP","internet.fido.ca"
OK
--> Modem initialized.
--> Sending: ATD*99***1#
--> Waiting for carrier.
ATD*99***1#
CONNECT
--> Carrier detected.  Starting PPP immediately.
--> Starting pppd at Wed Apr 27 08:27:59 2011
--> Pid of pppd: 25044
--> Using interface ppp0
--> local  IP address 25.30.202.165
--> remote IP address 192.168.254.254
--> primary   DNS address 64.71.255.198
--> secondary DNS address 64.71.255.253

Yay. Now we are connected through a very thin life-line to the Internet. The bandwidth of the GRPS data service is somewhere in between 38kbit – 114kbit, depending on the link quality and the usage of the cell.
Although you now get downloads at a rate of 6kb/second you can load Gmail in HTML mode and use Skype for messaging. For emergency situations like going on vacation without proper internet this is a still a viable solution.
Note the GRPS configuration of any other 2G phone that accepts Hayes AT commands directly is identical. Just figure out APN of your network and put it in the configuration.

I hope some other anachronistic people out there who still use 2G phones or are in rural areas with just GRPS services (Middle-East, India, China, …) find this info helpful. On modern 3G phones you will have other options like UMTS high-bandwidth internet connectivity in Europe or the Edge network services in North America. Most of the so-called smart-phones will enable you to use their interface directly for the internet. You may also get a dedicated App for your email service, such that you do not really need to hack your phone as modem.

Other useful references:

Friday, April 8, 2011

Final Exam Survival - Designing, Preparing for, and Taking It.

Final Exam Survival -
Designing, Preparing for, and Taking It.

I have no home; I make awareness my dwelling.
I have no means; I make understanding my means.
I have no eyes; I make the flash of lightning my eyes.
I have no strategy; I make “unshadowed by thought” my strategy.
I have no enemy; I make carelessness my enemy.
(A few related verses from the samurai creed of an unnamed samurai;
Japan c.a. 13th century)


I have been teaching SE350 the operating systems course at the University of Waterloo this term. This Monday I concluded the lecture and now the students enter the final stage towards the final exam. After I finished designing the exam yesterday, I thought about some valuable lessons that I made during the process. These may be useful for other instructors in getting their exam right.
In addition my student quality indicators still are in the red for some of the students (more about this measure in a future post; but yes guys you were profiled big time) and it appears that they do not have the right methodology to prepare for the exam. Having designed this exam and being a student for the better part of the decade also enables me to talk about some useful lessons.

The Profs View - Exam Design Tactics

My original hiring committee told me that my job is teaching an operating systems course. In a bit over 35 lectures I explained the students anything from basic computer architecture to file system design. I also motivated them a bit about the field of embedded systems. My assignment is a success, if the overwhelming majority of students walk out of the course with a reasonable understanding of operating system concepts. So what does this have to do with the exam: The exam is one of the means to make sure only those walk out of the door with high grades that do actually understand these concepts.

Understanding happens at several levels and a certain spread in preparation. Here is a rough scale where I want to see certain student groups.
Grade
Description
0-5
At the very low end you have one or two students, who never showed up during the lecture and are stupid enough to take the exam. They will have little to no understanding of operating systems.
5-35
Then there will be a few who went to the lecture but did not make the effort to properly prepare for the exam at all. They also failed the related course project. Although they showed effort, the acquired skills will be of little use in practice.
35-60
Ending up in this range can have a diversity of reasons. Lack of concentration, panic etc. Someone who falls in this range should have a little understanding of the concepts, went to the tutorials, and followed the lecture. However, the level of understanding is not enough to really release them into the public. I would be seriously worried if those guys ever write system software.
60-80
Students in this range know the concepts. They followed the lecture, went to the tutorials and can solve simple problems by applying the algorithms of the lecture. Most of the students in this range also did well during their course project and reinforced the stuff learned in the lecture by applying it on the project. They usually also considered additional materials like the course text for the exam preparation. I would be relatively confident to release those guys into the public. In practice they will make the appropriate decisions with some aid based on what they have learned in the course.
80-100
The elite. These guys know stuff and can solve complex problems easily. They probably had close to no life and just focused on the exam preparation. I would be very confident to release those guys into the field because they know their stuff. The fact that they put so much preparation into it should show up in the marks as well as being better than the rest of the crowd.

First of all, I will not have any multiple-choice questions. Personally, I regard these tests as one of the more brain-dead approaches to evaluate students (long philosophical discussion skipped here).
My exam is designed in a way that I try to catch the 1-35 percentiles with dedicated questions. I have two questions in my exam that will just ask you to define and distinguish some very basic concepts. No one who at least went to the lecture should get less than one 1 point on the exam.
The 35 onwards percentiles are covered in composite problems. These problems usually start with explaining some concepts that go a little beyond definitions. The main part is usually an algorithm or explaining the internal workings of some exemplified system. Just mastering that will get them in the 60 – 80 range. To make it easier all individual composite problems are dedicated to particular individual problem areas.
To reward the elite, I usually throw in an “ice-berg” question at the end of the composite problem that one could only answer if they really know the concept well.
Since some of the concepts are less important from my perspective, those lesser important topics will have a lower weighting than the more important topics. The less important topics will also not be covered in-depth.

One important factor to consider is the marking of the exam. Avoid open-ended questions that require the students to make heavy assumptions about a problem. This will result in quite a diversity of answers that no TA really wants to mark. Avoid scattering questions randomly across the problem areas. In my case TAs were assigned to the lab and I dedicated one particular TA to the tutorial. That way you will have TAs marking the exam that had little to no exposure to the materials. You do not want to have each one of them to mark more than one particular problem area.
Another thought is to not include sophisticated coding questions. The time pressure and nature of the exam will cause most of them to make fugitive errors that may quickly deteriorate their scores. Real code you can edit, debug, compile, and massage over time. You cannot do that on paper. I would only ask them about code they have seen before in the book, tutorials, lecture slides, or likely written themselves.

The Exam-Takers View – How the hell do I prepare for that exam?
(funny, but even these guys won’t help you with that)

It is quite funny but that thought crossed my mind in a Karate sparring session today. As it turns out a possible approach to effectively prepare “mentally” for the exam is analogous to generating and maintaining muscle memory of certain techniques and applying them in practice.

Kata – Memorizing and Maintaining the Building Blocks

Kata in martial arts is often seen as the central building block in many martial arts. In Karate (one of the things I do besides Tai Chi and Kendo) it is a sequence of basic moves, each of which has a specific application and is exercised against an imaginary opponent. The point of learning and practicing Kata is to memorize the moves and their application. This is actually quite similar to learning operating system concepts. In the lecture several core concepts, requirements, and algorithms were described that should be “known” for the final exam.
When I was an undergraduate student I managed to pass my Bachelors degree with a perfect score. This was possible with an effective system of learning techniques and knowing how to work the system of electives in a way that I always had the best marks included in the final score. The system I used was coined by a Swiss guy called Gregor Staub. He wrote a book (in German) called “Mega Memory” in which he described the following idea among a many other techniques for specific memorization tasks.

The key principle to this technique is repetition. According to him you need to at least 6 repetitions to reinforce a learned concept. These repetitions need to occur in certain time intervals. The chance to forget a concept that you have just learned by tomorrow is very high if you do not revisit it again within 20 minutes.
His proposal was to distil the concepts of lectures down into small note cards (a.k.a. flash cards). These cards only contain the essential information that you need to reinforce the concept. For example I distilled my 755 slides of the lecture down to 84 (4 7/8" x 3 1/2") cards. Each of those cards carries a concept title on the back and a sequential card number.
Those cards are a very nice way to subdivide information. You can easily dissect concepts from the lecture. Once you have your deck, you need to reinforce the concepts.

Day 1:
To illustrate that approach, assume you take the first 20 cards out of your deck:
  1. Memorize all those cards until you fluently can reproduce the concepts by just looking at the topic headline of the card.
  2. Cards that you know perfectly well put on a separate stack. Let’s call this “know stack”.
  3. Repeat 1 and 2 until you know all cards perfectly well and they are now on the “know stack”.
  4. Now wait 20 minutes.
  5. Do 1-3 over again.
  6. Enough for today

Day 2:
  1. Revisit all cards from yesterday again. This should yield a “know-yesterday-” and a “forgot stack”. Ideally, you should end up somewhere like 17-know and 3-forgot concepts.
  2. Now take 20 more cards from your deck and put them on the “forgot” stack.
  3. Repeat procedure from day 1 with the “forgot” stack.

Day 3-6 and onwards:
Now the same thing happens over again. You revisit each of those days separately and place the “known” concepts on respective “know-day-x” stacks. All forgotten and new concepts get placed on the “forgot” stack. On day six, you should end up with 6 separate stacks that you know quite well. The oldest of those stacks was successfully revisited 6 times and sits in long-term memory. You can safely put that old stack away in a separate box. You do not need to revisit it again until 3 months from now to make it permanent.

Over the years I made some amendments to the original technique. Instead of learning by titles you can use the back sides to formulate specific questions about the cards content. That speeds up the reinforcing process quite significantly. For very big exams, for example my preparation for the IBM-certified Specialist Software Quality exam, I ended up with close to 400 concept cards that contained 3 terms of software quality techniques and quality management. To speed up the reinforcing process, I bespoke MP3s with the these concept card questions and the related answers that I listened to after getting out of bed in the morning and when I got back to bed. This one also helped to speed up the reinforcing process quite significantly.

This technique is a very powerful tool to memorize concepts. It should be said that the information placed on the note-cards is very subjective. Depending on how well you already know a particular subject will dictate how many cards you dedicate to it. That said learning from someone else’s cards is not a good idea. The entire process of distilling the lecture materials down is already a good learning experience. Do not underestimate the overhead of this distillation process. It took me 2 working days to distil 755 slides down to 84 cards… and I’m the guy who taught the course.

This process of memorization will put you into the 60-80-crowd; however, to do really well you need to gear up a bit.

Kumite – Reinforcing by Application

Kumite generally refers to sparring in Karate. In contrast to Kata you train with a real individual to develop a particular skill or practice for competition. In martial arts just knowing the individual moves and Kata will not necessarily make you a good competitor.
So what has this to do with exam preparations? Well now that you know the “Kata” you need to know how to apply it in practice.
Practical problems can be found in the course book and were presented in the tutorials. Create a small booklet or folder of these problem descriptions on the front and their solutions on the back. Solve these problems on a separate sheet of paper and then compare your solution…
  • Every time you have some free time, pick a problem at random and solve it.
  • Every time you are etching to play your favourite MMORPG, pick a problem at random and solve it instead.
  • Every time you feel like goofing off on Facebook or Youtube, pick a problem at random and solve it instead.
  • Every time you feel like talking things over with your friend on the cell, pick a problem at random and solve it instead.
  • First thing in the morning … pick a problem and solve it.
  • Last thing in the evening … pick a problem and solve it.
  • I think you got the idea … pick a problem and solve it!

If you really dedicate some time to this you will master the art of operating systems, which will certainly bring you closer from the 60-80s to the 100. This step will cost a lot of effort but the fruits are rewarding. In martial arts this is also the sweaty part.

If you followed that through there should be no trouble in taking the exam. Some basic exam taking rules are printed on the current revision of the exam itself; don’t worry you will see it soon enough.

References

Saturday, April 2, 2011

The Real Survival Series – Cut Off and Isolated – Part Two

The Real Survival Series – Cut Off and Isolated – Part 2

“Sipping his sake and eating his "Disaster Sushi Set," a local construction planning company president reminds me and my colleague that modern Japanese descend from samurai warriors and kamikaze pilots who were willing, without complaint, to meet their fate.”
(Steve Herman from KoriyamaJapan, March 16, 2011)

(Cover: Horst von Dach - Der Totale Widerstand - Kleinkriegsanleitung fuer Jedermann
"Total resistance - Guerillia Warfare for Everyone")

This is the second sequel of the survival series. I was inspired by requests and catastrophic events in Japan to write a bit about this subject. After talking about essential supplies you should have at home to sustain the unexpected for a little while. The description below assumes that you are several days into a disaster and there is no foreseeable aid coming in. Under these assumptions your emergency supply (see my previous post) will already be close to depletion and you have to organize in a group to sustain. Note it makes no sense at all and it would probably be counterproductive to put resources to the described activities below, if aid is coming in the near future or local authorities already put evacuation plans in place.

After watching the news today the major concern about 5 days after the earthquake and tsunami seems to be to supply remote villages and cut off areas given the very poor condition of public infrastructure. Unfortunately, traditional survival literature that explains you what to buy to go on an Amazon rainforest trip or adventure trip to the Thorngaard Mountains does not really cover what to do in such a situation. Assuming your small village or town is cut off, the local authorities collapsed or were simply not allocated in the first place, you need to figure out what to do.

Since the early 1950s Switzerland did prepare their population for the event that neutrality could be put at risk by a cold war escalation. It was the understanding of many officers, including Hans von Dach, that in the event of a foreign occupation the Swiss forces would be swiftly defeated or dispersed by a much larger force (Americans or Russians at the time) and it is the duty of everyone in that country to resist to the last breath. Most of that scare was motivated by the events of WWII. As he pointed it out: “You should not surrender to communists; and you actually can not surrender to fascists”.
Back from these past days remain several manuals how to organize civil resistance and guerrilla warfare units. His very early books from the 1950s have been translated into English and were allegedly unsuccessfully used by Iraqi insurgents. From my perspective, had they actually used the more modern German publications, these efforts may have been much more successful (but that is just my personal opinion).

Ignoring all the tactical information and the nasty details how warfare in such an environment works, it still contains valuable lessons how you can organize a small group of people that are determined for a common goal. In this case it is primarily the survival of the group and secondary to keep peoples occupied. The anxiety and the shock resulting from a disaster that you see in Japan right now could turn your mind into a daemons workshop; especially if there is uncertainty about when aid will arrive. I will make major adaptations and supplement some of the ideas by Major von Dach, since we have a peaceful application in mind.

Composition and organisation of your group


Depending on who you get stranded or cut off with you may actually end up having a number of very useful talents. Assuming your village/group has about 40-70 people. Anything beyond a hundred people becomes hardly manageable because you will incur major inefficiencies in distributing supplies and keeping track of the current state of the group. An option in an urban setting or for a larger group is the sub organization into different groups. In a more populated such a group could be formed by an established community (your church, your bowling buddies, your local karate club, families that have children in the same class, etc.). And actually that is where things already deviate from a guerrilla warfare scenario.
  1. In a traditional guerrilla warfare setting you would set up staff, core services, mobile several detachments and a strict command chain to ensure readiness and efficiency.
  2. Implicitly part of that deal is that you voluntarily give up basic human rights (i.e. freedom of expression, democratic voting…) for the better cause of your country.
  3. The group will mainly consist of volunteers and not of people who got mixed up by the same fate.
  4. If a natural disaster hits, people will already have many of their own problems and imposing such a structure is rather counterproductive or even impossible.
  5. Most of the people will actually be idle during non-fighting periods and perform simple chores or training. Such activities are not needed or even counterproductive when it comes to preserving supplies in a disaster situation.
  6. The driving factors in guerrilla warfare are agility, deception and cover; when a disaster hits you should be more concerned about sustainability and conserving resources than being agile.
Therefore the setup and (democratic) organization of your group will largely depend on the group itself. You should strive to set up a credible leadership and a set of core services while maintaining the rights and needs of every individual of your group and applicable law.

Leadership

Be careful about establishing leadership. Choose someone (or a group of people) who has a sense of authority, that is respected, that can inspire people. The tasks encompass to organize the group, resolve conflicts, council individuals on their problems and provide technical support. The last point should be empathized. Leverage existing authorities such as remaining police forces and firefighters. Disaster situations are less about big leadership decisions and more about achieving the most with simple practical means, such that core services are provided by and for the group.

The Core Services

Note that not the entire group is needed to provide these services. It is actually rather a minority who acts on behalf of the group. That said these services should be tailored to the specific situation and be populated by experts in your group. Some fundamental services can also be carried out in rotation to assure fairness.

Supplies:
Goal: assure and improve food, water, equipment, and combustibles supply
Examples: Anyone who is willing and physically fit.

Medical:
Goal: provide aid and medical care, care for elderly that need attention
Examples: local medical staff (nurse, doctor, midwive…), people with first-aid experience

Communications:
Goal: Monitor news, establish contact with aid forces
Examples: HAM radio hobbyist, postman, people with working (cell-) phones, CB or GMRS radios, computer geek with working satellite communications link

Engineering:
Goal: Provide and restore very basic infrastructure for the other services to function.
Examples: carpenters, construction worker, electrician, (car-) mechanic, engineer

Equipment

  • Shelter: Depending on the disaster homes may still be in-tact such that available space can be shared. In severe cases, such right now in Japan, it may be useful to organize tents or establish other forms of shelter. If no other form of shelter is usable tents can be ‘required’, be donated from local camping stores or be established from the ruins (more in future posts).
  • Pots, Pans, Cutlery, Food containers may be readily available, and should be shared by individuals if needed.
  • Same applies for blankets, coats, warm undergarments in winter-scenarios that we now for example see in Japan.
  • Any form of radio equipment or media should be made available at a central spot. To conserve energy, battery-operated equipment should be shared by the entire group. For example von Dach suggests having two radios per detachment (80-100 people). One radio that is mains operated for places where power is available and one that is battery operated otherwise.
  • For minor repairs or other needed equipment by the individuals that can be shared see my previous post.

Food supply

In a nutshell you have to live with what you have or what you can organize.
  • You can organize it from local farms, food processing companies, shops and depots.
  • By any means respect applicable law and avoid looting. Conflicts should be avoided by paying for the supplies.
  • In severe cases scavenging foods in durable containers from the ruins may be an option.
  • Hunting and fishing may only marginally improve the food supply and are just stated for completeness.
  • Note since the arrival of aid is uncertain, save food in durable containers and ration available supplies.
  • Do not ‘require’ or take existing supplies food from individuals. This is a quick recipe for your group to dissolve fairly quickly. In extreme cases, individuals will eventually start sharing or other arrangements can be found.

Engineering

Depending on the disaster, shelter as well as public infrastructure may be severely damaged. The composition and tasks will largely vary with the situation that you encounter.
  • The core services, especially the medical one may need electricity. In subsequent articles I will write how you can provide such basic necessities.
  • Severely damaged shelter will need to be temporarily repaired.
  • Basic means of transportation (for example to get medical attention for the elderly or injured) need to be established
  • The infrastructure needs to be cleared to get aid workers in, obtain external supplies and facilitate the evacuation process (e.g., helicopter landing zone).
  • Maintaining equipment that is used by the other services.

Medical

Also this service will largely vary by the situation. In general there are the following tasks:
  • Make them transportable for further care on-site.
  • Locate and provide first aid for injured.
  • Collocate the injured to focus the attention of the medical staff and reduce their overhead. Existing facilities should be used. If not this effort should be supported by the engineering service that provides the basic infrastructure and restores the needed shelter.

Communications

The key objectives of communications are
·       establishing contact with aid forces,
·       reporting on the condition of the group,
·       coordinate supplies in cut off areas (i.e., air drops),
·       Receive and distribute news to inform the group and keep the moral up.

Special topics

Basic Weather Rules

(photo credit)

This is a collection of symptoms by von Dach and my flight school manual that allow crude nice weather predictions. Given that your infrastructure and possibly shelter is destroyed, you will be much more vulnerable to weather changes. Since the description leaves lots of room for interpretation, develop an eye for them over time.
If you search on the web you will find numerous website that elaborate on simple farmer rules and other forms of crude weather predictions. You do not have to be a meteorologist but mastering a few basics is always handy.

Signs for improving weather conditions include:
  • Evening fog,
  • Dispersed piled clouds moving into the wind direction,
  • High-altitude cirrus clouds under which piled clouds move with a faster velocity.
Nice weather signs
  • sunset afterglow,
  • high-flying swallows and croaking frogs,
  • early morning fog that disappears on sunrise,
  • massive dew in the evening and the first-half of the night is a clear sign that there is no rain the next day,
  • a few large piled clouds indicate good and dry weather. Note in warm weather they can also be light indicators for thunderstorms.
Bad weather:
Indicators for bad weather are usually animals. Birds or fish chasing for insects that move lower in anticipation of rain. Mountain goats or -sheep also sense rain quite accurately and move lower. Other indicators according to Nehberg include,
  • red sky in the morning,
  • glowing moon and twinkling stars,
  • absence of morning dew in the summer,
  • clear views (i.e., clear day),
  • mix of different cloud types,
  • sudden wind changes by more than 45 degrees,
  • raising fog from mountains,
  • surprisingly far sound propagation.
Nehberg recommends the use of a barometer in mountain regions. The limited far sight and the formation of mountain chains make even short-term weather predictions difficult.

Supplemental Emergency Food


If your emergency supply is depleted, you have to sustain on what nearby fields and forests can offer. Elaborate hunts or trips into forests for berry collection are counterproductive for your assumed group size. In addition, these supplemental foods are not a sustainable source of food but may bridge severe shortages until aid arrives. Moreover in urban areas your choices may be even more confined to scavenging. The recipes below are a collection of Major von Dach.

Basic sources
Vegetables, fruits, potatoes, berries, mushrooms, herbs, deer, birds, fish, frogs, snails, etc…

Soups
Most of the above sources can be prepared as soup. Preferably use cereals. Squish the corn, add water, and, if possible salt and cook it.

Potatoes
Roast in open fire or cook in water.

Substitute bread
Cereals that aren’t ripe yet can be used to create a substitute for bread. Squish and grind the corn, mix it with water to form dough. Add salt when possible. Put it flat on a steel plate or put it around a branch and bake it over the open fire.

Substitute coffee
Use ripe barley corn or alternatively acorns. Roast them on a steel plate over open fire until they are dark brown to black. Grind them to powder and infuse them in hot water.

Herbs to be used as supplemental spices
Von Dach has an elaborate collection on herbs that could be used to replace traditional spices. However that list is confined to the central-European vegetation and might be of little use elsewhere.

Various interesting hints:
  • The soft inside of tree-bark can be eaten raw. Cut off the soft skin that directly surrounds the hard wood. It can be eaten raw or cooked as soup.
  • The inside bark of willow-, birch-, pine- trees can be dried, ground to powder and used as flour.
  • You can eat sweet corn even if it is not ripe yet. The best way to do so is to roast it on the open fire.
  • Various kinds of nuts can also be eaten if they are not ripe yet.
  • Fruits that are not ripe yet can be cut in small pieces, cooked soft and eaten. Drink the cooking water warm as juice replacement.
Preparing Meat:
Soak it in cold water then the water can later be used as strong soup. Same applies to bones.

Fish:
Cut the fish open starting from the tail to the front. Peel the guts out with a finger. To prepare:
  • Roast: Keep the head, eyes etc on. Add some salt and fry it on open fire.
  • Cook: Take the eyes out, put in water and let it sit for some time.

Basic Field Well


In case water supply becomes a problem, there is no freshwater nearby to purify, consider building a small field well. For areas like deserts or below-freezing point temperatures this is not an option. I’ll write about these scenarios on future.
For this well:
  • Dig a trench to reach a bit beneath the ground water level
  • Take a barrel and remove the bottom
  • Put about 30 cm of gravel/large stones and sand as filter layer into the bottom of the well.

The water should be purified as follows:
  • Filter the water through a clean cloth
  • Boil the filtered water for at least 1 minute
  • Always use clean containers. When cleaning containers for storage also clean the caps and the thread.

“Kosovo” Generator


This story is based on a circulating rumour in the battle engineering company that I did my service in more than a decade ago. According to that story, a local car mechanic and machinist went off and built this generator from scrap car and bike parts to supply electricity to surgeons in the local hospital during the Kosovo war in 1999. They successfully deployed that generator in the river of the town while being under constant threat to get shot by enemy forces.

In a nutshell they joined two bike frames together in a rather simplistic wood construction. The tires from the back wheels were removed.
They cut off either side of the inside wheel hangers of the two frames and connected the outer wheels with the gears facing outwards to the frame. Panels of wood were fasted into the spikes of both rims to build something that is like a waterwheel of a mill. Note that the width (i.e. the spacing between the two bike wheels) determines the torque that the mill can generate. The alternator can be driven by a belt and the alternator and the needed battery can be enclosed in a simple wood construction. A schematic is shown in the following picture.

Above the waterwheel, where usually the rack of the bike sits they fastened a panel with an automotive alternator and a car battery sitting on top. A belt was used to connect one side of the rim to the alternator and to generate power.

Note that alternators require a relatively high RPM that is unlikely to be achieved by the ratio of the rim to the alternator. You can account for that by adding resistors in the circuit. If it is properly hooked up, the generator should output around 13.8V to 14V which is enough to charge the connected battery. Note that the design of the alternator mandates that a battery needs to be connected for it to work. Alternators compared to traditional generators do not have magnets, such that the magnetic field needed for the power generation is initially supplied by the connected battery. Hobbyists picked up that idea as well and the circuit is well described here.

Summary & References

These were some thoughts on how you could organize a small to medium-sized group to survive hardening circumstances, when you are cut off from any outside aid. Note that these lessons here are not useful or even counterproductive if aid is on the way. Look at the previous series of my blog posts how to survive short periods of privations.
In future posts I’ll probably blog a bit more on selected topics of survival.

References: