Search code examples
assemblydosboxemu8086

How to pass command line parameters to Emu8086?


What I want to do is to debug my assembly code using Emu8086 by starting my program as if it was launched via command line with some parameters. Using DOSBox I launch my program like this: program.exe result.txt source.txt (result.txt and source.txt are arguments) but it does not work the way it is supposed to and I need to find out why. How does one "imitate" command line argument passing into Emu8086?


Solution

  • Start the emulator. You'll find in the emulator window the option file - set command line parameters. Here you can insert "result.txt source.txt". After that you will prompted to reload the program. Click on "Yes". You don't need to close the emulator window, when you change the code and want to debug the new version. Just click in the editor window on "emulate". The command line parameter are not changed or removed and you can debug the new version with the "old" command line parameters.