Welcome to the Gamebase 64 forums.                 An attempt to document ALL Commodore 64 gameware before it's too late!

Set WinVice automatic to use drive 1581 by using d81-file

Discuss GameBase, the Universal Emulator Frontend!

Moderator: Jimbo

eagle
New Member
Posts: 24
Joined: Sun Nov 18, 2018 3:14 pm

Set WinVice automatic to use drive 1581 by using d81-file

Sun Nov 18, 2018 3:27 pm

Is there a way to change the drive automatic in Vice by using d81-files....
I have include some d81 over "Extras" in the Gamebase. The way to change the drive to 1581 and then to 1541 and so one is not optimal.
If there was a way - how can i do this.
Thanks for help
User avatar
.mad.
Honoured Member
Honoured Member
Location: Lancashire
Posts: 2256
Joined: Sun Jun 19, 2005 3:30 pm

Re: Set WinVice automatic to use drive 1581 by using d81-file

Sun Nov 18, 2018 8:32 pm

The script that comes with the GB64 v15 collection, already does that if the Game File is D81.

If GameType CONTAINS(d80||d81||d82)
Set_INI_Value(%emupath%\vice.ini||C64||FSDevice8Dir||"%gamepath%")
Set_INI_Value(%emupath%\vice.ini||C64||Drive8Type||1581)
End If

might be missing the check with the file being in the EXTRAS??

you could also use the command line and GEMUS.

add this before the run_emulator

if key_drive CONTAINS(d81)
Add_CLP ( -drive8type 1581)
else
Add_CLP ( -drive8type 1541)
end if

Run_Emulator()
---------

then use GEMUS on the EXTRAS entry to store the key...
drive=1581
Attachments
gemus.GIF
gemus.GIF (18.63 KiB) Viewed 74700 times
eagle
New Member
Posts: 24
Joined: Sun Nov 18, 2018 3:14 pm

Re: Set WinVice automatic to use drive 1581 by using d81-file

Sun Nov 18, 2018 11:04 pm

Thanks mad.
I will test it tomorrow. :D
eagle
New Member
Posts: 24
Joined: Sun Nov 18, 2018 3:14 pm

Re: Set WinVice automatic to use drive 1581 by using d81-file

Mon Nov 19, 2018 12:30 pm

Hi mad
i have it checked
in my WinVice.txt ist this:
---------------------------------------------------
If GameType CONTAINS(d80||d81||d82)

Set_INI_Value(1||C64||FSDevice8Dir||"%gamepath%")
Set_INI_Value(1||C64||Drive8Type||1581)

If Key_maxdrives CONTAINS(2||3||4)
If NumGameFiles > 1
Add_CLP2( -9 "%gamepathfile(1)%")
Set_INI_Value(1||C64||FSDevice9Dir||"%gamepath%")
Set_INI_Value(1||C64||Drive9Type||1581)
End If
End If
If Key_maxdrives CONTAINS(3||4)
If NumGameFiles > 2
Add_CLP2( -10 "%gamepathfile(2)%")
Set_INI_Value(1||C64||FSDevice10Dir||"%gamepath%")
Set_INI_Value(1||C64||Drive10Type||1581)
End If
End If
If Key_maxdrives CONTAINS(4)
If NumGameFiles > 3
Add_CLP2( -11 "%gamepathfile(3)%")
Set_INI_Value(1||C64||FSDevice11Dir||"%gamepath%")
Set_INI_Value(1||C64||Drive11Type||1581)
End If
End If
End If
------------------------------------------------
I dont have "%emupath%\vice.ini"

If i use my WinVICE.txt with Winvice 3.2 and d64 or d81 i become an error
Unbenannt.PNG
Unbenannt.PNG (6.28 KiB) Viewed 74690 times
Must i changed all "1" in the Set-line in my WinVICE.txt to "%emupath%\vice.ini"?
User avatar
.mad.
Honoured Member
Honoured Member
Location: Lancashire
Posts: 2256
Joined: Sun Jun 19, 2005 3:30 pm

Re: Set WinVice automatic to use drive 1581 by using d81-file

Mon Nov 19, 2018 5:31 pm

The error you have.
The script can not find the VICE.INI.
The INI file is missing or you have the incorrect emulator path set in the emulators.ini.

(%emupath%\vice.ini|| is the fool proof way of typing (1||

The (1|| refers to the full path to the vice.ini set in the Emulators.ini
if the 1= line is blank or missing, it will not work.

[WinVICE v3.1 x86]
UseShortFilenames=1
SupportedTypes=D64;D80;T64;TAP;PRG;g64
EmulatorPathFile=C:\GameBase\GBC_v15\Emulators\WinVICE-3.1-x86\x64.exe
ScriptFile=WinVICE30.txt
1=C:\GameBase\GBC_v15\Emulators\WinVICE-3.1-x86\vice.ini

newer versions of VICE 3.1.+ create an almost empty vice.ini
you will probably need to copy the vice.ini from the v2.4 folder to the 3.2 one.

also try replacing the 'Drive Type' SET_INI lines with Add_CLP ones to use the command-line...

Code: Select all

    If GameType CONTAINS(d80||d81||d82)
       
        Add_CLP( -fs8 "%gamepath%")
         Add_CLP( -drive8type 1581)
        
       If Key_maxdrives CONTAINS(2||3||4) 
        If NumGameFiles > 1
         Add_CLP2( -9 "%gamepathfile(1)%")
         Add_CLP( -fs9 "%gamepath%")
         Add_CLP( -drive9type 1581)
        End If
       End If
      If Key_maxdrives CONTAINS(3||4)
        If NumGameFiles > 2
         Add_CLP2( -10 "%gamepathfile(2)%")
         Add_CLP( -fs10 "%gamepath%")
         Add_CLP( -drive10type 1581)
        End If
      End If  
       If Key_maxdrives CONTAINS(4)
        If NumGameFiles > 3
         Add_CLP2( -11 "%gamepathfile(3)%")
         Add_CLP( -fs11 "%gamepath%")
         Add_CLP( -drive11type 1581)
        End If
       End If
    End If
Last edited by .mad. on Mon Nov 19, 2018 5:39 pm, edited 1 time in total.
eagle
New Member
Posts: 24
Joined: Sun Nov 18, 2018 3:14 pm

Re: Set WinVice automatic to use drive 1581 by using d81-file

Mon Nov 19, 2018 5:38 pm

ok, i will do that

Works but only with Winvice 2.4 (d64 and d81)
In the versions 3.0, 3.1 and 3.2 returns both with error
Unbenannt.PNG
Unbenannt.PNG (36.63 KiB) Viewed 74678 times
path are ok in emulators.ini

[WinVICE v3.2 (x86)]
UseShortFilenames=1
SupportedTypes=D64;D71;D80;D81;D82;G64;G41;X64;T64;P00;TAP;PRG;CRT
EmulatorPathFile=E:\GameBase\GBC_v15\Emulators\WinVICE-3.2-x86\x64.exe
ScriptFile=WinVICE.txt
1=E:\GameBase\GBC_v15\Emulators\WinVICE-3.2-x86\vice.ini
UseDefaultTypes=0
WaitFinish=1
2=

and also in gemus.dat

¬WinVICE v3.2 (x86)¬http://vice-emu.sourceforge.net¬¬x64.exe¬BE8F410F¬D64;D71;D80;D81;D82;G64;G41;X64;T64;P00;TAP;PRG;CRT¬Y¬WinVICE.txt¬vice.ini¬
Attachments
Unbenannt1.PNG
Unbenannt1.PNG (17.86 KiB) Viewed 74679 times
Unbenannt1.PNG
Unbenannt1.PNG (17.86 KiB) Viewed 74680 times
User avatar
.mad.
Honoured Member
Honoured Member
Location: Lancashire
Posts: 2256
Joined: Sun Jun 19, 2005 3:30 pm

Re: Set WinVice automatic to use drive 1581 by using d81-file

Mon Nov 19, 2018 7:32 pm

You just need to enable a virtual device (disk drive).
They are all switched off as default in new WinVICE

add this to TOP of script. :wink:

Set_INI_Value(1||C64||VirtualDevices||1)

;set SID to 6581 - default is "1" 8580 (no speech in Impossible Mission)
Set_INI_Value(1||C64||SidEngine||0)
Set_INI_Value(1||C64||SidModel||0)
eagle
New Member
Posts: 24
Joined: Sun Nov 18, 2018 3:14 pm

Re: Set WinVice automatic to use drive 1581 by using d81-file

Mon Nov 19, 2018 8:31 pm

and why nobody say it :(

OK thanks mad

Yesterday d81 not work with your entries for virtual drive and today it works. I've only activate the "True drive emulation" in the settings.
Is this the result for working d81?

So mad - im happy

Thanks for your great help. You are a tree in this forum :wink:
User avatar
.mad.
Honoured Member
Honoured Member
Location: Lancashire
Posts: 2256
Joined: Sun Jun 19, 2005 3:30 pm

Re: Set WinVice automatic to use drive 1581 by using d81-file

Tue Nov 20, 2018 12:40 pm

eagle wrote:
Mon Nov 19, 2018 8:31 pm
and why nobody say it :(
I suppose because VICE 3.0 came out after the release of gamebase 64 v15.
And older working emulators were supplied with the release.

Hopefully v16 will have working scripts for newer VICE.
I've only activate the "True drive emulation" in the settings.
Is this the result for working d81?
Yes, True Drive Emultion needs to be on for most extended disk formats (G64, D81).
You can turn it on from the Extras GEMUS entry (see pic above)

Glad you got it working. :D

Return to “The GameBase Frontend”

Who is online

Users browsing this forum: No registered users and 37 guests