I managed to print from my DOS application by redirecting the LPT1 port to COM1 port (MODE LPT1: = COM1:) and inside Vbox I created a Serial COM1 with RAW FILE as port mode.
The program i'm using to print from the host is Printfil which looks for this file created by the COM1 port. The problem is that the application waits the file to be unlocked to start printing and VBox only unlock the file when i close the VM instead of closing the file when there is no data being sent to the port (ie: when the printing job ends). Is there anyway to release the file without closing the VM.?? Because, otherhise, everytime I need to print, i'll have to start the print job and then close my VM to see the result.
I don't know if i was clear.
VBox locks the COM1 Raw File
-
- Site Moderator
- Posts: 39134
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: VBox locks the COM1 Raw File
You were clear enough, but ISTM VirtualBox is doing what it is supposed to do. "When the print job ends" has no meaning at a hardware level. If a port timeout caused the file to be locked it would be locked almost the moment the guest boots up.LuzWinfield wrote:VBox only unlock the file when i close the VM instead of closing the file when there is no data being sent to the port
ISTM that you're trying to use this feature in a way that wasn't intended. It sounds to me like you should be using the named pipe mode.
Alternatively, print to a local file inside the guest, and copy that to a shared folder.