Skip to content

Commit fa12651

Browse files
author
ronybeck
committed
First commit
1 parent 7b822ad commit fa12651

796 files changed

Lines changed: 378214 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

GPL

Lines changed: 620 additions & 0 deletions
Large diffs are not rendered by default.

README

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
Short: V2.70, SANA-II network drivers for several adapters
2+
Author: Henryk Richter
3+
Uploader: henryk.richter@gmx.net
4+
Type: driver/net
5+
Architecture: m68k-amigaos
6+
Requires: OS 2.04+
7+
8+
This package contains network drivers for the following hardware:
9+
- ZII LAN IDE CP (matze, scrat and buggs @a1k.org)
10+
OSS Zorro-II card with ENC624J600 ethernet controller, autoboot
11+
IDE and Clockport
12+
- Vampire500/600 with ENC28J60 module connected to the SD-card slot
13+
- Vampire500V2+ with ENC28J60 module connected to the expansion port
14+
- VampireV4 with onboard Ethernet
15+
16+
Full source code is included. Please refer to README.sdnet and
17+
README.enc for installation and operation instructions
18+

README.enc

Lines changed: 178 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,178 @@
1+
ENC624J6Net - A SANA-II driver for the Scratze card
2+
3+
ENC624J6Net Copyright (C) 2018 Henryk Richter <henryk.richter@gmx.net>
4+
5+
This driver is supposed to support ENC624J600 based ethernet on the
6+
ZII LAN IDE CP card designed by Matze (a1k.org), Buggs (a1k.org)
7+
and Scrat (a1k.org).
8+
9+
Please see at the end of the file for information about licensing
10+
conditions.
11+
12+
13+
Installation:
14+
-------------
15+
16+
Installation of the driver is straightforward.
17+
Just copy the enc624j6net.device to devs:networks and enable
18+
the interface in your favorite TCP/IP stack as usual. There is a version
19+
for MC68020 or later (enc624j6net.device) and another version for
20+
68000 (enc624j6net.device_68000). Choose the right one.
21+
22+
So far, successful tests have been done with the free AmiTCP/IP 3.0b2,
23+
AmiTCP4.0-4.2, Genesis, MiamiDX and RoadShow.
24+
25+
The Zorro board itself should be visible in early startup with manufacturer
26+
ID 2588 and card ID 123.
27+
28+
29+
30+
Configuration options
31+
---------------------
32+
33+
No special configuration of the driver is necessary for normal operation.
34+
The configuration options outlined below are documented for tuning purposes.
35+
36+
The config to be placed in ENVARC:sana2/enc624j6net.config and consists
37+
of a single line with parameters (much like CLI parameters).
38+
39+
PRIORITY=PRI/K/N,BPS/K/N,MTU/K/N,FULLDUPLEX/S,FLOWCONTROL/S,TIMER/K/N,MULTICAST/S
40+
41+
FULLDUPLEX - change Ethernet module into full duplex mode,
42+
caution: requires manual configuration of duplex mode
43+
on the switch, too.
44+
note: this switch should not be enabled in normal cases.
45+
The module features autoconfiguration that determines
46+
speed and duplex automatically.
47+
note(2): see miitool for changing speed/duplex
48+
settings at runtime.
49+
50+
PRIORITY - server task priority (default 1)
51+
52+
BPS - bit per seconds for statistics purposes
53+
54+
MTU - maximum transmission unit (default 1500)
55+
56+
MULTICAST - (V2.3+) override fine-grained automatic multicast filtering
57+
and accept all multicast frames (default: off)
58+
59+
FLOWCONTROL - enable automatic flow control that throttles incoming
60+
data when the hardware buffer gets full
61+
62+
example (useful for DSL via PPPoE with AmiTCP):
63+
echo "MTU=1492 PRIORITY=6" >ENVARC:sana2/enc624j6net.config
64+
65+
66+
Changelog:
67+
----------
68+
69+
2.7 - fixed MuForce hit
70+
71+
2.4 - added second semaphore, specifically for the write list
72+
- recompiled using GCC 2.95 for slightly smaller binary
73+
- avoid full ethernet chip reset on startup when the
74+
registers seem to be in a sane state (faster init, especially
75+
with DHCP)
76+
- additional checks for properly built hardware:
77+
verify data bus bits before accepting card by
78+
a simple short mem test
79+
80+
2.3 - implemented fine grained multicast filter hashes
81+
82+
2.2 - some more tuning to RX/TX scheduling
83+
- added optional debug code to lowlevel routines
84+
- removed some obsolete bus transfers
85+
- uses DMACopyFromBuffer for IP-stacks supporting
86+
this capability
87+
- explicit 32 bit alignment for RX/TX to speed up
88+
ZIII transfers
89+
- added experimental support for MII interface to
90+
poll and modify speed and duplex settings on the
91+
fly
92+
- miitool added (see README.miitool)
93+
94+
2.00 - improved RX speed for buffer wraparound cases
95+
- some more safety checks for boards with unresponsive
96+
ENC chips (explicit card bus clear before verification of
97+
chip presence)
98+
- version bump
99+
100+
1.99 - fixed soft reset for ZIII firmware
101+
- re-enabled 32 Bit Buffer copies (unless Miami is active)
102+
- default server task priority for AmiTCP=6 (otherwise 0)
103+
- tuned RX/TX balancing to make RoadShow happy
104+
- added Packet Filter hook processing (needs testing)
105+
106+
1.98 - improved TX speed
107+
- precaution: soft-reset cards in detection loop to make
108+
sure that no bogus settings are left over after reset
109+
- optional: disable length check in Sana-II Device Query
110+
111+
1.97 - added New Style Device (NSD) commands
112+
- implemented SANA-II Device Query Extension
113+
114+
1.93 - recompiled using SAS/C, now 1kB smaller
115+
116+
1.91 - first Beta of completely rewritten driver
117+
- support for concurrent IP stacks
118+
- faster handling of statistics
119+
- multiple board support where applicable
120+
- workaround for Shapeshifter network plugin bug
121+
- GCC or VBCC as compiler (cross or native compilation)
122+
- faster lowlevel read/write
123+
124+
125+
Compilation / Development Notes
126+
-------------------------------
127+
128+
Either VBCC or GCC (tested with version 2.95 only) can be used for
129+
cross-compiles. General options for compiler usage can be found in
130+
Common.mk. Also, you might want to adapt the paths to your setup
131+
(PREFX,SYSINC). In addition to the regular NDK, the sana2.h is expected
132+
in the devices/ subdir of the includes. sana2.h may be found in the
133+
AmiTCP or Roadshow SDK, respectively.
134+
135+
Call
136+
137+
make -f Makefile.enc
138+
139+
for building the device.
140+
141+
VBCC note: When calling the GNU Make port supplied with ADE/GG natively on AmigaOS3,
142+
please make sure that "vc" is within the search path of "/bin/sh".
143+
144+
Native compilation is also supported for GCC and VBCC. In addition, SAS/C
145+
smakefiles are provided for the hardware targets.
146+
147+
Call
148+
149+
smake -f smakefile.enc
150+
151+
for native building with SAS/C.
152+
153+
Conceptually, the driver was meant to support multiple hardware targets. Therefore,
154+
it features a SANA-II frontend (device.c,deviceheader.c,deviceinit.c), a main
155+
server running in a task (server.c) and several hardware backends. A new hardware
156+
backend requires customized implementation of hw.c and hwprivate.h, along with
157+
additional hardware-specfic code, if needed. The device unit structure reserves
158+
three LONGS and three pointers for exclusive use by the hardware instance. Additional
159+
data for the hardware can be auto-allocated at device initialization time, if necessary.
160+
See "struct HWData" in hwprivate.h of existing backends.
161+
162+
163+
License:
164+
--------
165+
166+
This program is free software: you can redistribute it and/or modify
167+
it under the terms of the GNU General Public License as published by
168+
the Free Software Foundation, either version 3 of the License, or
169+
(at your option) any later version.
170+
171+
This program is distributed in the hope that it will be useful,
172+
but WITHOUT ANY WARRANTY; without even the implied warranty of
173+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
174+
GNU General Public License for more details.
175+
176+
You should have received a copy of the GNU General Public License
177+
along with this program. If not, see <https://www.gnu.org/licenses/>.
178+

README.miitool

Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
MIITool
2+
-------
3+
4+
This utility allows to observe and change the physical parameters
5+
of Ethernet NICs on AmigaOS. The parameters include autonegotiation
6+
settings and forced speed/duplex combinations. While it is expected
7+
that autonegotiation "just works" with modern equipment, there still
8+
are people with some interest in retro-computing who might or might
9+
not experience link-related problems or are just curious about some
10+
inner workings of everyday hardware.
11+
12+
A modern switch ("link partner") should advertise it`s capabilities
13+
properly such that the Ethernet hardware can select the optimal mode
14+
out of the supported set. If that is not the case, you can narrow down
15+
the list of advertised modes such that the link partners come to a
16+
working agreement. The last resort is to set a fixed speed/duplex
17+
combination. Please note that fixed parameters must be set at both
18+
ends of the link. Otherwise the link will work slowly or not at all.
19+
20+
None of the settings this tool applies is permanent. Changed parameters
21+
are only valid until the next reset of the NIC.
22+
23+
This utility is able to detect an active Ethernet interface in case that
24+
the RoadShow TCP/IP stack is active. Otherwise, the device needs to be
25+
passed as commandline option explicitly.
26+
27+
Examples for usage are given at the end of this text.
28+
29+
30+
Prerequisites:
31+
- AmigaOS 2.04 on 68k
32+
- active Ethernet SANA-II driver, i.e. after starting the IP-Stack
33+
34+
35+
Invocation:
36+
- MIITool is supposed to be run from CLI/Shell.
37+
38+
39+
Arguments template:
40+
DEVICE/K,UNIT/K/N,V/S,FORCEMEDIA/K,ADVERTISE/K,RENEG/S,RESET/S,VV/S
41+
42+
43+
Detailed description of arguments:
44+
45+
keyword - description
46+
------------------------
47+
DEVICE/K - device name corresponding to active ethernet interface
48+
DEV/K example: DEVICE=enc624j6net.device
49+
50+
UNIT/K/N - unit number of device to be opened (default: 0)
51+
example: UNIT=0
52+
53+
FORCEMEDIA - speed/duplex combination to set unconditionally,
54+
see below for a list of valid speed or duplex modes
55+
56+
ADVERTISE - speed/duplex combinations to announce by autonegotiation,
57+
implicitly restart autonegotiation,
58+
see below for a list of valid speed or duplex modes
59+
60+
RENEG - restart autonegotiation, please allow a couple of seconds
61+
RESTART until the negotiation is finished
62+
63+
RESET - reset PHY to power-on state
64+
65+
VERBOSE - more detailed outputs
66+
V
67+
68+
VERYVERBOSE- even more detailed outputs
69+
VV
70+
71+
72+
Valid Speed/Duplex combinations (not case sensitive):
73+
74+
10baseT-HD - 10 Mbit/s half duplex
75+
10baseT-FD - 10 Mbit/s full duplex
76+
100baseTx-HD - 100 Mbit/s half duplex over two wire pairs
77+
100baseTx-FD - 100 Mbit/s full duplex over two wire pairs (common)
78+
100baseT4 - 100 Mbit/s full duplex over 4 wire pairs (rare)
79+
10baseT - 10 Mbit/s half or full duplex
80+
10bT - 10 Mbit/s half or full duplex
81+
100baseTx - 100 Mbit/s half or full duplex
82+
100bTx - 100 Mbit/s half or full duplex
83+
84+
85+
Examples:
86+
87+
current status (detailed, autodetect)
88+
miitool v
89+
90+
current status (detailed):
91+
miitool DEV=enc624j6net.device v
92+
93+
negotiate 10 Mbit/s only
94+
miitool DEV=enc624j6net.device ADVERTISE=10bT
95+
96+
negotiate 100baseTx and 10baseT half duplex only:
97+
miitool DEV=enc624j6net.device ADVERTISE=100bTx,10baseT-HD
98+
99+
force 100 Mbit/s full duplex
100+
miitool DEV=enc624j6net.device FORCEMEDIA=100baseTx-FD
101+

0 commit comments

Comments
 (0)