GDINFO

If you have any questions on programming, this is the place to ask them, whether you're a newbie or an experienced programmer. Discussion on programming in general is also welcome. We will help you with programming homework, but we will not do your work for you! Any porting requests must be made in Developmental Ideas.
Post Reply
User avatar
Quzar
Dream Coder
Dream Coder
Posts: 7489
Joined: Wed Jul 31, 2002 12:14 am
Location: Miami, FL
Has liked: 0
Been liked: 3 times
Contact:

GDINFO

Post by Quzar » Sat Aug 30, 2008 3:45 pm

So I wrote up a little program that complements MapleTest and gathers all possible extended data from the GD-Rom drive. The biggest piece of info this returns is the version number of the DC's GDRom firmware, mine happens to be 6.43 with a date code of 990408 (well, I assume that's a date stamp, it makes sense =P). Of course, unlike MapleTest this has no real goal or purpose, just thought it would be interesting.

Eventually I'll throw this into a full program with Mapletest and a few others and give them you know... graphical output and such.

Here's what my DC says:

Code: Select all

Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE              
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE    
Data+0x030 | 36 2e 34 33 20 20 20 20 20 20 20 20 20 20 20 20 | 6.43            
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE    
Data+0x010 | 20 20 52 65 76 20 36 2e 34 33 39 39 30 34 30 38 |   Rev 6.43990408
gd_EXEC_DEV_DIAG returned: 0x01
The first block of info is the result of sending the ATA command "Identify Packet Device". The spec has it returning 255chars, but this only gives back 80. The first 16 bytes should be some sort of info (non-ascii), then the next three lines are each some sort of identifier, from what I can tell:

Code: Select all

Identify Packet Device (ATA command 0xA1):
0x00-0x02: ?? 
0x03-0x0F: Reserved (??)
0x10-0x1F: Manufacturer (ascii, SEGA tends to pad ascii strings with 20[space])
0x20-0x2F: Device Name (ascii)
0x30-0x3F: Firmware Revision (ascii)
0x40-0x4F: Reserved (??, this isn't here by mistake, when issuing the command it returns this)
The second set of information comes from issuing the Packet Interface code "Request Mode"

Code: Select all

0x00-0x09: ??
0x0A-0x0F: Manufacturer (similar to the above?)
0x10-0x11: ?? (may belong to the version string, but why would they make it "  REV")
0x12-0x09: Firmware Revision (In my case "REV 6.43")
0x1A-0x1F: Firmware Date (YYMMDD)
The last thing is the result of the ATA command "Executive Device Diagnostic" which returns 0x01 on 'OK' and anything else means that there's a problem.

The program and it's source code is attached below. Maybe some of the same people who tried out MapleTest could run this and we'll see if there are other firmware revisions.

Note: This only outputs to console, so it is only for those with a CC, BBA, SLA, etc.

Edit: Added a description of the data as far as I can tell what it means.
Edit2: Chopped the junk out of my output and a typo.
Attachments
GDINFO_bin.zip
GDINFO Binary File (unscrambled)
(127.43 KiB) Downloaded 172 times
GDINFO_src.zip
GDINFO Source Code
(3.31 KiB) Downloaded 164 times
"When you post fewer lines of text than your signature, consider not posting at all." - A Wise Man
User avatar
BlueCrab
The Crabby Overlord
The Crabby Overlord
Posts: 5410
Joined: Mon May 27, 2002 11:31 am
Location: Sailing the Skies of Arcadia
Has liked: 2 times
Been liked: 16 times
Contact:

Re: GDINFO

Post by BlueCrab » Sat Aug 30, 2008 7:56 pm

Code: Select all

KallistiOS ##version##: Sat Aug 30 20:55:05 EDT 2008
  lj@kimiko.local:/Users/lj/Projects/clean/cadcdev/kos
thd: pre-emption enabled, HZ=100
maple: active drivers:
    Dreameye (Camera): Camera
    Sound Input Peripheral: Microphone
    PuruPuru (Vibration) Pack: JumpPack
    VMU Driver: Clock, LCD, MemoryCard
    Mouse Driver: Mouse
    Keyboard Driver: Keyboard
    Controller Driver: Controller
  DMA Buffer at ac08c660
vid_set_mode: 640x480IL NTSC
dc-load console support enabled
maple: attached devices:
  A0: Dreamcast Controller          (01000000: Controller)
  A1: Visual Memory                 (0e000000: Clock, LCD, MemoryCard)
  A2: SoundInputPeripheral (S.I.P.) (10000000: Microphone)
Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE              
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE    
Data+0x030 | 36 2e 34 32 20 20 20 20 20 20 20 20 20 20 20 20 | 6.42            
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE    
Data+0x010 | 20 20 52 65 76 20 36 2e 34 32 39 39 30 33 31 36 |   Rev 6.42990316
gd_EXEC_DEV_DIAG returned: 0x01
arch: shutting down kernel
net_unreg_device: 'bba' isn't registered
maple: final stats -- device count = 3, vbl_cntr = 4, dma_cntr = 4
vid_set_mode: 640x480IL NTSC
User avatar
Quzar
Dream Coder
Dream Coder
Posts: 7489
Joined: Wed Jul 31, 2002 12:14 am
Location: Miami, FL
Has liked: 0
Been liked: 3 times
Contact:

Re: GDINFO

Post by Quzar » Sun Aug 31, 2008 2:43 am

Some contributions from elsewhere:
kirk wrote:Asian Dreamcast, fairly old (purchased early 1999 IIRC) model HKT-3010, with replaced GD-ROM.

Code: Select all

Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE
Data+0x030 | 35 2e 30 36 20 20 20 20 20 20 20 20 20 20 20 20 | 5.06
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE
Data+0x010 | 20 20 52 65 76 20 35 2e 30 36 39 38 30 38 30 33 |   Rev 5.06980803
gd_EXEC_DEV_DIAG returned: 0x01
Slightly newer Asian Dreamcast.

Code: Select all

Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE
Data+0x030 | 35 2e 30 38 20 20 20 20 20 20 20 20 20 20 20 20 | 5.08
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE
Data+0x010 | 20 20 52 65 76 20 35 2e 30 38 39 38 31 30 32 32 |   Rev 5.08981022
gd_EXEC_DEV_DIAG returned: 0x01
Maddog wrote:PAL Dreamcast HKT-3030 (PAL DCs don't have manufacture date at bottom, but it's a model 1)

Code: Select all

Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE              
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE    
Data+0x030 | 36 2e 34 32 20 20 20 20 20 20 20 20 20 20 20 20 | 6.42            
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE    
Data+0x010 | 20 20 52 65 76 20 36 2e 34 32 39 39 30 33 31 36 |   Rev 6.42990316
gd_EXEC_DEV_DIAG returned: 0x01
NU-NRG wrote:PAL Dreamcast HKT-3030:

Code: Select all

OUTPUT:> Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
OUTPUT:> Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
OUTPUT:> Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE              
OUTPUT:> Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE    
OUTPUT:> Data+0x030 | 36 2e 34 33 20 20 20 20 20 20 20 20 20 20 20 20 | 6.43            
OUTPUT:> Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
OUTPUT:> Running gd_REQ_MODE: 32 bytes to read from GDROM
OUTPUT:> Got 32 bytes of data back
OUTPUT:> Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE    
OUTPUT:> Data+0x010 | 20 20 52 65 76 20 36 2e 34 33 39 39 30 34 30 38 |   Rev 6.43990408
OUTPUT:> gd_EXEC_DEV_DIAG returned: 0x01
ackmed wrote:Hi

Here are some more

JAPAN HKT-3000

Code: Select all

Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE              
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE    
Data+0x030 | 35 2e 30 37 20 20 20 20 20 20 20 20 20 20 20 20 | 5.07            
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE    
Data+0x010 | 20 20 52 65 76 20 35 2e 30 37 39 38 30 38 33 31 |   Rev 5.07980831
gd_EXEC_DEV_DIAG returned: 0x01
USA HKT-3020 #1

Code: Select all

Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE              
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE    
Data+0x030 | 36 2e 34 32 20 20 20 20 20 20 20 20 20 20 20 20 | 6.42            
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE    
Data+0x010 | 20 20 52 65 76 20 36 2e 34 32 39 39 30 33 31 36 |   Rev 6.42990316
gd_EXEC_DEV_DIAG returned: 0x01
USA HKT-3020 #2

Code: Select all

Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE              
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE    
Data+0x030 | 36 2e 34 33 20 20 20 20 20 20 20 20 20 20 20 20 | 6.43            
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE    
Data+0x010 | 20 20 52 65 76 20 36 2e 34 33 39 39 30 34 30 38 |   Rev 6.43990408
gd_EXEC_DEV_DIAG returned: 0x01
-ack
AvS wrote:HKT-3000 JAPAN

Code: Select all

Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE
Data+0x030 | 36 2e 34 32 20 20 20 20 20 20 20 20 20 20 20 20 | 6.42
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE
Data+0x010 | 20 20 52 65 76 20 36 2e 34 32 39 39 30 33 31 36 |   Rev 6.42990316
gd_EXEC_DEV_DIAG returned: 0x01
Maddog wrote:Treamcast, newest model (the black one)
This was a nasty one, for some reason the BBA wouldn't fit properly (suppose I should blame cheap Chinese plastics) so I had to remove the BBA plastic casing to allow it to fit. :roll:

Code: Select all

Running gd_ATA_IDENTIFY_PACKET_DEV: Got 80 bytes of data back
Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE              
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE    
Data+0x030 | 36 2e 34 33 20 20 20 20 20 20 20 20 20 20 20 20 | 6.43            
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE    
Data+0x010 | 20 20 52 65 76 20 36 2e 34 33 39 39 30 34 30 38 |   Rev 6.43990408
gd_EXEC_DEV_DIAG returned: 0x01
"When you post fewer lines of text than your signature, consider not posting at all." - A Wise Man
User avatar
Neoblast
DC Developer
DC Developer
Posts: 312
Joined: Sat Dec 01, 2007 8:51 am
Has liked: 0
Been liked: 0

Re: GDINFO

Post by Neoblast » Sun Nov 02, 2008 10:57 am

mine is a pal 3030 model 1

Code: Select all

Data+0x000 | 20 20 20 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Data+0x010 | 53 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | SE              
Data+0x020 | 43 44 2d 52 4f 4d 20 44 52 49 56 45 20 20 20 20 | CD-ROM DRIVE    
Data+0x030 | 36 2e 34 33 20 20 20 20 20 20 20 20 20 20 20 20 | 6.43            
Data+0x040 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |                 
Running gd_REQ_MODE: 32 bytes to read from GDROM
Got 32 bytes of data back
Data+0x000 | 00 00 00 00 00 b4 19 00 00 08 53 45 20 20 20 20 |           SE    
Data+0x010 | 20 20 52 65 76 20 36 2e 34 33 39 39 30 34 30 38 |   Rev 6.43990408
gd_EXEC_DEV_DIAG returned: 0x01
Post Reply