<<

P3E-T OI aktDie o CTPb T otaeAN-748 Software FTP by PC/TCP for Driver Packet SONIC DP839EB-ATS

National DP839EB-ATS SONIC Application Note 748 Packet Driver for PC/TCP January 1991 by FTP Software

INTRODUCTION This is a program listing for a driver for the DP839EB-ATS This software does not make use of higher performance SONIC Ethernet Adapter. This driver enables the DP839EB- upper level features, and performance is limited by this. ATS to operate with a TCP/IP software package from FTP The driver is listed by modules in the order listed below. Software Inc. called PC/TCP. This driver is written to ver- 1. pktdrv.c 6. sonic.h sion 2.0x of this software package. 2. far.c 7. isrlib.asm This software program listing is provided primarily as a pro- gramming example for writing software for the DP83932 3. isr.c 8. pktint.asm Systems Oriented Network Interface Controller. This driver 4. sonic.c 9. pktdrv.mak (make file) is written in C 5.1 and Microsoft Assembler 5.1. 5. pktdrv.h Since the bulk of the software is written in C, the concepts provided are easily portable to other environments. This example driver was not written to achieve optimum per- formance with PC/TCP, but primarily to show how the SON- IC Controller can be programmed.

FILENAME: pktdrv.c

TL/F/11142–1

MicrosoftÉ is a registered trademark of Microsoft Corporation. PC/TCPÉ is a registered trademark of FTP Software Inc.

C1995 Semiconductor Corporation TL/F/11142 RRD-B30M75/Printed in U. S. A. TL/F/11142–2

2 TL/F/11142–3

3 TL/F/11142–4

4 TL/F/11142–5

5 TL/F/11142–6

6 TL/F/11142–7

7 TL/F/11142–8

8 TL/F/11142–9

9 TL/F/11142–10

10 TL/F/11142–11

11 TL/F/11142–12

12 TL/F/11142–13

13 TL/F/11142–14

14 FILENAME: far.c

TL/F/11142–15

15 FILENAME: isr.c

TL/F/11142–16

16 TL/F/11142–17

17 FILENAME: sonic.c

TL/F/11142–18

18 TL/F/11142–19

19 TL/F/11142–20

20 TL/F/11142–21

21 FILENAME: pktdrv.h

TL/F/11142–22

22 TL/F/11142–23

23 FILENAME: sonic.h

TL/F/11142–24

24 TL/F/11142–25

25 TL/F/11142–26

26 FILENAME: isrlib.asm

TL/F/11142–27

27 TL/F/11142–28

28 FILENAME: pktint.asm

TL/F/11142–29

29 TL/F/11142–30

30 TL/F/11142–31

31 AN-748 DP839EB-ATS SONIC Packet Driver for PC/TCP by FTP Software IEAE pktdrv.mak FILENAME: ainlde o sueayrsosblt o s faycrutydsrbd ocrutptn iessaeipidadNtoa eevstergta n iewtotntc ocag adcrutyadspecifications. and circuitry said change to notice without time any at right the reserves National and implied are licenses patent circuit no described, circuitry any of use for responsibility any assume not does National .Lf upr eie rssesaedvcso .Aciia opnn saycmoeto life a of component any is component critical A 2. or devices are systems NATIONAL or OF SUPPORT PRESIDENT devices LIFE THE support IN OF COMPONENTS APPROVAL Life WRITTEN CRITICAL 1. EXPRESS AS herein: used THE USE As WITHOUT FOR CORPORATION. SEMICONDUCTOR SYSTEMS AUTHORIZED OR NOT DEVICES ARE PRODUCTS NATIONAL’S POLICY SUPPORT LIFE alr oprom hnpoel sdi codnespotdvc rsse,o oafc t aeyor safety its affect to life or the of system, effectiveness. failure or can the perform cause device to to failure support expected whose reasonably injury system be significant or can a device labeling, in support user. result the the to to in accordance expected provided in reasonably use whose be used for and properly life, instructions implant when sustain with or surgical perform, support to for (b) failure or intended body, are the into (a) which, systems oprto mHJpnLd ogKn t.D rzlLd.(utai)Py Ltd. Pty, (Australia) Park Business Monash Australia 3168 Victoria Melbourne Nottinghill, Ltda. Brazil Do 212-5066 (55-11) Tel: Paulo-SP Sao 05418-000 Brazil Ltd. Kong Hong 2737-1600 (852) Tel: Kowloon Tsimshatsui, 16 Building Franco Lacorda Ltd. Deputado Japan Rue Kong Hong Chiba-City, Mihama-Ku Nakase, 1-7-1, Semiconductor National 7F Bldg. Block, Straight Floor, 13th Semiconductores National 527649 Telex: 35-0 F (81-41) D-82256 Tel: Chemical Sumitomo GmbH Semiconductor National 339-9240 (910) TWX: 272-9959 Semiconductor 10 1(800) National Livry-Gargan-Str. 95052-8090 Tel: CA Clara, Santa 58090 Semiconductor Box National P.O. Drive Semiconductor 2900 Corporation Semiconductor National a:(14)3- iaPeetr 6 a:(5)23-90Tlx 9-113 SRB e:()558-9999 (3) Tel: BR NSBR 391-1131931 Telex: 2736-9960 (852) Fax: 261 Prefecture Ciba 35-1 (81-41) Fax: rtnedrc niern etrOenCnr,5Cno d 2-ABsns akDrive Park Business 120-3A Rd. Canton 5 Centre, Ocean Center Engineering 4urstenfeldbruck e:(4)2920 a:(51)2218 a:()558-9998 (3) Fax: 212-1181 (55-11) Fax: 299-2500 (043) Fax: 299-2300 (043) Tel: TL/F/11142–32