China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --

Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
DOS stands for freedom, openness and progress. Let us work hard, learn from the openness and GNU spirit of FreeDOS and Linux, and together build and grow a free GNU GPL world!

中国DOS联盟论坛
The time now is 2026-08-01 11:00
中国DOS联盟论坛 » DOS开发编程 & 发展交流 (开发室) » Help with DOS network programming (winsail) View 3,838 Replies 34
Floor 16 Posted 2008-01-16 18:52 ·  中国 江苏 南京 电信
初级用户
Credits 100
Posts 41
Joined 2007-12-06 15:52
18-year member
UID 104858
Gender Male
Status Offline
Changed back to "c:\intel\netbind.com", run debug test, after d180, no "xxxx:0183H" appeared, and no "PKT DRVR" characters on the right;
Protocol.ini is
[protman]
drivername=PROTMAN$

[pktdrv]
drivername=PKTDRV$
bindings=nic
intvec=0x60
chainvec=0x66

[nic]
DriverName=RTSND$
;MaxMultiCasts=10
;TxBuffers=4
;RxBuffers=4
;Medium=_100Full

Test environment is DOS

Regarding the problem of print output, the "InitSystem()" function has been executed
Floor 17 Posted 2008-01-16 19:05 ·  中国 江苏 南京 电信
初级用户
Credits 100
Posts 41
Joined 2007-12-06 15:52
18-year member
UID 104858
Gender Male
Status Offline
So it means my network card driver definitely hasn't started.
Floor 18 Posted 2008-01-16 19:06 ·  中国 江苏 南京 电信
初级用户
Credits 100
Posts 41
Joined 2007-12-06 15:52
18-year member
UID 104858
Gender Male
Status Offline
Then ask another question, how to set the network IP address under DOS
Floor 19 Posted 2008-01-16 19:09 ·  中国 广东 深圳 电信
高级用户
★★
Credits 668
Posts 295
Joined 2005-07-26 00:00
21-year member
UID 41110
Gender Male
From 广东深圳
Status Offline
Is there the simplest way to check if "Packet Driver" is loaded successfully? It is to use the debug program to check whether the content of the 60H interrupt vector has the string "PKT DRVR".

(1) The first step, execute "Debug" under the DOS command line.
(2) The second step, type "d180" and press Enter.
(3) The third step, pay attention to the consecutive four bytes jj kk mm nn indicated by xxxx:0180. If it is 00 00 00 00, it is not loaded successfully; otherwise, the fourth step.

(4) The fourth step, type d nnmm:kkjj and press Enter (note: nn mm kk jj is the result of the third step).
(5) The fifth step, check whether there is the string "PKT DRVR" on the right side of the screen. If there is, it is loaded successfully; otherwise, it is not loaded successfully.

Originally posted by tianmian at 2008-1-16 19:06:
Another question, how to set the network IP address under DOS


In the private Config.Sys file of WinSail, specify the key value "My_IP" in the "Netcard" section.


My_IP = 169.254.82.133

[ Last edited by firstsail on 2008-1-16 at 07:15 PM ]
Floor 20 Posted 2008-01-16 19:14 ·  中国 江苏 南京 电信
初级用户
Credits 100
Posts 41
Joined 2007-12-06 15:52
18-year member
UID 104858
Gender Male
Status Offline
d180 does not indeed show the PKT DRVR word on the right, but there are prompts like Ethernet address 00e04cf... etc. when booting.
Floor 21 Posted 2008-01-16 19:18 ·  中国 广东 深圳 电信
高级用户
★★
Credits 668
Posts 295
Joined 2005-07-26 00:00
21-year member
UID 41110
Gender Male
From 广东深圳
Status Offline
The simplest way to check if "Packet Driver" is loaded successfully is to use the debug program to check if the content of the 60H interrupt vector has the string "PKT DRVR".

(1) The first step is to execute "Debug" under the DOS command line.
(2) The second step is to type "d180" and press Enter.
(3) The third step is to pay attention to the consecutive four bytes jj kk mm nn indicated by xxxx:0180. If it is 00 00 00 00, it is not loaded successfully; otherwise, the fourth step.

(4) The fourth step is to type d nnmm:kkjj and press Enter (note: nn mm kk jj is the result in the third step).
(5) The fifth step is to check if there is the string "PKT DRVR" on the right side of the screen. If yes, it is loaded successfully; otherwise, it is not loaded successfully.

Quote:
Originally posted by tianmian at 2008-1-16 19:06:
Ask another question, how to set the network IP address under DOS


In the private Config.Sys file of WinSail, specify the "My_IP" key value in the "Netcard" segment

[Netcard]
My_IP = 169.254.82.133
Floor 22 Posted 2008-01-16 19:18 ·  中国 江苏 南京 电信
初级用户
Credits 100
Posts 41
Joined 2007-12-06 15:52
18-year member
UID 104858
Gender Male
Status Offline
So it seems that the network card driver was not loaded successfully, because the positions of jj, kk, mm, nn are all 0
Floor 23 Posted 2008-01-16 19:21 ·  中国 广东 深圳 电信
高级用户
★★
Credits 668
Posts 295
Joined 2005-07-26 00:00
21-year member
UID 41110
Gender Male
From 广东深圳
Status Offline
Originally posted by tianmian at 2008-1-16 19:14:
The d180 does not indeed show the "PKT DRVR" on the right, but there are prompts like "Ethernet address 00e04cf..." during startup.


(1) Displaying the NIC address can only indicate that the NDIS driver is loaded.
(2) Only after executing the NetBind.Com program can the NDIS be truly converted into a Packet driver. Note that the Protman.Exe and NetBind.Com files must be in the same directory.

NDIS driver is a network protocol interface standard proposed by Microsoft.
Packet driver is a network protocol interface standard proposed by xxxx company.
IPX driver is a network protocol interface standard proposed by Novel company.

[ Last edited by firstsail on 2008-1-18 at 09:58 AM ]
Floor 24 Posted 2008-01-16 19:25 ·  中国 江苏 南京 电信
初级用户
Credits 100
Posts 41
Joined 2007-12-06 15:52
18-year member
UID 104858
Gender Male
Status Offline
Then the problem should be with netbind. How to solve it
Floor 25 Posted 2008-01-16 19:26 ·  中国 广东 深圳 电信
高级用户
★★
Credits 668
Posts 295
Joined 2005-07-26 00:00
21-year member
UID 41110
Gender Male
From 广东深圳
Status Offline
If you are using an 8139 network card, you can directly execute "RtsPkt.Com 0x60" in the DOS command line to load the Packet driver. You can find this file in the Sail3000\Internet\Other directory. If the loading is successful, the NIC address xx:xx:xx:xx:xx will be displayed, and then try the "QQ Chat Room" of Sail3000.

[ Last edited by firstsail on 2008-1-16 at 07:30 PM ]
Floor 26 Posted 2008-01-16 19:31 ·  中国 江苏 南京 电信
初级用户
Credits 100
Posts 41
Joined 2007-12-06 15:52
18-year member
UID 104858
Gender Male
Status Offline
Can such a thing be loaded into autoexec.bat? I'm using a realteck 8139 network card. Why does it go wrong when I load it according to the parcket driver instruction file you provided?
Floor 27 Posted 2008-01-16 19:40 ·  中国 广东 深圳 电信
高级用户
★★
Credits 668
Posts 295
Joined 2005-07-26 00:00
21-year member
UID 41110
Gender Male
From 广东深圳
Status Offline
Originally posted by tianmian at 2008-1-16 19:31:
Can such a thing be loaded into autoexec.bat? I'm using a realteck 8139 network card. Why does it go wrong when I follow the loading instructions in the parcket driver instruction file?


If you directly execute "Rtspkt.Com", then modify Config.Sys and "autoexec.bat" in the root directory of drive C as follows

The Config.Sys file is as follows

device=c:\windows\himem.sys/testmem:off
device=c:\windows\emm386.exe noems novcpi
rem devicehigh=c:\intel\protman.dos /i:c:\intel\RTL81xx
rem devicehigh=c:\intel\dis_pkt.dos
rem devicehigh=c:\intel\RTL81xx\Rtsnd.dos
dos=high,umb
stacks=12,256
files=30


The autoexec.bat file is as follows:
path c:\windows;c:\windows\command
lh smartdrv
rem c:\intel\netbind.com
lh c:\sail3000\internet\other\rtspkt 0x60

Please modify the directory where the above rtspkt.com file is located according to the actual situation

[ Last edited by firstsail on 2008-1-16 at 07:41 PM ]
Floor 28 Posted 2008-01-16 19:54 ·  中国 江苏 南京 电信
初级用户
Credits 100
Posts 41
Joined 2007-12-06 15:52
18-year member
UID 104858
Gender Male
Status Offline
I removed all the network card configuration in config.sys, and sail3000 ran successfully; There is a question: After loading winsail, can't use the printf function? I feel that winsail is not very stable, and the program works sometimes and sometimes not.
Floor 29 Posted 2008-01-16 20:01 ·  中国 广东 深圳 电信
高级用户
★★
Credits 668
Posts 295
Joined 2005-07-26 00:00
21-year member
UID 41110
Gender Male
From 广东深圳
Status Offline
Originally posted by tianmian at 2008-1-16 19:54:
I removed all the network card configuration in config.sys, and sail3000 ran successfully;
There is a question, can't you use the printf function after loading winsail? I feel that winsail is not very stable, and the program works sometimes and sometimes not




To use network functions, the system memory should be at least "8M" or more


The printf function can be used in 16-color mode, but it cannot be used in 256-color mode. The graphic mode display function ChPrintf() can be used instead.
All Chinese displays in WinSail are implemented by calling the ChPrintf() function



(1) Display "I am learning WinSail" at x = 100, y = 50 on the screen with white stroke, red background, and text magnification factor of 1 time, then
::ChPrintf(100, 50, WHITE, RED, 1, 1, "I am learning WinSail");

(2) Display "I am learning WinSail" at x = 100, y = 50 on the screen with white stroke, transparent background, and text magnification factor of 1 time, then
::ChPrintf(100, 50, WHITE, RED, 1, 0, "I am learning WinSail now");

(3) Display "I am learning WinSail" at x = 100, y = 50 on the screen with white stroke, red background, and text magnification factor of 2 times, then
::ChPrintf(100, 50, WHITE, RED, 2, 1, "I am learning WinSail");

[ Last edited by firstsail on 2008-1-16 at 08:08 PM ]
Floor 30 Posted 2008-01-16 20:05 ·  中国 广东 深圳 电信
高级用户
★★
Credits 668
Posts 295
Joined 2005-07-26 00:00
21-year member
UID 41110
Gender Male
From 广东深圳
Status Offline
(1) Before executing WinSail, you should not execute UCDOS, Pdos95, etc.
(2) To save memory, do not execute the smartdrv.exe program in Autoexec.bat.
(3) You cannot execute WinSail in the Bc31 integrated environment.
(4) After booting into DOS, type "mem/c/p" in the DOS command to check the size of conventional memory. It is best to have more than "550K".
[ Last edited by firstsail on 2008-1-16 at 08:14 PM ]
Forum Jump: