dosbox

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Locked
hlidea
Posts: 3
Joined: Fri Feb 23, 2007 4:52 pm

Post by hlidea »

crazyc wrote:Posted a new patch and binary. It may be placebo, but some things seem to be significantly faster now.
I always meet bus errors when using the binary running some games.
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

hlidea wrote:
crazyc wrote:Posted a new patch and binary. It may be placebo, but some things seem to be significantly faster now.
I always meet bus errors when using the binary running some games.
Which games and what is the register dump?
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

I've posted a new patch and binary. The memory access code has been redone to reduce the number of non-cache-line contiguous load required to access emulated RAM. Now, at 333, Commander Keen runs at full speed, SimCity 2000 is playable and Tie Fighter approaches playability. This new code is probably a little buggy (Warcraft 2 crashes now but I think it's fixable), but there will almost certainly be, even after the bugs are fixed, reduced compatibility (but I'm not sure of the extent).
Also, I've added two new dos commands: 'INPUTMAP <button> <keycode>' maps the given button to the given keycode and 'INPUTMAP exec <cmdline>' runs cmdline with the inputmap, and 'SYSOPT clock <rate>' sets the cpu clock to rate.
Before anyone complains about having to type in these options remember that is what batch files are for.

Here is the button and keycode option strings

Code: Select all

const keyinfo INPUTMAP&#58;&#58;chartab&#91;&#93; = 
	&#123;&#123;KBD_1,"1"&#125;,&#123;KBD_2,"2"&#125;,&#123;KBD_3,"3"&#125;,&#123;KBD_4,"4"&#125;,&#123;KBD_5,"5"&#125;,&#123;KBD_6,"6"&#125;,&#123;KBD_7,"7"&#125;,&#123;KBD_8,"8"&#125;,&#123;KBD_9,"9"&#125;,&#123;KBD_0,"0"&#125;,
	&#123;KBD_q,"q"&#125;,&#123;KBD_w,"w"&#125;,&#123;KBD_e,"e"&#125;,&#123;KBD_r,"r"&#125;,&#123;KBD_t,"t"&#125;,&#123;KBD_y,"y"&#125;,&#123;KBD_u,"u"&#125;,&#123;KBD_i,"i"&#125;,&#123;KBD_o,"o"&#125;,&#123;KBD_p,"p"&#125;,
	&#123;KBD_a,"a"&#125;,&#123;KBD_s,"s"&#125;,&#123;KBD_d,"d"&#125;,&#123;KBD_f,"f"&#125;,&#123;KBD_g,"g"&#125;,&#123;KBD_h,"h"&#125;,&#123;KBD_j,"j"&#125;,&#123;KBD_k,"k"&#125;,&#123;KBD_l,"l"&#125;,&#123;KBD_z,"z"&#125;,
	&#123;KBD_x,"x"&#125;,&#123;KBD_c,"c"&#125;,&#123;KBD_v,"v"&#125;,&#123;KBD_b,"b"&#125;,&#123;KBD_n,"n"&#125;,&#123;KBD_m,"m"&#125;,
	&#123;KBD_f1,"f1"&#125;,&#123;KBD_f2,"f2"&#125;,&#123;KBD_f3,"f3"&#125;,&#123;KBD_f4,"f4"&#125;,&#123;KBD_f5,"f5"&#125;,&#123;KBD_f6,"f6"&#125;,&#123;KBD_f7,"f7"&#125;,
	&#123;KBD_f8,"f8"&#125;,&#123;KBD_f9,"f9"&#125;,&#123;KBD_f10,"f10"&#125;,&#123;KBD_f11,"f11"&#125;,&#123;KBD_f12,"f12"&#125;,
	&#123;KBD_esc,"esc"&#125;,&#123;KBD_tab,"tab"&#125;,&#123;KBD_backspace,"bs"&#125;,&#123;KBD_enter,"enter"&#125;,&#123;KBD_space,"space"&#125;,
	&#123;KBD_leftalt,"lalt"&#125;,&#123;KBD_rightalt,"ralt"&#125;,&#123;KBD_leftctrl,"lctrl"&#125;,&#123;KBD_rightctrl,"rctrl"&#125;,&#123;KBD_leftshift,"lshift"&#125;,&#123;KBD_rightshift,"rshift"&#125;,
	&#123;KBD_capslock,"caplock"&#125;,&#123;KBD_scrolllock,"scrllock"&#125;,&#123;KBD_numlock,"numlock"&#125;,
	&#123;KBD_grave,"`"&#125;,&#123;KBD_minus,"-"&#125;,&#123;KBD_equals,"="&#125;,&#123;KBD_backslash,"\\"&#125;,&#123;KBD_leftbracket,"&#91;"&#125;,&#123;KBD_rightbracket,"&#93;"&#125;,
	&#123;KBD_semicolon,";"&#125;,&#123;KBD_quote,"'"&#125;,&#123;KBD_period,"."&#125;,&#123;KBD_comma,","&#125;,&#123;KBD_slash,"/"&#125;,
	&#123;KBD_insert,"insert"&#125;,&#123;KBD_home,"home"&#125;,&#123;KBD_pageup,"pgup"&#125;,&#123;KBD_delete,"del"&#125;,&#123;KBD_end,"end"&#125;,&#123;KBD_pagedown,"pgdn"&#125;,
	&#123;KBD_left,"left"&#125;,&#123;KBD_up,"up"&#125;,&#123;KBD_down,"down"&#125;,&#123;KBD_right,"right"&#125;,
	&#123;KBD_kp1,"n1"&#125;,&#123;KBD_kp2,"n2"&#125;,&#123;KBD_kp3,"n3"&#125;,&#123;KBD_kp4,"n4"&#125;,&#123;KBD_kp5,"n5"&#125;,&#123;KBD_kp6,"n6"&#125;,&#123;KBD_kp7,"n7"&#125;,&#123;KBD_kp8,"n8"&#125;,&#123;KBD_kp9,"n9"&#125;,&#123;KBD_kp0,"n9"&#125;,
	&#123;KBD_kpslash,"n/"&#125;,&#123;KBD_kpmultiply,"n*"&#125;,&#123;KBD_kpminus,"n-"&#125;,&#123;KBD_kpplus,"n+"&#125;,&#123;KBD_kpenter,"nenter"&#125;,&#123;KBD_kpperiod,"n."&#125;, &#123;KBD_LAST, NULL&#125;&#125;;

const char *INPUTMAP&#58;&#58;button&#91;&#93; = &#123;"select", "start", "up", "right", "down", "left", "triangle", "circle", "cross", "square", NULL&#125;; 
Wraggster
Posts: 121
Joined: Fri Aug 26, 2005 7:40 am
Contact:

Post by Wraggster »

hi wheres the new patch i cant see the download.

also can you give detailed instructions for those who arent familar with dosbox to try this on the PSP
Webmaster of http://www.dcemu.co.uk

DCEMU The Worlds Only Homebrew & Gaming Network of Sites.
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

Wraggster wrote:hi wheres the new patch i cant see the download.
4th post, first page.
Wraggster wrote:also can you give detailed instructions for those who arent familar with dosbox to try this on the PSP
Do you mean the input mapping? I wrote it to be used with batch files, somthing like this:

Code: Select all

@ECHO OFF
INPUTMAP up up
INPUTMAP right right
INPUTMAP down down
INPUTMAP left left
INPUTMAP triangle w
INPUTMAP square a
INPUTMAP cross s
INPUTMAP circle d
INPUTMAP start enter
INPUTMAP select esc
SYSOPT clock 333
INPUTMAP exec doom2
(not that doom2 is playable, you'd be much better off with the psp port)
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

New patch and binary. Fixed the audio somewhat and switched to the scummvm ym3182 emulator. Also, made the x87 use single floats instead of double, this will probably cause problems with some apps, but should be a lot faster with programs that use the fpu frequently. The 16 color vga modes now use 4bpp textures, not much of a speed improvement here though because converting the data from planer to packed is cpu intensive; if any has any ideas how to speed this up, right now it uses a lookup table , I'd like to hear them.
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

Another new patch and binary at the links above. This fixes a serious bug in dpmi emulation. Also, the binary is 25% smaller since I now link it against uClibc++. I've added a three new config file options to control a very basic autocycle system.

Code: Select all

&#91;cpu&#93;
autocycle=true
mincycles=600
maxcycles=3000
This will adjust the cycles between 600 and 3000 by attempting to match the emulated vsync with the actual one. This works well with games the run at or nearly full speed.
l00k
Posts: 12
Joined: Thu Apr 12, 2007 12:36 am

Post by l00k »

hi

just playing around witth this nice project. I was finding the command prompt a bit fiddley so I stuck this on to auto boot from dosbox.conf

http://www.ritlabs.com/download/dn/dn151.zip

I used something similar back in the day when my brothers were too thick to type.

also found dropping the mouse sensetivity down to 10 helped alot
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

l00k wrote:also found dropping the mouse sensetivity down to 10 helped alot
The last version I just posted makes the mouse less sensitive, you will probably want to raise sensitivity to 80 or 90.
l00k
Posts: 12
Joined: Thu Apr 12, 2007 12:36 am

Post by l00k »

crazyc wrote:
l00k wrote:also found dropping the mouse sensetivity down to 10 helped alot
The last version I just posted makes the mouse less sensitive, you will probably want to raise sensitivity to 80 or 90.
I've been trying to track down elf2pbp so I can patch myself a new eboot but I cant find it anywhere.

Can you stick up the new eboots somewhere please?

BTW The launcher thing works well cant believe 4dsports boxing just loaded up! shame I dont have the manual to get past copy protection :/
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

l00k wrote: I've been trying to track down elf2pbp so I can patch myself a new eboot but I cant find it anywhere.

Can you stick up the new eboots somewhere please?

BTW The launcher thing works well cant believe 4dsports boxing just loaded up! shame I dont have the manual to get past copy protection :/
The dosbox binary is ready to go. Just rename it to EBOOT.PBP and put it in the appropriate directory. I use psplink to load it so that why I didn't rename it.
l00k
Posts: 12
Joined: Thu Apr 12, 2007 12:36 am

Post by l00k »

crazyc wrote:
l00k wrote: I've been trying to track down elf2pbp so I can patch myself a new eboot but I cant find it anywhere.

Can you stick up the new eboots somewhere please?

BTW The launcher thing works well cant believe 4dsports boxing just loaded up! shame I dont have the manual to get past copy protection :/
The dosbox binary is ready to go. Just rename it to EBOOT.PBP and put it in the appropriate directory. I use psplink to load it so that why I didn't rename it.
cheers for that just showing my psp n00biness there....
Weaver1497
Posts: 18
Joined: Thu Apr 12, 2007 1:59 pm

Post by Weaver1497 »

CrazyC,
I would like to thank you. Playing Quest for Glory 1 VGA by Sierra on my PSP is an absolute dream come true! I really cannot thank you enough. This is AMAZING! Couple of questions to anyone, maybe some insight to a "noobie" (me)

I have been in the PSP emu scene from the start and consider myself somewhat knowledgable. And Love dosbox, I am very glad you have continued work. I actually downloaded a PSP ready version from DCemu that a user named Belthasar00 actually created.

I have tried to create one using the bin files that you upload but they always come up as corrupted data. Could someone teach me how to create them into eboots? So they are literaly "plug and play" for the PSP scene. If I knew how I will be more than happy to distribute so more people get to use this amazing program.

Also the interface, specifically typing is extremely difficult. Can anything be done about that? a virtual Keyboard like PSPUAE?

Once again, you have made a childhood dream of mine a complete reality! Thank you soooooooo much.

(I apoligize if these questions sound extremely amateur, just need some help.)
l00k
Posts: 12
Joined: Thu Apr 12, 2007 12:36 am

Post by l00k »

Weaver1497 wrote:CrazyC,
I would like to thank you. Playing Quest for Glory 1 VGA by Sierra on my PSP is an absolute dream come true! I really cannot thank you enough. This is AMAZING! Couple of questions to anyone, maybe some insight to a "noobie" (me)

I have been in the PSP emu scene from the start and consider myself somewhat knowledgable. And Love dosbox, I am very glad you have continued work. I actually downloaded a PSP ready version from DCemu that a user named Belthasar00 actually created.

I have tried to create one using the bin files that you upload but they always come up as corrupted data. Could someone teach me how to create them into eboots? So they are literaly "plug and play" for the PSP scene. If I knew how I will be more than happy to distribute so more people get to use this amazing program.

Also the interface, specifically typing is extremely difficult. Can anything be done about that? a virtual Keyboard like PSPUAE?

Once again, you have made a childhood dream of mine a complete reality! Thank you soooooooo much.

(I apoligize if these questions sound extremely amateur, just need some help.)
If you dont want to type download this dos app (dos navigator) and copy it into dir called dosbox in the root of your psp which is then going to be mounted as C

http://www.ritlabs.com/download/dn/dn151.zip

here's what I have in my dosbox.conf autoexec bit

Code: Select all

&#91;autoexec&#93;
# Lines in this section will be run at startup.
mount c ms0&#58;/psp/dosbox
SYSOPT clock 333
c&#58;
cd dn151\
dn.com
If you copy all your dos program directories into /psp/dosbox/ you can then use the mouse control in dos navigator to lauch your programs.

works for me
Retron
Posts: 5
Joined: Fri Apr 13, 2007 4:02 am

Post by Retron »

First up, many thanks for porting DOSBox! It's right up my street as I'm probably one of the few who's insane enough to keep an old PC running just for old games.

Anyway, I've got DOSBox for the PSP up and running. Wolf runs after a fashion, but the status bar doesn't draw - no biggy, as it's a relatively complex game and would doubtless be laggy anyway.

Duke Nukem I seems to run perfectly, that is apart from the input configuration. I used the batch file as posted earlier to set up a key config:

Code: Select all

@ECHO OFF
INPUTMAP up up
INPUTMAP right right
INPUTMAP down down
INPUTMAP left left
INPUTMAP triangle d
INPUTMAP square a
INPUTMAP cross lctrl
INPUTMAP circle lalt
INPUTMAP start enter
INPUTMAP select esc
However, DOSBox crashed.

I then tried manually typing in:

inputmap up up

as a test, but it still caused DOSBox to crash. The dump looked like this:

Code: Select all

Exception - Bus error &#40;data&#41;
EPC       - 0888E48C
Cause     - 1000001C
Status    - 20008613
BadVAddr  - 00841008
zr&#58;00000000 at&#58;08B60000 v0&#58;00000018 v1&#58;00000030
a0&#58;00000002 a1&#58;00000050 a2&#58;08910000 a3&#58;0000006E
t0&#58;00000075 t1&#58;00000070 t2&#58;00000001 t3&#58;00000002
t4&#58;00000032 t5&#58;00000000 t6&#58;0890480C t7&#58;08900000
s0&#58;0000000C s1&#58;00000034 s2&#58;00000002 s3&#58;00000050
s4&#58;08CCEFB0 s5&#58;00000002 s6&#58;0885D8A4 s7&#58;08910000
t8&#58;00000000 t9&#58;00000061 k0&#58;0885FF00 k1&#58;00000000
gp&#58;08917FE0 sp&#58;0885D660 fp&#58;08910000 ra&#58;00000048

eax&#58;00004A00 ecx&#58;00000000 edx&#58;00000000 ebx&#58;00000040
esp&#58;00000400 ebp&#58;00000000 esi&#58;00000100 edi&#58;00000000
es&#58;0000006D os&#58;0000006D ss&#58;0000006D ds&#58;0000006D
fs&#58;00000000 gs&#58;00000000 eip&#58;0000010E
There's nothing fancy in my dosbox.conf, although I've disabled speaker and SB emulation. The following is in the autoexec section:

Code: Select all

mount c ms0&#58;/psp/dos
c&#58;
#sysopt clock 333
Now, I'm still a relative newb to the PSP homebrew scene, but not to DOS in general. If it helps any, I'm running DarkAlex's modified firmware, 3.02 OE-B.

Am I just being daft, or is it likely to be a firmware issue causing that crash?
Last edited by Retron on Fri Apr 13, 2007 4:20 am, edited 1 time in total.
Weaver1497
Posts: 18
Joined: Thu Apr 12, 2007 1:59 pm

Post by Weaver1497 »

Sweet! Thanks 100k, I'm actually at work right now, so I'll impliment that file when I get home. I have 1 more request though, can you walk me through how to compile CrazyC's binary's that he updates?

Now that he is working on the project somewhat regularly I would love to be able to compile the latest bin on my own. Instead of waiting or requesting in other forums for someone else to do it.

TO ALL: 100k adding the "gui" of dos navigator looks great, making it a much more fully functional "emu" my question is to the community how else, can we help to make this a better, more user friendly emulator? How many cycles can the PSP actually churn out safely before the speed is crippled? What's the ideal frameskip? Can we make a "user" dosbox.conf file that takes full advantage of what the "user" community can create? Sorry If I'm rambling, I want this project to go as far as possible!

GAMES IVE TESTED THAT WORK:
Space Quest 1 VGA Remake
Space Quest 4 CD version
Space Quest 5
King's Quest 5 CD version
King's Quest 6 CD version (some audio errors, unlike other CD versions)
Gabriel Knight CD version
Police Quest 1 VGA Remake
Police Quest 3
Quest for Glory VGA Remake
Quest for Glory 3
Quest for Glory 4 CD Version
Leisure Suit Larry VGA Remake
Leisure Suit Larry 5
Conquest of the Longbow
Freddy Pharkus Frontier Pharmicist
Laura Bow - Colonels Bequest
Laura Bow - Dagger of Amon Ra
Rex Nebular
Sherlock Holmes - Case of the Serrated Scalpel

The shocking thing is the games that worked the best were some of the later games like QFG4 and Freddy Pharkus, I also am using the first update he sent out that was compiled by someone at DCemu so I dont think this is upped to 333, and I'm not using frame skip, I consider these game playable.

Which is a great sign considering what I'm running it on a non-optimized dosbox.conf. (once again if someone could help me fine tune a .conf as well as compile the latest binary I would LOVE to continue to test these games.) Also all these games have the abillity under the control panel to up the speed in-game, making it much more playable. (The majority of sierra games had these.)
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

However, DOSBox crashed.
It crashes for me too, I've got some other fixes i'm working on too. I'll try to make a new patch with a fix for this soon.
l00k
Posts: 12
Joined: Thu Apr 12, 2007 12:36 am

Post by l00k »

How about this for a cool old dos game ?

Bullfrogs Syndicate

It works on pspdosbox too (bit slow for now tho)

for those without the compilation progs grab the binary "dosbox" that crazyc posted earlier and rename it eboot.pbp copy it to the dosbox_psp folder replacing the old one
Weaver1497
Posts: 18
Joined: Thu Apr 12, 2007 1:59 pm

Post by Weaver1497 »

100k,
I've downloaded his binaries renamed them as EBOOT.PBP and put that same file in both the Dosbox_psp folder and the dosbox_psp% folder, all I get is corrupted data, under my Game menu.
Am I doing something wrong?

Also 100k would you mind sharing your .conf file? if Im allowed to ask for it? if not I apoligize
l00k
Posts: 12
Joined: Thu Apr 12, 2007 12:36 am

Post by l00k »

Weaver1497 wrote:100k,
I've downloaded his binaries renamed them as EBOOT.PBP and put that same file in both the Dosbox_psp folder and the dosbox_psp% folder, all I get is corrupted data, under my Game menu.
Am I doing something wrong?

Also 100k would you mind sharing your .conf file? if Im allowed to ask for it? if not I apoligize
Dont overwrite the eboot.pbp thats in the % directory just the one in Dosbox_PSP

heres my conf

http://www.deardenboys.co.uk/dosbox.conf
User avatar
Wally
Posts: 663
Joined: Mon Sep 26, 2005 11:25 am

Post by Wally »

Dangerous Dave goes too fast :/ Its hiliarious
Weaver1497
Posts: 18
Joined: Thu Apr 12, 2007 1:59 pm

Post by Weaver1497 »

100k, thanks for the walkthrough I'm a little slow at this stuff, and thank you SOOOOOO much for your .conf

What other games are people testing? I would love to piece together a compat chart
W00fer
Posts: 40
Joined: Fri Apr 13, 2007 8:02 am

Post by W00fer »

So well i'm brand new into this dosbox thing. First i had only the corrupted eboot.pbp :) but now dosbox runs :)

Also with the config from l00k, Navigator runs, but WHAT a hassle to run programs there omg.

I'm trying to play Duke Nukem 1, which runs. But how to play when you can't define controls ?

Standard Keymapper from Dosbox can't be run.

Now i know you have to run these games with BAT files, but it doesn't work very properly.

Anyone knows how to map keys correctly ? Sound works :)

I got this BUS ERROR:

Image
Last edited by W00fer on Fri Apr 13, 2007 9:09 am, edited 2 times in total.
Wraggster
Posts: 121
Joined: Fri Aug 26, 2005 7:40 am
Contact:

Post by Wraggster »

anyone tried theme park :)
Webmaster of http://www.dcemu.co.uk

DCEMU The Worlds Only Homebrew & Gaming Network of Sites.
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

I posted a new binary that fixes the mapping problems and some problems with VGA. I'll post a new patch when I finish with some other things.
Weaver1497
Posts: 18
Joined: Thu Apr 12, 2007 1:59 pm

Post by Weaver1497 »

Sweet! New binary! I'm really glad you continue to develop this CrazyC! Got a question for anyone... What exactly do the patch updates do? Is that like a config file?
User avatar
Wally
Posts: 663
Joined: Mon Sep 26, 2005 11:25 am

Post by Wally »

Wraggster wrote:anyone tried theme park :)
I will when i get home Wraggs :)
crazyc
Posts: 408
Joined: Fri Jun 17, 2005 10:13 am

Post by crazyc »

Weaver1497 wrote:Sweet! New binary! I'm really glad you continue to develop this CrazyC! Got a question for anyone... What exactly do the patch updates do? Is that like a config file?
Source code patch to satisfy the GPL and so others can help with development if they'd like.
cloudhunter
Posts: 86
Joined: Thu Aug 17, 2006 3:27 am

Post by cloudhunter »

Are you going to consider implementing any keyboard libraries, such as pi-key by Fanjita?

Cloudy
:)
DarthGameR
Posts: 18
Joined: Fri Apr 13, 2007 12:52 pm

REMAPPING

Post by DarthGameR »

remapping doesnt work for me. i tried using batch file & inputting commands directly but they dont affect the game. it just continues to run with the default ones.
Locked