Hardware Infos: Guenter Damm

ACHTUNG alles lesen und Stecker bei Aktionen in der Box ziehen Jeder der eine der beschriebenen Verfahren durchführt handelt auf eigene Gefahr, wir übernehmen keine Haftung für eventuelle Schäden an Ihrem Equipment!

Mediamaster
® ist ein eingetragene Warenzeichen von Nokia
d-box
®  ist ein eingetragenes Warenzeichen von betaresearch

ENGLISH TRANSLATION

07.12.97

Hallo !

fuer alle die sich naeher dafuer interessieren, wie die Hardware der Mediamaster und DBoxen organisiert ist, will ich hier einmal kurz einen Lageplan zur Box schreiben:

Der 68340 Prozessor, der in jeder Box arbeitet, ist in der Lage ohne weitere Hardware die Selectsignale fuer seine Peripheriebausteine zu generieren.

Dazu benutzt er verschiedene interne Register, die so programmiert werden koennen, das Rom und Ram und andere Bausteine, an fast beliebigen Adressen angesprochen werden koennen. Zum Beispiel wird die Lage der Flash- und RAM-Bereiche, bis die jeweilige Software der Box sich zum Beispiel mit einem Sendername wie NBC im Display meldet, bis zu drei Mal umgelegt.

Die benutzten Adressbereiche von aktiv laufenden Boxen sehen so aus:

Flash-Memory: 0x000000 bis 0x1fffff
RAM: 0x800000 bis 0xbfffff
Demux: 0x700000 bis 0x7001ff
I/O: 0x780000 bis 0x7807ff

bei Standard-Boxen, mit 1 MB Flash und 1MB RAM wird fuer das Flash:

0x000000 bis 0x0fffff und fuer das RAM:
0x900000 bis 0x9fffff benutzt.

Der Bootloader Teil I liegt im Bereich: 0x000000 bis 0x003fff und Teil II bei 0x010000 bis 0x01ffff. Die Sender und Antennenparameter werden im Bereich 0x004000 bis 0x00ffff abgelegt (Nokia und Telepiu- BD benutzen den Bereich aber unterschiedlich !!!).

Der Prozessorstack und seine Exeption Vektoren liegen im RAM-Bereich ab 0x950000. Der Prozessor arbeitet in der Box immer im Supervisormode.


Wenn man sich naeher fuer diese Dinge interessiert, kann man mit dem Programm 'bd32.exe' Flash- und RAM-Inhalte ansehen. Wer sich mit 68k Assembler auskennt, kann natuerlich auch Bereiche der Box Software disassemblieren.

Hat man die Box mit dem BDM-Modul verbunden und 'bd32.exe' gestartet, kann man mal probeweise einen Sender an der Box waehlen. Ich habe hier 'premiere zwei' gewaehlt. Gibt man nun am 'bd32' Prompt folgendes ein:

BD32->md $700000 $FF

dann sieht man eine Auflistung die in Etwa so aussieht:

00700000 E014 E011 41FF 4200 1FFF 1FFF E012 1FFF `.`.A.B.....`...
00700010 1FFF 1FFF 1FFF 1FFF 1FFF 1FFF 1FFF 1FFF ................
00700020 088C 3894 388B 388B 088B 088B 389C 088B ..8.8.8.....8...
00700030 088B 088B 088B 088B 088B 088B 088B 088B ................
00700040 0893 089B 088B 088B 088B 088B 08A3 088B .............#..
00700050 088B 088B 088B 088B 088B 088B 088B 088B ................
00700060 2400 04FF 0244 6727 0000 900D 0200 BF48 $....Dg'......?H
00700070 0044 001C 0000 0000 0000 0000 0000 005D .D.............]
00700080 005D 9000 9000 9000 9000 005D 9000 9000 .].........]....
00700090 9000 9000 9000 9000 9000 9000 9000 FFFF ................
007000A0 FFFF 0000 0000 0000 0000 0000 0000 0000 ................
007000B0 0000 0000 00E4 0000 0000 0030 0000 0000 .....d.....0....
007000C0 0003 0000 6D68 835B 0000 0000 6D68 724A ....mh.[....mhrJ
007000D0 7777 0000 6D68 6A0B 00DA D106 B674 00DA ww..mhj..ZQ.6t.Z
007000E0 D10B EA67 0AA8 0000 0014 006E 002F 0000 Q.jg.(.....n./..
007000F0 0000 030A 005E 00BC 00BC 00BC 00BC 005E .....^.<.<.<.<.^

interessant ist dabei der Anfangsteil. Ab Adresse 700000 hex sieht man hier die Werte aller Pid's, beginnend mit Pid 0. In meinem Beispiel sieht man, dass Premiere zwei als Pid Nr. 2 (Videopid) 41FF und als Audiopid 4200 (Pid Nr. 3) benutzt. PCR Pid (Pid Nr. 4) ist hier 1FFF (unbenutzt).

Es gibt insgesamt 16 Pid's, diese liegen im Bereich: 0x700000 bis 0x7001f.

Im I/O-Bereich: 0x780000 bis 0x7807ff habe ich bisher nur herausgefunden, das ein Lesen bestimmter Adressen, dazu fuehrt, dass der 12 Volt Ausgang aktiviert wird, oder das man die Box in Standby schalten kann.

Bitte alle beigefuegten Files in das Verzeichnis legen, wo auch bd32.exe steht !!!

Ich habe hier zum Beispiel zwei Macro-Files beigelegt, die man innerhalb von bd32 mit z.B. 'do init' und 'do setsim' ausfueheren kann:

'init' vereinbart einige Symbole und zeigt einen Bereich auf, der bei allen mir bekannten Boxen ungefaehrdet fuer eigene Versuche benutzt werden kann.

'setsim' hat man nach dem Start von bd32.exe das Kommando 'restart' ausgefuehrt, sind die Adressbereiche in der Box noch nicht so eingerichtet, wie dies bei normal laufender Software der Fall ist. Dies Macrofile stellt alles so ein.


Wer sich bereits geaergert hat, das man keinen Binaerdump beliebiger Bereiche der Box machen kann, fuer den habe ich die Files 'dump.d32' und 'dump.msg' mitgeliefert. Das ist ein bd32 Treiber, der innerhalb des Box RAM laueft:

Vorgehen: bd32 ist gestartet, box laueft bereits, dann am bd32 Prompt 'do init' ausfuehren, dann z.B. 'dump test.bin $4000 $ffff' (ohne do davor !!!). Es werden ein paar Punkte auf dem Schirm gezeigt und wenn der Prompt von bd32 erscheint, steht im bd32 Verzeichnis, ein Binaefile 'test.bin', das den Sender- und Parameter Bereich der Box enthaelt...

Da es bei den meisten Aktionen, die Inhalte der Box in ein File schreiben sollen, besser ist, wenn die Box gerade keine Bereiche aktuallisiert, waehrend man in das File schreibt, ist es besser so vorzugehen: bd32 starten, am Prompt 'restart' eingeben, nun 'do init' und 'do setsim', danach nach belieben mit dump etwas ausgeben...

Wie gesagt, diese Beschreibungen sind nur fuer Interessierte gedacht, die tiefer in die Geheimnisse der Box vordringen wollen. Wer dazu Fragen hat oder wissen will wie man Treiber schreibt, die die bd32 Befehle ergaenzen, kann sich bei mir melden...


Ohne 68k Assembler Kentnisse, wird man ausser z.B. Anschauen von Adressbereichen in der Box allerdings nicht viel machen koennen.

Für Fragen und weitere KOSTENLOSE Infos stehe ich gerne zur Verfügung,eine eMail reicht.
Hardware-Infos: Guenter Damm

ATTENTION You should always unplug power before you do anything inside your Box.  We cannot give any warranty if the info shown here - is correct! Anyone does this all on his own risk!

Mediamaster®
is registered trademark of Nokia
d-box
®  is registered trademark of betaresearch

For all those who would like to know more about how the hardware of the mediamaster is organised, I'll write here a situation plan of the box:
The 68340 processor inside of every box can generate the select signals for his periphery elements without further hardware.
It uses different internal registers which can be programmed in a way that ROM and RAM and other elements can be reached at nearly any address. For example, the location of the flash and RAM ranges is shifted up to three times until the software of the box indicates for instance NBC in the display.

The address ranges used by running boxes look as follows:

Flash memory 0x000000 to 0x1fffff
RAM 0x800000 to 0xbfffff
Demux 0x700000 to 0x7001ff
I/O 0x780000 to 0x7807ff

For the standard box, with 1 MB flash and 1MB RAM
is used for the flash: 0x000000 to 0x0fffff
and for the RAM: 0x900000 to 0x9fffff

The bootloader part I is in the range 0x000000 to 0x003fff and part II from 0x010000 to 0x01ffff. The channel and antenna parameters are stored from 0x004000 to 0x00ffff (however, Nokia and Telepiu-BD use this range in a different way!!!).

The processorstack and its exemption vectors are in the RAM range from 0x950000. The processor in the box always works in the supervisor mode.

If you're interested, you can take a look at the flash and RAM contents with the help of the programme bd32.exe. Who has knowledge of the 68k assembler can also disassemble parts of the box software.
If you have connected the box with the BDM module and started bd32.exe, you can try and select a channel of the box. I took "Premiere zwei". If you enter at the bd32 prompt:

BD32->md$700000$FF

you will see about the following list:

00700000 E014 E011 41FF 4200 1FFF 1FFF E012 1FFF `.`.A.B.....`...
00700010 1FFF 1FFF 1FFF 1FFF 1FFF 1FFF 1FFF 1FFF ................
00700020 088C 3894 388B 388B 088B 088B 389C 088B ..8.8.8.....8...
00700030 088B 088B 088B 088B 088B 088B 088B 088B ................
00700040 0893 089B 088B 088B 088B 088B 08A3 088B .............#..
00700050 088B 088B 088B 088B 088B 088B 088B 088B ................
00700060 2400 04FF 0244 6727 0000 900D 0200 BF48 $....Dg'......?H
00700070 0044 001C 0000 0000 0000 0000 0000 005D .D.............]
00700080 005D 9000 9000 9000 9000 005D 9000 9000 .].........]....
00700090 9000 9000 9000 9000 9000 9000 9000 FFFF ................
007000A0 FFFF 0000 0000 0000 0000 0000 0000 0000 ................
007000B0 0000 0000 00E4 0000 0000 0030 0000 0000 .....d.....0....
007000C0 0003 0000 6D68 835B 0000 0000 6D68 724A ....mh.[....mhrJ
007000D0 7777 0000 6D68 6A0B 00DA D106 B674 00DA ww..mhj..ZQ.6t.Z
007000E0 D10B EA67 0AA8 0000 0014 006E 002F 0000 Q.jg.(.....n./..
007000F0 0000 030A 005E 00BC 00BC 00BC 00BC 005E .....^.<.<.<.<.^

The first part is interesting. From address 700000 hex you can see the value of all the pids, starting with pid 0. In my example you see that "Premiere zwei" uses 41FF as pid no. 2 (videopid) and as audiopid 4200 (pid no. 3). PCR pid (pid no. 4) is here 1FFF (unused).
There are 16 pids totally, from 0x700000 to 0x7001f.
Within the range I/O: 0x780000 to 0x7807ff I could only find out that the reading of certain addresses activates the 12 V output, or the box can be switched to standby.

Put all the additional files in the index where you find bd32.exe !!!
I added for instance two macro files which can be executed within bd32 with for example "do init" and "do setsim":

"init" comprises some symbols and shows the range where you can make experiments without risks in all the boxes I know.

"setsim": If you gave the command "restart" after the start of bd32.exe, the address range in the box isn't set up as it would be in a normal running software. That's all done by this macro file.

For those who feel annoyed because a binary dump of any range of the box is not possible, I've provided the files "dump.d32" and "dump.msg". This is a bd32 driver running in the box RAM:

Procedure: bd32 is started and the box running. Now "do init" at the bd32 prompt. Then, e.g. "dump test.bin $4000 $ffff" (without "do" at the beginning!!!). You will see some dots on the screen and when the prompt of bd32 appears, you will find a binary file "test.bin" containing the channel- and parameter range of the box.

Most of the times, if contents of the box must be written in a file, the box shouldn't actualise something at the same time. Therefore follow this procedure:
start bd 32, give "restart" at the prompt, then "do init" and "do setsim". After that, you can give out something with dump ...

As I said, these descriptions are only for those who want to know more secrets of the box. If you have questions or if you would like to know how to write drivers which complete the bd32 commands, just let me know.

However, without 68k assembler knowledge you can't do much more than look at the address range of the box.