jhhoward
Posts: 4
Joined: Tue Oct 29, 2019 1:49 pm

Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Tue Oct 29, 2019 1:51 pm

Faux86 is an 8086 PC emulator that I have been developing to run bare metal on a Raspberry Pi. This means that the Pi does not have to boot Linux or any other OS first - it just boots straight into MS-DOS. This means a fast boot time and externally it looks like an actual 8086 PC is booting.

Faux86 started as a fork of Mike Chamber's Fake86 emulator but a lot of the code has been shuffled around or rewritten.

Release binaries can be found here:
https://github.com/jhhoward/Faux86/releases

The emulator features:
- 8086 and 80186 instruction set emulation
- CGA / EGA / VGA emulation is mostly complete
- PC speaker, Adlib and Soundblaster sound emulation
- Serial mouse emulation

Currently Raspberry Pi models zero, 1, 2 and 3 are supported. To get up and running:
- Download the SD card image from the releases page
- Write the image to an SD card (e.g. using Win32DiskImager on Windows)
- Plug in your SD card to your Raspberry Pi and switch it on!

The release image has an included floppy disk boot image that the emulator will mount as drive A and boot from. The SD card will be mounted by the emulator as drive C. Just copy your favourite DOS games / apps to the SD card and you will be able to access them from the emulator.

The SD card image is fixed at 32MB as I had some problems with the emulator when trying to use larger disk sizes.

epoch1970
Posts: 5156
Joined: Thu May 05, 2016 9:33 am
Location: Paris, France

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Tue Oct 29, 2019 2:42 pm

Well I'm probably never going to run it, but nevertheless, my hat's off to you, sir!
"S'il n'y a pas de solution, c'est qu'il n'y a pas de problème." Les Shadoks, J. Rouxel

hippy
Posts: 7793
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Tue Oct 29, 2019 3:30 pm

It looks good, booted on a 1B and 3B, got the C: prompt, but then what ?

It doesn't seem to enable any USB keyboards I have.

jhhoward
Posts: 4
Joined: Tue Oct 29, 2019 1:49 pm

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Tue Oct 29, 2019 3:56 pm

hippy wrote: It looks good, booted on a 1B and 3B, got the C: prompt, but then what ?

It doesn't seem to enable any USB keyboards I have.
Did you make sure that your USB keyboard was plugged in before plugging in the power? Currently the emulator doesn't support hot swapping of USB devices

hippy
Posts: 7793
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Tue Oct 29, 2019 4:37 pm

Seems it's a bit picky about keyboards, but I found one which works.

Runs WordStar, GW-Basic, TurboBasic, compiled Basic programs, various other MS-DOS utilities, so I would mark that up as "working". Working brilliantly in fact.

Fantastic job. Well done.

jhhoward
Posts: 4
Joined: Tue Oct 29, 2019 1:49 pm

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Tue Oct 29, 2019 4:49 pm

Glad to hear you it was working well for you after switching out for a different keyboard.

For the keyboard that didn't work: does it have any particular features? e.g. a built in USB hub or if its a wireless keyboard

hippy
Posts: 7793
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Tue Oct 29, 2019 4:56 pm

jhhoward wrote:
Tue Oct 29, 2019 4:49 pm
For the keyboard that didn't work: does it have any particular features?
No but I do now recall the ones which don't work throw 'endpoint errors' in dmesg under Raspbian which I guess could be catching Circle out. I'm happy to put it down to problems at my end rather than what you have provided.

User avatar
bomblord
Posts: 266
Joined: Sun Jul 14, 2019 2:54 am

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Wed Oct 30, 2019 9:14 pm

No Pi-4 support or support for any any newer versions of Windows atm?

User avatar
scruss
Posts: 3237
Joined: Sat Jun 09, 2012 12:25 pm
Location: Toronto, ON
Contact: Website

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Wed Oct 30, 2019 10:02 pm

it's an 8086/80186 emulator: that's before Windows' time.
‘Remember the Golden Rule of Selling: “Do not resort to violence.”’ — McGlashan.
Pronouns: he/him

hippy
Posts: 7793
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Wed Oct 30, 2019 11:02 pm

I believe Windows 3.0 ran on an 80186.

Windows 3.11 and later demanded more than that; 80286 or 80386.

I have some vague recollections of GEM or something like that running as well.

User avatar
rpdom
Posts: 17212
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Thu Oct 31, 2019 7:51 am

hippy wrote:
Wed Oct 30, 2019 11:02 pm
I have some vague recollections of GEM or something like that running as well.
I used to run some applications under GEM on my Archimedes using Acorn's PC Emulator software and a DOS floppy. The 4MHz ARM2 using software emulation chip ran GEM at close to the speed of a 4.77MHz 8088 system.
Unreadable squiggle

jhhoward
Posts: 4
Joined: Tue Oct 29, 2019 1:49 pm

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Thu Oct 31, 2019 9:02 am

bomblord wrote: No Pi-4 support or support for any any newer versions of Windows atm?
It should be possible to compile for Pi 4 (Circle supports it) but since I don't have a Pi 4 to test with I didn't bundle it in the release yet.

Not sure what you meant by Windows support, but as others pointed out Windows 3.0 is probably the 'newest' version that will run on the emulator. I haven't actually tested running Windows though!

hippy
Posts: 7793
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Thu Oct 31, 2019 4:55 pm

Just a FYI update - Couldn't get OpenGEM to install, but will try Windows 3.0 later. It sure brings back a sense of nostalgia when run in DosBox under Raspbian :D

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 26685
Joined: Sat Jul 30, 2011 7:41 pm

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Thu Oct 31, 2019 4:59 pm

bomblord wrote:
Wed Oct 30, 2019 9:14 pm
No Pi-4 support or support for any any newer versions of Windows atm?
That's down to Microsoft. At RPI we do nothing Windows related at all.
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed.
I've been saying "Mucho" to my Spanish friend a lot more lately. It means a lot to him.

hippy
Posts: 7793
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Thu Oct 31, 2019 7:02 pm

Yay! Windows 3.0 Multimedia Edition running. Not running brilliantly, but a success none the less ...
win30.jpg
Windows 3.0 under Faux86
win30.jpg (44.89 KiB) Viewed 4208 times

User avatar
bomblord
Posts: 266
Joined: Sun Jul 14, 2019 2:54 am

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Sat Nov 02, 2019 8:38 pm

jamesh wrote:
Thu Oct 31, 2019 4:59 pm
bomblord wrote:
Wed Oct 30, 2019 9:14 pm
No Pi-4 support or support for any any newer versions of Windows atm?
That's down to Microsoft. At RPI we do nothing Windows related at all.
Correct I was more aiming the question at the creator of this emulator to see if, for example, Windows 95 might work on it. And also if the emulator in general worked on the Pi 4 since he specifically mentioned older boards.

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13110
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Sat Nov 02, 2019 9:09 pm

hippy wrote:
Wed Oct 30, 2019 11:02 pm
I believe Windows 3.0 ran on an 80186.

Windows 3.11 and later demanded more than that; 80286 or 80386.

I have some vague recollections of GEM or something like that running as well.
Yes, but the intel i80186 had built in peripherals (interrupt controller, timer etc) that made it incompatible with a 100% compatible IBM PC clone. It was almost only used for embedded controllers.

Very few personal computers used the i80186, but these were not IBM PC compatible, and although Windows 3.0 could run on the 186, windows 3.1 could not!

https://en.wikipedia.org/wiki/Intel_80186


The real follow up for PC’s was the i80286.

User avatar
leilei
Posts: 31
Joined: Wed Jun 26, 2019 2:26 am

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Mon Nov 04, 2019 3:51 am

I think one of the Tandys were a 80186. that's about it for computers though

Windows 95 won't be possible until there's 386 emulation (as a bare minimum).

User avatar
scruss
Posts: 3237
Joined: Sat Jun 09, 2012 12:25 pm
Location: Toronto, ON
Contact: Website

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Mon Nov 04, 2019 4:02 pm

Living in Ontario and working in tech, I have to advocate for the CEMCorp ICON. It was an 80186-based educational computer running QNX released in 1984. Almost all of them were destroyed due to a change in provincial education policy, and since they were diskless clients, any remaining terminals are useless without the (even rarer) server. I think there's something like two working systems left.

Ontarians of a certain age have fond memories of the ICON's trackball navigation.
‘Remember the Golden Rule of Selling: “Do not resort to violence.”’ — McGlashan.
Pronouns: he/him

K9Kraken
Posts: 1
Joined: Tue Jan 21, 2020 6:33 pm

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Tue Jan 21, 2020 6:44 pm

This is an awesome project and I hope to see it progress!

I tested out a few games on version 0.1:

SQ1 VGA - Takes a minute to load with some popping noises. Graphics and sound mostly working, mouse cursor only moves on the Y axis, up down. (Tried a different mouse and it worked fine.)

Commander Keen 1 - Loads, sound is working, but graphics are all garbled.

Bananoid - Gives error "I am sorry, but this game requires a vga card."

Snarf - Locks up before starting the game.

Lemmings - Blank screen and locks up, tried CGA and VGA with the same results.

RetroMal
Posts: 2
Joined: Mon Jun 29, 2020 10:20 am

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Mon Jun 29, 2020 10:41 am

Thank you for you hard work. I'm looking for a retro gaming project that works OK on my Pi 1.

Silly question - how do I get sound running ? I have run the Day of the Tentacle configuration and it doesn't even take a guess at the sound card settings.

Your initial post says FAUX86 is SoundBlaster compatible - what settings do I use and any particular set of drivers ?

Am I missing some documentation/examples ?

Thanks

Mal

User avatar
rpdom
Posts: 17212
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Mon Jun 29, 2020 11:58 am

RetroMal wrote:
Mon Jun 29, 2020 10:41 am
Thank you for you hard work. I'm looking for a retro gaming project that works OK on my Pi 1.

Silly question - how do I get sound running ? I have run the Day of the Tentacle configuration and it doesn't even take a guess at the sound card settings.

Your initial post says FAUX86 is SoundBlaster compatible - what settings do I use and any particular set of drivers ?

Am I missing some documentation/examples ?

Thanks

Mal
If you want to play DotT, just run it under SCUMMVM in Raspberry Pi OS. That will run fine with full sound.
Unreadable squiggle

RetroMal
Posts: 2
Joined: Mon Jun 29, 2020 10:20 am

Re: Faux86 - an 8086 PC emulator for Raspberry Pi that runs bare metal

Mon Jun 29, 2020 12:38 pm

DotT was just an example. I want to be able to run old school DOS games.

Return to “Gaming”