Ophis for DOS?

This is an archive of a topic from NESdev BBS, taken in mid-October 2019 before a server upgrade.
View original topic
Ophis for DOS?
by on (#216502)
Hi! Is there an Ophis assembler for DOS? I have a DOS laptop at my mother's house and want to use it for NES programming. :)
Re: Ophis for DOS?
by on (#216503)
I think you're gonna have to go a little more old school if all you have is DOS.
Re: Ophis for DOS?
by on (#216505)
I have a DOS laptop at my mother's house. I also have a Win10/64 laptop at home and access to several Win32 systems. I just like the delusion that the DOS laptop can be useful, but sadly, all I do on it is install software. :(
Re: Ophis for DOS?
by on (#216506)
How much RAM and how much HDD does the MS-DOS laptop have? I ask because if it's at least a 486 with several MB of extended memory, you might be able to run DJGPP under MS-DOS, which gives you much of the same GNU software that you have under Linux, and from there build NESASM, ASM6, or cc65.

I seem to remember having used x816 under MS-DOS to make the first version of my Sprite Cans demo.
Re: Ophis for DOS?
by on (#216509)
It has a 486DX2/75MHz and about 10MB XMS memory not used by a RAM drive. The hard drives are simulated but have enough free space for some large things. However, I don't want to install DJGPP. I have Turbo C++ 1.01, and on other computers Watcom and Turbo C++ 3.0. I can compile NESBASIC but want to compile the OPHIS tool. Is its source code available? I didn't check but probably should. :)
Re: Ophis for DOS?
by on (#216510)
Ophis source code is available, but it requires Python 2, and I don't know if Python is made for MS-DOS anymore.
Re: Ophis for DOS?
by on (#216511)
Okay. I have another NES assembler. Thank you for your insight. :)
Re: Ophis for DOS?
by on (#216513)
Uhh...an the latest stable release of NBASIC be compiled for DOS16? I have a few C/C++ compilers to target DOS16.
Re: Ophis for DOS?
by on (#216514)
I would think that cc65 should be compilable for DOS as well, with some small amount of setup?
Re: Ophis for DOS?
by on (#216515)
Doesn't HXDos let you run win32 console applications on Dos?
Re: Ophis for DOS?
by on (#216517)
I run Windows 95 OSR2 in a 486DX laptop with 12 Mb RAM. Of course modern GUI based programs crawl, but as long as you open a console you can run console based program just fine. I don't know if ca65, nesasm or asm6 will work in Windows 9X. I can try, if I find the time - and my PCMCIA CF-Card reader.
Re: Ophis for DOS?
by on (#216522)
The last time I tried cc65 under Win32, it only processed short filenames. Also, cc65 used to have a DOS port, and I think it can be compiled as a DOS32 application. Now, can I compile NBASIC as a DOS16 application?
Re: Ophis for DOS?
by on (#216527)
I looked at NBASIC's source code, and it seems to be DOS-compatible. I ask the creator of NBASIC and NESAsm to compile DOS binaries of these.
Re: Ophis for DOS?
by on (#216532)
Harry Potter wrote:
Also, cc65 used to have a DOS port, and I think it can be compiled as a DOS32 application.

Ah, yes the DOS build from 2012 is still on the old FTP:
ftp://ftp.musoftware.de/pub/uz/cc65/
Re: Ophis for DOS?
by on (#216538)
NESASM can run under DOS but you need it's extmem program iirc.
Re: Ophis for DOS?
by on (#216539)
You could alternately just use minus/Norman Yen's x816, which is natively for MS-DOS. It's a 65816 assembler with a SNES focus, but will work for 6502 -- just make sure you don't use any 65c02 or 65816 addressing modes/opcodes and you'll be fine. It's still, IMO, one of the best 65xxx assemblers there is. It requires at least 4MBytes of XMS memory, so make sure you have EMM386 loaded and enough RAM. Best-suited for a 486 system. Latest (and last) version was 1.12f: https://www.zophar.net/utilities/nesdev ... mbler.html

Alternately, there's a separate thread about getting x816 ported to a present-day OS.
Re: Ophis for DOS?
by on (#216545)
Dude seriously...

tass64 will compile on a M68K Amiga so you can be build for DOS easily. ACME I would also think, TASM is DOS, PDS is DOS if you can get a hacked version that skips the "check for the ISA card" check. DASM, xa65... DOS 6502 assemblers are a dime a dozen.
Re: Ophis for DOS?
by on (#216557)
Confirmed: cc65 just compiled one of my games in a Windows 95 486 laptop. Long filenames and all.
Re: Ophis for DOS?
by on (#216560)
na_th_an: I thank you for your insight. Maybe I should try it again. :)
Re: Ophis for DOS?
by on (#216564)
I'm sorry, but I installed a new copy of cc65 on my Win98 computer and checked some environment variables (it appears that I already had a copy installed), and, when I ran a batch file that compiles one of my cc65 programs, the console window displays an Access Denied message, and I keep getting an Invalid Operation error dialog box. What could be the problem?
Re: Ophis for DOS?
by on (#216566)
If I remember correctly, "Access denied" in the Win9x days implies that something else has the file open for writing.

If you have a @ECHO OFF at the top of your batch file, remove it, and you'll be able to tell what specifically is causing the error.
Re: Ophis for DOS?
by on (#216568)
I can do that, but it seems to be a call to cc65, as the error dialog box says "cc65." None of the files used by the bath file should be open, so I don't know what's causing the error. :( I will get the information now. :)
Re: Ophis for DOS?
by on (#216569)
I captured the output from the batch file, and the output file is 0k in length. :(
Re: Ophis for DOS?
by on (#216580)
asm6 1.6 also works.
Re: Ophis for DOS?
by on (#216585)
na_th_an wrote:
asm6 1.6 also works.

I'm actually using cc65 for purposes other than NES programming. I don't think C is currently good for video game programming. :(
Re: Ophis for DOS?
by on (#216608)
Harry Potter wrote:
I'm sorry, but I installed a new copy of cc65 on my Win98 computer and checked some environment variables (it appears that I already had a copy installed), and, when I ran a batch file that compiles one of my cc65 programs, the console window displays an Access Denied message, and I keep getting an Invalid Operation error dialog box. What could be the problem?


You might also check to see if any files/folders (er I mean, directories, hehe) have the read-only attribute set. I remember running into that somehow after I copied files from a CD-R.

Are there any kind of temporary directories that it uses maybe? https://www.cc65.org/bugs.php mentions c:\tmp needing to exist, but that specifically relates to ar65.

Was a long time ago, but I used to use ca65 (not cc65 though) in MS-DOS.
Re: Ophis for DOS?
by on (#216620)
Harry Potter wrote:
I'm actually using cc65 for purposes other than NES programming. I don't think C is currently good for video game programming. :(

cc65 is a collection of tools that includes an assembler (ca65), if this isn't clear. I didn't mention it to suggest you should use C instead, but because its included assembler is a good assembler for the NES.