VOGONS


Reply 60 of 63, by carlostex

User metadata
Rank l33t
Rank
l33t

This card has potential to be useful as a poor man's AdLib Gold regarding compatibility, but that would require work on AIL/16, AIL/32 and DIGPAK drivers. I had a thought about this today so i took a look into the AIL/16 source code, DMASOUND.ASM is the assembly source for the digital playback drivers.

ELSEIFDEF ADLIBG ;Ad Lib Gold access routines must ;preserve DS,SI,DI! […]
Show full quote

ELSEIFDEF ADLIBG ;Ad Lib Gold access routines must
;preserve DS,SI,DI!

;****************************************************************************
IO_wait PROC
mov cx,500
mov dx,CTRL_ADDR
__wait: in al,dx
and al,01000000b
loopnz __wait
ret
ENDP

;****************************************************************************
enable_ctrl PROC RegNum ;Enable access to control chip
mov dx,CTRL_ADDR
mov al,0ffh
out dx,al
ret
ENDP

;****************************************************************************
disable_ctrl PROC RegNum ;Disable access to control chip
call IO_wait
mov dx,CTRL_ADDR
mov al,0feh
out dx,al
ret
ENDP

;****************************************************************************
get_ctrl_reg PROC RegNum ;Get control chip register value
call IO_wait
mov dx,CTRL_ADDR
mov ax,[RegNum]
out dx,al
call IO_wait
mov dx,CTRL_DATA
in al,dx
ret
ENDP

;****************************************************************************
set_ctrl_reg PROC RegNum,Val ;Set control chip register value
call IO_wait
mov dx,CTRL_ADDR
mov ax,[RegNum]
out dx,al
call IO_wait
mov dx,CTRL_DATA
mov ax,[Val]
out dx,al
ret
ENDP

;****************************************************************************
MMA_wait PROC ;Wait at least 470 nsec.
mov cx,100
__kill_time: jmp $+2
loop __kill_time
ret
ENDP

;****************************************************************************
MMA_write PROC Chan,Reg,Val ;Write byte to MMA register
mov ax,[Reg]
mov dx,DSP_ADDR
out dx,al
call MMA_wait
mov dx,[Chan]
shl dx,1
add dx,DSP_DATA
mov ax,[Val]
out dx,al
call MMA_wait
ret
ENDP

ENDIF

;****************************************************************************
reset_DSP PROC ;Returns AX=0 if failure
USES ds,si,di

IFDEF PAS

mov ax,1

ELSEIFDEF ADLIBG

call MMA_write C,0,9,10000000b
call MMA_write C,0,9,01110110b

call MMA_write C,1,9,10000000b
call MMA_write C,1,9,01110110b

mov ax,01110110b
mov PRC_0_shadow,ax

mov ax,1

I have no experience with sound drivers, and very little ASM experience, but by just taking a look it is quite obvious that: "No GOLD CTRL chip, no AdLib Gold". However, it seems this 2themax card has the Yamaha MMA at the required 38Ch port, but failing to go through the GOLD CTRL will prevent any sound attempted out of the MMA chip. So basically i was wondering if this driver could be manipulated to remove any GOLD CTRL dependencies, thus enabling this sound card to playback AdLib Gold stuff. The XMIDI driver probably needs dependencies removed too.

The AdLib Gold seems to have a lot of game support through middleware sound libraries, so this card has potential to be a little more useful.

Any code gurus around? Thoughts on this?

Reply 61 of 63, by Ozzuneoj

User metadata
Rank l33t
Rank
l33t
carlostex wrote on 2020-08-11, 17:35:
This card has potential to be useful as a poor man's AdLib Gold regarding compatibility, but that would require work on AIL/16, […]
Show full quote

This card has potential to be useful as a poor man's AdLib Gold regarding compatibility, but that would require work on AIL/16, AIL/32 and DIGPAK drivers. I had a thought about this today so i took a look into the AIL/16 source code, DMASOUND.ASM is the assembly source for the digital playback drivers.

ELSEIFDEF ADLIBG ;Ad Lib Gold access routines must ;preserve DS,SI,DI! […]
Show full quote

ELSEIFDEF ADLIBG ;Ad Lib Gold access routines must
;preserve DS,SI,DI!

;****************************************************************************
IO_wait PROC
mov cx,500
mov dx,CTRL_ADDR
__wait: in al,dx
and al,01000000b
loopnz __wait
ret
ENDP

;****************************************************************************
enable_ctrl PROC RegNum ;Enable access to control chip
mov dx,CTRL_ADDR
mov al,0ffh
out dx,al
ret
ENDP

;****************************************************************************
disable_ctrl PROC RegNum ;Disable access to control chip
call IO_wait
mov dx,CTRL_ADDR
mov al,0feh
out dx,al
ret
ENDP

;****************************************************************************
get_ctrl_reg PROC RegNum ;Get control chip register value
call IO_wait
mov dx,CTRL_ADDR
mov ax,[RegNum]
out dx,al
call IO_wait
mov dx,CTRL_DATA
in al,dx
ret
ENDP

;****************************************************************************
set_ctrl_reg PROC RegNum,Val ;Set control chip register value
call IO_wait
mov dx,CTRL_ADDR
mov ax,[RegNum]
out dx,al
call IO_wait
mov dx,CTRL_DATA
mov ax,[Val]
out dx,al
ret
ENDP

;****************************************************************************
MMA_wait PROC ;Wait at least 470 nsec.
mov cx,100
__kill_time: jmp $+2
loop __kill_time
ret
ENDP

;****************************************************************************
MMA_write PROC Chan,Reg,Val ;Write byte to MMA register
mov ax,[Reg]
mov dx,DSP_ADDR
out dx,al
call MMA_wait
mov dx,[Chan]
shl dx,1
add dx,DSP_DATA
mov ax,[Val]
out dx,al
call MMA_wait
ret
ENDP

ENDIF

;****************************************************************************
reset_DSP PROC ;Returns AX=0 if failure
USES ds,si,di

IFDEF PAS

mov ax,1

ELSEIFDEF ADLIBG

call MMA_write C,0,9,10000000b
call MMA_write C,0,9,01110110b

call MMA_write C,1,9,10000000b
call MMA_write C,1,9,01110110b

mov ax,01110110b
mov PRC_0_shadow,ax

mov ax,1

I have no experience with sound drivers, and very little ASM experience, but by just taking a look it is quite obvious that: "No GOLD CTRL chip, no AdLib Gold". However, it seems this 2themax card has the Yamaha MMA at the required 38Ch port, but failing to go through the GOLD CTRL will prevent any sound attempted out of the MMA chip. So basically i was wondering if this driver could be manipulated to remove any GOLD CTRL dependencies, thus enabling this sound card to playback AdLib Gold stuff. The XMIDI driver probably needs dependencies removed too.

The AdLib Gold seems to have a lot of game support through middleware sound libraries, so this card has potential to be a little more useful.

Any code gurus around? Thoughts on this?

As an owner of a couple of these cards myself, I would like to bump this thread to see if anyone has an interest in investigating this further. It'd be great if we could get these to work as full featured Adlib Gold clones, even if it requires a special driver. I have an pretty miniscule chance of ever coming across a real one, that's for sure.

I have an SCSI version and a boxed Sony version and would be willing to offer any assistance I can.

One thing I was just thinking about is that the SCSI version has silk screening for a 27C256-200 (DIP28) chip near the bottom edge of the board. Not sure what it would have been for, but it's something I didn't notice when looking at the card when I got it.

Now for some blitting from the back buffer.

Reply 62 of 63, by dionb

User metadata
Rank l33t++
Rank
l33t++
Ozzuneoj wrote on 2022-11-30, 16:57:

[...]

One thing I was just thinking about is that the SCSI version has silk screening for a 27C256-200 (DIP28) chip near the bottom edge of the board. Not sure what it would have been for, but it's something I didn't notice when looking at the card when I got it.

SCSI boot ROM?

Reply 63 of 63, by Ozzuneoj

User metadata
Rank l33t
Rank
l33t
dionb wrote on 2022-11-30, 23:07:
Ozzuneoj wrote on 2022-11-30, 16:57:

[...]

One thing I was just thinking about is that the SCSI version has silk screening for a 27C256-200 (DIP28) chip near the bottom edge of the board. Not sure what it would have been for, but it's something I didn't notice when looking at the card when I got it.

SCSI boot ROM?

That's what I was thinking it might be too.

I haven't used SCSI much but that seems like an odd option to have on a sound card... but then, this is about as weird as sound cards get in my opinion. Let's attempt to clone an Adlib Gold long after Creative had taken over the market, but then kind of give up before it is actually compatible... then make the SCSI interface bootable I guess? Finally, why not round it off with a volume pot that's so large that it doesn't fit many computer towers. 🤣

This card basically embodies all of the things that keep me interested in this stuff. It's an absurd looking design with very little record of why it exists at all, while potentially having untapped compatibility with cards that most of us will never lay hands on.

Now for some blitting from the back buffer.