1 diff -Nur dosemu-1.4.0.orig/etc/dosemu.conf dosemu-1.4.0.chng/etc/dosemu.conf
2 --- dosemu-1.4.0.orig/etc/dosemu.conf 2008-01-29 09:04:59.000000000 +0100
3 +++ dosemu-1.4.0.chng/etc/dosemu.conf 2008-01-29 10:55:17.000000000 +0100
5 # $_lpt2 = "lpr -l -P lpt2"
8 +# Thought: even if you have fourth lpt port available you cannot access it by
9 +# LPT4 name but is available to use at 0x2BC port.
12 # idle time in seconds before spooling out. Default: (20)
14 # $_printer_timeout = (20)
15 diff -Nur dosemu-1.4.0.orig/etc/global.conf dosemu-1.4.0.chng/etc/global.conf
16 --- dosemu-1.4.0.orig/etc/global.conf 2006-11-29 11:05:27.000000000 +0100
17 +++ dosemu-1.4.0.chng/etc/global.conf 2008-01-29 09:36:58.000000000 +0100
21 if (1) # no idea why but we need this...
22 - foreach $xxx (" ", "1 2 3")
23 + foreach $xxx (" ", "1 2 3 4")
27 diff -Nur dosemu-1.4.0.orig/src/base/bios/setup.c dosemu-1.4.0.chng/src/base/bios/setup.c
28 --- dosemu-1.4.0.orig/src/base/bios/setup.c 2007-05-04 07:59:48.000000000 +0200
29 +++ dosemu-1.4.0.chng/src/base/bios/setup.c 2008-01-29 10:01:34.000000000 +0100
32 CONF_NFLOP(configuration, config.fdisks);
33 CONF_NSER(configuration, config.num_ser);
34 + if (config.num_lpt > 3) config.num_lpt = 3;
35 CONF_NLPT(configuration, config.num_lpt);
36 if (config.mouse.intdrv)
37 configuration |= CONF_MOUSE;
38 diff -Nur dosemu-1.4.0.orig/src/base/dev/misc/lpt.c dosemu-1.4.0.chng/src/base/dev/misc/lpt.c
39 --- dosemu-1.4.0.orig/src/base/dev/misc/lpt.c 2007-05-04 07:59:48.000000000 +0200
40 +++ dosemu-1.4.0.chng/src/base/dev/misc/lpt.c 2008-01-29 09:25:25.000000000 +0100
43 {NULL, NULL, 5, 0x378, .status = LPT_NOTBUSY | LPT_ONLINE | LPT_IOERR | LPT_ACK},
44 {NULL, NULL, 5, 0x278, .status = LPT_NOTBUSY | LPT_ONLINE | LPT_IOERR | LPT_ACK},
45 - {NULL, NULL, 10, 0x3bc, .status = LPT_NOTBUSY | LPT_ONLINE | LPT_IOERR | LPT_ACK}
46 + {NULL, NULL, 10, 0x3bc, .status = LPT_NOTBUSY | LPT_ONLINE | LPT_IOERR | LPT_ACK},
47 + {NULL, NULL, 10, 0x2bc, .status = LPT_NOTBUSY | LPT_ONLINE | LPT_IOERR | LPT_ACK}
50 static int get_printer(ioport_t port)
53 - for (i = 0; i < 3; i++)
54 + for (i = 0; i < NUM_PRINTERS; i++)
55 if (lpt[i].base_port <= port && port <= lpt[i].base_port + 2)
59 io_device.irq = EMU_NO_IRQ;
62 - for (i = 0; i < 3; i++) {
63 + for (i = 0; i < NUM_PRINTERS; i++) {
64 p_printf("LPT: initializing printer %s\n", lpt[i].dev ? lpt[i].dev : "<<NODEV>>");
66 lpt[i].remaining = -1; /* mark not accessed yet */
67 diff -Nur dosemu-1.4.0.orig/src/doc/README/config dosemu-1.4.0.chng/src/doc/README/config
68 --- dosemu-1.4.0.orig/src/doc/README/config 2007-05-05 06:22:31.000000000 +0200
69 +++ dosemu-1.4.0.chng/src/doc/README/config 2008-01-29 10:55:40.000000000 +0100
70 @@ -1143,14 +1143,19 @@
73 # Print commands to use for LPT1, LPT2 and LPT3.
74 -# Default: "lpr -l, lpr -l -P lpt2, lpr -l P lpt3"
75 +# Default: "lpr -l, lpr -l -P lpt2, lpr -l P lpt3, lpr -l P lpt4"
76 # Which means: use the default print queue for LPT1, "lpt2" queue for LPT2,
77 -# "lpt3" queue for LPT3. "-l" means raw printing mode (no preprocessing).
78 +# "lpt3" queue for LPT3, "lpt4" queue for LPT4.
79 +# "-l" means raw printing mode (no preprocessing).
82 $_lpt2 = "lpr -l -P lpt2"
83 $_lpt3 = "lpr -l -P lpt3"
85 +# Thought: even if you have fourth lpt port available you cannot access it by
86 +# LPT4 name but is available to use at 0x2BC port.
87 +$_lpt4 = "lpr -l -P lpt4"
89 $_printer_timeout = (20)# idle time in seconds before spooling out
92 diff -Nur dosemu-1.4.0.orig/src/doc/README/config-tech dosemu-1.4.0.chng/src/doc/README/config-tech
93 --- dosemu-1.4.0.orig/src/doc/README/config-tech 2003-08-20 00:15:06.000000000 +0200
94 +++ dosemu-1.4.0.chng/src/doc/README/config-tech 2008-01-29 09:19:04.000000000 +0100
95 @@ -3366,11 +3366,11 @@
99 -NOTE: Printers are assigned to LPT1:, LPT2:, and LPT3: on a one for
100 +NOTE: Printers are assigned to LPT1:, LPT2:, LPT3: and LPT4 on a one for
101 one basis with each line below. The first printer line is assigned
102 -to LPT1:, second to LPT2:, and third to LPT3:. If you do not specify
103 -a base port, the emulator will setup the bios to report 0x378, 0x278,
104 -and 0x3bc for LPT1:, LPT2:, and LPT3: respectively.
105 +to LPT1:, second to LPT2:, third to LPT3: and fourth to LPT4. If you
106 +do not specify a base port, the emulator will setup the bios to report
107 +0x378, 0x278, 0x3bc and 0x2bc for LPT1:, LPT2:, LPT3: and LPT4: respectively.
111 diff -Nur dosemu-1.4.0.orig/src/include/bios.h dosemu-1.4.0.chng/src/include/bios.h
112 --- dosemu-1.4.0.orig/src/include/bios.h 2007-05-04 07:59:48.000000000 +0200
113 +++ dosemu-1.4.0.chng/src/include/bios.h 2008-01-29 09:11:43.000000000 +0100
115 #define BIOS_ADDRESS_LPT1 0x408
116 #define BIOS_ADDRESS_LPT2 0x40a
117 #define BIOS_ADDRESS_LPT3 0x40c
118 +#define BIOS_ADDRESS_LPT4 0x40e
119 /* 0x40e is reserved */
120 #define BIOS_CONFIGURATION 0x410
121 /* 0x412 is reserved */
123 #define BIOS_LPT1_TIMEOUT 0x478
124 #define BIOS_LPT2_TIMEOUT 0x479
125 #define BIOS_LPT3_TIMEOUT 0x47a
126 +#define BIOS_LPT4_TIMEOUT 0x47b
127 /* 0x47b is reserved */
128 #define BIOS_COM1_TIMEOUT 0x47c
129 #define BIOS_COM2_TIMEOUT 0x47d
130 diff -Nur dosemu-1.4.0.orig/src/include/lpt.h dosemu-1.4.0.chng/src/include/lpt.h
131 --- dosemu-1.4.0.orig/src/include/lpt.h 2007-05-04 07:59:48.000000000 +0200
132 +++ dosemu-1.4.0.chng/src/include/lpt.h 2008-01-29 09:14:17.000000000 +0100
135 #define LPT_NOTBUSY 0x80
137 -#define NUM_PRINTERS 3
138 +#define NUM_PRINTERS 4
139 extern struct printer lpt[NUM_PRINTERS];