Technical Informations
Technische Informationen

1.) Motorola S records english deutsch
2.) Pictures / Bilder english deutsch
3.) Fonts / Schriften english deutsch
4.) Power Consumption
     Stromverbrauch
english deutsch

1.) Motorola S records (english)

Motorola developed a file structure for transferring this file into micro computers systems. Thus also the Rex6000 firmware file REX.BIN is subject to this structure.
Those files are divided into so-called S records which always begin with the letter "S". The s record structure looks like this:
1.) "S"
2.) a number to determinate the kind of the S record
3.) a counter which gives the lenght of the S record
4.) the address where the data shall be stored
5.) the data
6.) the checksum
Usually these data is stored in ASCII code. Though in REX.BIN they are stored as normal hex bytes. That's why the informations you can find in the internet how to build the checksum are more confusing than useful because they are valid for normal S records. This is the reason why I describe the way how to calculate a checksum for REX.BIN. Because if you change the REX.BIN file, you must also suit the checksums, otherwise the update of the firmware will not work.
In REX.BIN there are only S0, S1, S2 und S9 records. I describe a S2 record:

Hex Dec Description
53 83 "S"
32 50 "2"
14 20 Counter: 20 - 3 bytes for address - 1 byte for the checksum = 16 bytes for data
04 4 S2 records always have 3 address bytes
60 96
A0 160
F4 244 16 data bytes
DD 221
66 102
F5 245
DD 221
4E 78
F6 246
DD 221
46 70
F7 247
09 9
01 1
00 0
00 0
DD 221
75 117
24 36 checksum

Hex Dec How to calculate the checksum:
09DB 2523 Sum of all 20 bytes (counter, address, data)
DB 219 Keep only the 2 least significant digits
(Hex: 09DB AND 00FF = DB, Dec: 2523 MOD 256 = 219)
24 36 The checksum is the defference to 255
(Hex: FF - DB = 24, Dec: 255 - 219 = 36)

more informations - thanks to Myles Rix for this link.



1.) Motorola S records (deutsch)

Motorola entwickelte eine Dateistruktur, mit deren Hilfe der Inhalt dieser Datei in Microcomputersysteme übertragen werden kann. So unterliegt auch die Firmware-Datei REX.BIN für den Rex6000 dieser Struktur.
Solche Dateien sind in sogenannte "records" unterteilt, die immer mit dem Buchstaben "S" beginnen. Die Struktur eines S records sieht so aus:
1.) "S"
2.) eine Ziffer, die die Art des S records angibt
3.) ein Zähler, der die Länge des S records angibt
4.) die Adresse, für die die Daten bestimmt sind
5.) die Daten
6.) die Prüfsumme
Normalerweise liegen diese Daten im ASCII code vor. Bei REX.BIN allerdings liegen sie in normalen Hex-Bytes vor. Deshalb sind die Informationen, die man im Internet über die Bildung der Prüfsumme findet, eher verwirrend als nützlich, weil sie für normale S records gelten. Aus diesem Grunde beschreibe ich hier, wie man eine Prüfsumme für REX.BIN bildet. Denn wenn man die Datei REX.BIN verändert, muss man auch die betreffenden Prüfsummen anpassen, sonst funktioniert das Firmware-Update nicht.
In REX.BIN kommen nur S0, S1, S2 und S9 records vor. Ich beschreibe einen S2 record:

Hex Dec Beschreibung
53 83 "S"
32 50 "2"
14 20 Zähler: 20 - 3 Bytes für Adressen - 1 Byte für Prüfsumme = 16 Bytes für Daten
04 4 S2 records haben immer 3 Bytes für die Adresse
60 96
A0 160
F4 244 16 Daten-Bytes
DD 221
66 102
F5 245
DD 221
4E 78
F6 246
DD 221
46 70
F7 247
09 9
01 1
00 0
00 0
DD 221
75 117
24 36 Prüfsumme

Hex Dec Berechnung der Prüfsumme:
09DB 2523 Summe aller 20 Bytes (Zähler, Adresse, Daten)
DB 219 Nur die zwei letzen Stellen der Hex-Zahl behalten
(Hex: 09DB AND 00FF = DB, Dec: 2523 MOD 256 = 219)
24 36 Die Prüfsumme ist die Differenz zu 255
(Hex: FF - DB = 24, Dec: 255 - 219 = 36)

Weitere Informationen - ich danke Myles Rix für diesen Link.




2.) Pictures (english)

Pictures are stored in the way that each bit of a byte corresponds to a dot. 1 means black, 0 means white. The first two bytes determine width and height of the picture. Let's take for example the picture of the lower case keyboard. It starts from address 030000. There are the bytes F0 58. That means the picture is 240 dots wide and 88 dots high. To draw the picture, we must read out 240 * 88 / = 2640 bytes. The eight bits of each byte draw eight dots which lay side by side. All dots are drawn line by line from the right top to the left bottom.

Thanks to Chris Harris' RexMap which shows many important memory addresses.



2.) Bilder (deutsch)

Bilder sind so abgespeichert, dass jedes Bit eines Bytes einem Punkt entspricht. 1 bedeutet schwarz, 0 bedeutet weiß. Die ersten beiden Bytes geben Breite und Höhe in Punkten an. Nehmen wir zum Beispiel das Bild, das die Tastatur mit Kleinbuchstaben darstellt. Es beginnt an der Adresse 030000. Dort liegen die Bytes F0 58. Das Bild ist also 240 Punkte breit und 88 Punkte hoch. Um das Bild darzustellen, müssen wir 240 * 88 / 8 = 2640 Bytes auslesen. Die acht Bits aus jedem Byte bilden acht nebeneinander liegende Punkte. Alle Punkte werden zeilenweise von links oben bis rechts unten geschrieben.

Danke für Chris Harris' RexMap, die viele wichtige Speicheradressen zeigt.




3.) Fonts (english)

Rex6000 knows three fonts: normal, bold, and tiny. The font tables begin in the file REX.BIN in the addresses 0F0000, 0F2000, and 0F4000. Each font contains the complete Windows-compatible set of the characters 32 - 255. The table of each character begins with two bytes wich give the size of the character. The first byte shows the width of the character. But this has nothing to do with the width of the dot pattern table, this width is always 16. The second byte shows the height of the character. The normal and the bold characters are 11 dots high, there are 2 + 11 * 16 / 8 = 24 bytes stored. The tiny characters are 9 dots high, there are 2 + 9 * 16 / 8 = 20 bytes stored. To draw for example a bold "A" (ASCII 65), we have to add 65 * 24 = 1560 to the start address and get 0F2618. There are the bytes 07 0B, that means the "A" is 7 dots wide and 11 dots high. The 16 bits of the following 2 bytes draw the 16 dots of the upmost line and so on.

Thanks to Chris Harris' RexMap which shows many important memory addresses.



3.) Schriften (deutsch)

Der Rex6000 kennt drei Schriftarten: normal, fett und klein. Die Tabellen mit den Schriften liegen in der Datei REX.BIN an den Adressen 0F0000, 0F2000 und 0F4000. Jede Schriftart enthält den kompletten Windows-kompatiblen Satz der Zeichen 32 - 255. Die Tabelle für jedes Zeichen beginnt mit zwei Bytes, die die Größe des Zeichens angeben. Das erste Byte gibt die Breite des Zeichens an. Dies hat aber nichts mit der Breite der Punktmuster-Tabelle zu tun, diese beträgt immer 16 Punkte. Das zweite Byte gibt die Höhe des Zeichens an und gleichzeitig die Länge der Punktmuster-Tabelle. Die normalen und die fetten Zeichen sind 11 Punkte hoch, es sind 2 + 11 * 16 / 8 = 24 Bytes pro Zeichen gespeichert. Die kleinen Zeichen sind 9 Punkte hoch, es sind 2 + 9 * 16 / 8 = 20 Bytes pro Zeichen gespeichert. Um zum Beispiel ein fettes "A" (ASCII 65) darzustellen, müssen wir zur Startadresse 65 * 24 = 1560 hinzuaddieren und erhalten 0F2618. Dort stehen die Bytes 07 0B, das "A" ist also 7 Punkte breit und 11 Punkte hoch. Die 16 Bits der folgenden 2 Bytes zeichnen die 16 Punkte der obersten Zeile usw.

Danke für Chris Harris' RexMap, die viele wichtige Speicheradressen zeigt.




4.) Power Consumption / Stromverbrauch

(english)

I measured these values by inserting an 1 Ohm resistor into the power circuit and measure it's voltage drop with an oscilloscope.

When the Rex6000 "sleeps", I could not detect any current.
When the Rex6000 waits for user input, the current looks like in the picture. There is a 3 mA level with 5 mA peaks. The duration of the peaks is about 1.5 ms, the duration of a cycle is about 8 ms. Each second there is a short pulse with 7 mA.
When the Rex6000 is working, the power consumption is about 7 mA. It does not matter what the Rex6000 is doing: drawing the world clock, getting key taps from the soft keyboard, switching from one calendar day to another and searching for dates - all jobs need the same power.
Writing the content of a memo into the flash memory, the power consumption rises up to 10 mA.
If the Rex6000 is inserted in the serial cradle, it is powered by the cradle batteries, so all jobs don't drain power from the coin batteries.

(deutsch)

Ich maß diese Werte, indem ich einen 1 Ohm-Widerstand in den Stromkreis einfügte und seinen Spannungsabfall maß.

Wenn der Rex6000 "schläft", konnte ich keinen Stromfluss feststellen.
Wenn der Rex6000 auf Benutzer-Eingaben wartet, sieht der Strom aus wie auf dem Bild. Es gibt einen 3 mA Level mit 5 mA Spitzen. Die Spitzen dauern etwa 1.5 ms, der gesamte Zyklus dauert etwa 8 ms. Jede Sekunde gibt es einen kurzen Puls mit 7 mA.
Wenn der Rex6000 arbeitet, beträgt der Stromverbrauch etwa 7 mA. Es ist gleichgültig, was der Rex6000 tut: ob er die Weltzeituhr zeichnet, Eingaben vom Soft-Keyboard bekommt, von einem Kalendertag zum anderen schaltet und Daten sucht - alle Jobs brauchen den selben Strom.
Wenn der Inhalt eines Memos in den Flash Speicher geschrieben wird, steigt der Stromverbrauch auf 10 mA.
Wenn der Rex6000 in den seriellen Einschub gesteckt wird, wird er von dessen Batterien versorgt, also verbrauchen alle Arbeiten keinen Strom von den Münzen-Batterien.