Kahvibreak Nokia S40 Game Dumping

From Flashpoint Database
Revision as of 11:52, 5 April 2020 by Nokia64 (talk | contribs) (I had "a" issue)
Jump to: navigation, search

This guide is for Nokia S40 phones. If you have a Symbian or a Nokia 3410 / 6310i phone, please read their respective guides by going back to the main Nokia section.

This page will guide you through the process of copying a file from your Nokia S40 mobile phone to your computer, using the Gammu software utility under a Linux-based or Windows operating system. For Linux users, a basic knowledge of their environment is expected. This procedure can be used to backup media files from the phone's internal memory and digitally purchased games.

Notice. Help needed! : Some Nokia models make use of a "Forward-Lock" feature that encrypts the game JAR files when downloaded and stored to the phone's internal memory. This renders the game files unuseable without knowing the phone's keys.

1. Getting the software


If your distribution offers it, search and install the gammu package from your package manager. Otherwise or if prefered, head over to Gammu's download page to get the sources and follow the instructions on building and installing.


Download Gammu from Gammu's download page , look for Windows executables under the "Windows Binaries" section. There's three releases available. You will likely want the *-Windows-64bit.exe or *-Windows.exe version, according to your system specs. During the installation, you will be prompted whether to add Gammu's files to the system PATH. It's not necessary to do so, but it will make things easier.

Tip: If you don't want to install the software, you can use 7-zip to extract the installer contents. Gammu will run fine from the extracted folder.

You might need to install "Visual C++ Redistributable Packages" to run Gammu in case they are not already on your system. You can find it here

2. Connecting your phone to the Computer

Depending on your phone model/capabilities, this process will vary. Bluetooth is by far the most convenient and compatible way, if both your phone and your computer have such capability. Some phones work over Bluetooth but do not do so over data cable, or vice-versa.

Bluetooth (Recommended, if available on your phone/computer)

Make sure your phone haves Bluetooth enabled and phone visibility is set to discoverable mode. On most phones Bluetooth settings are at Menu > Settings > Connectivity > Bluetooth


Pair your phone to the bluetooth adaptor of your computer. Use your favourite method for doing so.
For convenience, here's an how-to using bluetoothctl:
  1. Make sure Bluetooth works in your system and the bluetoothctl utility is installed.
  2. Depending on your user permissions, you might have to run bluetoothctl as root.
  3. On a terminal run bluetoothctl ( sudo bluetoothctl to do so as root). you should be greeted with a [bluetooth]# prompt.
  4. Run the list command. You should get something like this:
    Controller XX:XX:XX:XX:XX:XX BlueZ X.XX [default]. If not, make sure you have the required permissions.
  5. Make sure the controller is powered and pairable, to do so run power on, pairable on and agent on (The agent is the pairing passkey negotiator).
  6. Start scanning for devices, run scan on. Eventually, new found devices will be echoed to the command line.
    You can display all found (and paired) devices with the devices command. You should see your phone appear on the list.
  7. Pair with your phone. Given your phone is Device XX:XX:XX:XX:XX:XX (Friendly Bluetooth name of your device), run pair XX:XX:XX:XX:XX:XX. This XX:XX:XX:XX:XX:XX string is the Bluetooth MAC address of your phone, you will need it later.
    Depending on your device, you will either have to:
    1. Confirm a passkey. Type yes when prompted Confirm passkey XXXXXX (yes/no)
    2. Type a passkey. You will be prompted for a passkey on both devices. Enter any same passkey in both devices.
  8. Now you can set agent off and pairable off again.

You might be prompted by your phone whether to let the computer connect automatically. It's recommended to select yes for convenience, but not needed.


ToDo: Document procedure, both with Windows bluetooth stack and Toshiba's bluetooth stack.

You will need the Bluetooth MAC adress of your phone. It usually looks like a XX:XX:XX:XX:XX:XX string composed of hexadecimal numbers (0-9 and A-F characters). Sometimes it's shown without the : between them.
On some phones you can check it out by dialing the code *#2820# (It's the 12 hex characters shown at the first line)

Data cable

Nokia phones may have many different connector types:

  • USB:
Use a standard USB cable to perform the connection.
  • Pop-Port:
Nokia phones with Pop-Port connector may have different technologies regarding data cable connection, despite the Pop-Port connector being the same:
  • Serial: on older phones. You will need either a Nokia CA-42, Nokia DKU-5 or aftermarket compatible cable. Such cables have a chip to do serial emulation over USB (Help Needed: CA-42 Might be internally performing differently, but should work)
  • USB: on newer phones. You will need either a Nokia CA-53, Nokia CA-70, Nokia DKU-2 or aftermarket compatible cable. Such cables do direct connection between the computer and the phone, which does USB directly.
    You may check here [NokiaCableArchivedPages] whether your phone needs a serial or direct USB type cable. Also, you can tell some USB capable phones by checking whether they have a "USB data Cable" option on Settings > Connectivity.
  • Other connectors:
Some other phones have very specific connectors. Most of them are direct USB, so the procedure should not vary.


Connect your cable to the phone then to the computer.
If your phone does USB it may prompt you with a mode selection choice. Choose "Default Mode" / "Nokia PC Suite mode". If you are not, make sure the "USB data cable" setting at Settings > Connectivity is set to "Default Mode" / "PC Suite", if any.

Check the output of the dmesg command (Might require superuser permissions). Depending on your device, something like this should appear:

  • (Nokia 6151, does direct USB)
[10674.228192] usb 3-1.2: Product: Nokia 6151
[10674.228200] usb 3-1.2: Manufacturer: Nokia
[10674.389704] cdc_acm 3-1.2:1.1: ttyACM0: USB ACM device
  • (Aftermarket USB-Serial data cable, with _Prolific_ PL2303 chip)
[ 2953.638050] usbserial: USB Serial support registered for pl2303
[ 2953.638097] pl2303 3-1.2:1.0: pl2303 converter detected
[ 2953.639975] usb 3-1.2: pl2303 converter now attached to ttyUSB0

In the above cases, /dev/ttyACM0 and /dev/ttyUSB0 are the device nodes assigned to the phone's data interface.
You will likely want to make it readable/writable by your user. Do chmod 777 [device node] (as superuser) to make the device node readable/writable by everyone (non-permanently).


ToDo: document procedure


It is also possible to connect to IrDA (Infrared) capable phones via an IrDA interface. Not recommended since some phones have a mysterious firmware bug causing them to brick over time when using Gammu to interface them over IrDA.

3. Configuring Gammu

Gammu uses text files to store it's configuration parameters.
At their simplest form, they have the following syntax:

device = [Device Node/Bluetooth Address/COM Port]
name = [Phone's friendly name, can be anything user-set]
connection = [Connection mode]

Create a empty text file and type/paste the following template:

device = 
name = 
connection = 
  • device:
If connecting over Bluetooth, set it to the XX:XX:XX:XX:XX:XX Bluetooth address of the phone. If connecting via data cable, under Linux set it to the phone's interface device node, under Windows set it to the phone's COM port, as comX:
  • name:
An identifier for the phone, can be anything user-set
  • connection:
This is the protocol variant Gammu will use to communicate with the phone. The most common values are fbus for Serial-over-USB phones, bluephonet for connections over Bluetooth and fbusdku5 or dku2 for direct USB connections. Please refer to this documentation snippet from Gammu [gammusnippet] for more information.

Save the text file to a known location, and copy it's path. Filename does not matters. (On Windows, hold Shift and right click on the file then select "Copy as Path")


  • (Nokia 3100 at COM8, Windows)
device = com8:
name = Nokia 3100
connection = fbus
  • (Nokia 7210 at /dev/ttyUSB0, Linux)
device = /dev/ttyUSB0
name = Nokia 7210
connection = fbus
  • (Nokia 7230 over Bluetooth)
device = 9C:4A:00:00:00:00
name = Nokia 7230
connection = bluephonet

4. Using Gammu

Gammu is interfaced via the command line, with a simple set of commands.
Gammu command syntax looks like the following:
gammu [parameters] [command] [command options]

1. Launching Gammu from the command line.

  • Linux:
Use your favourite way of running a shell.
  • Windows:
  • If you used the installer and added Gammu to the system path, press Windows Key + R, then type in cmd and press Enter.
  • If you extracted the files using 7Zip or did not add Gammu to the system path, browse to the directory where Gammu files are and do Shift + Right Click on the bin folder, then choose "open command window here"
On all cases, if done right, typing gammu and pressing Enter should greet you with the program's built-in help message.

2. Specifying the config file.

We should tell Gammu where our configuration file is. To do so, we will specify it as a command-line argument.
First of all, append a -c argument after the gammu command on the command line. This tells Gammu that the following argument will be the path to the configuration file. So now, paste the path after it, enclosed in " . On Windows, keep in mind that Ctrl+V won't work, do Right Click > Paste. Use your favourite way on Linux, many graphical terminal emulators let you paste by doing Ctrl+Shift+V.
For example, if the config file path is C:\Example\gammu config.txt the command will look like this:</br> gammu -c "C:\Example\gammu config.txt"

Tip: On Windows command line and most shells you can quickly recall past commands with the Up and Down keys.

3. Testing the connection.

Now, let's check whether the connection is working and properly configured. Gammu's identify command will print basic information about your phone, and it's a quick way of testing whether the connection works. Append identify to the command line arguments:
gammu -c "C:\Example\gammu config.txt" identify
Once run, something like this should appear:
Device               : /dev/ttyUSB0
Manufacturer         : Nokia
Model                : 3100 (RH-19)
Firmware             : 05.91 C (22-10-04)
Note: If you get a "No response from device in specified time" error, make sure the connection type (Step 3) is properly set. Sometimes it's a matter of trial and error.