2 .\" $FreeBSD: src/share/man/man4/man4.i386/cx.4,v 1.7.2.6 2001/08/17 13:08:45 ru Exp $
9 .Nd asynchronous/synchronous Cronyx-Sigma adapter driver
11 .Cd "device cx0 at isa? port 0x240 irq 15 drq 7"
12 .Cd "device cx1 at isa? port 0x260 irq 12 drq 6"
13 .Cd pseudo-device sppp
15 The base i/o port address should be set by jumpers on the board.
16 The DMA i/o channel and interrupt request numbers are configured
17 by software at adapter initialization. Legal values are:
19 .Bl -tag -compact -width Port
21 0x240, 0x260, 0x280, 0x300, 0x320, 0x380
23 3, 5, 7, 10, 11, 12, 15
28 The Cronyx-Sigma driver supports the adapters of models 100,
29 400, 500, 401, 404, 410, 440, 703, 801, 810, 840. Different models have
30 different set of channels:
32 .Bl -tag -compact -width Cronyx-Sigma-999
52 0, 1, 2, 3, 4, 5, 6, 7
54 0, 1, 2, 3, 4, 5, 6, 7
56 0, 1, 2, 3, 4, 5, 6, 7
59 A pair of two adapters can be united together by the special
60 short inter-board cable. Two united adapters use the same
61 IRQ and DMA channels and from the point of driver works
62 as the single 16-channel multiplexer. One of the united
63 boards is ``master'' and the other is ``slave''.
65 The channels of the slave united board are numbered by the driver
66 beginning with 8, for example, the united adapter of the model 100/500
67 has channels 0, 8, 12, 13, 14, 15.
69 The channels which have the RS-232 interface can be used
70 both in synchronous and asynchronous modes (software selectable
71 by cxconfig utility) and hence are called ``universal'' channels.
73 The special device files,
75 for the adapter Cronyx-Sigma
81 sh MAKEDEV cronyx ttyx0 ttyx1 ttyy0
83 .Sh "Asynchronous driver"
84 The asynchronous channel device files have the names:
91 Here # is the channel number in hexadecimal form, 0-9-a-f.
93 The driver fulfills the following standard ioctl requests (see
96 .Bl -tag -width TIOCXXXXX -compact
102 Set DTR signal (DTR := 1). The DTR signal is always set
105 and could be changed by
113 Clear DTR signal (DTR := 0).
115 Set the given values of DTR and RTS signals (<DTR:RTS> := data).
116 The signals DTR and RTS are controlled by
120 bits of the data argument of the ioctl system call.
122 Set DTR and RTS signals (<DTR:RTS> |= data).
123 The signals DTR and RTS are controlled by
127 bits of the data argument of the ioctl system call.
129 Clear DTR and RTS signals (<DTR:RTS> &= ~data).
130 The signals DTR and RTS are controlled by
134 bits of the data argument of the ioctl system call.
136 Determine the state of the modem signals of the line.
137 After the call the data argument contains the following bits:
139 .Bl -tag -width TIOCM_XXX -compact
141 always set (Line Enabled)
143 Data Set Ready signal received
145 Clear To Send signal received
147 Data Carrier Detect signal received
149 Data Terminal Ready signal transmitted
151 Request To Send signal transmitted
154 .Sh "Synchronous driver"
155 The synchronous channels and universal channels, turned to the synchronous
158 utility, are accessible as network
159 interfaces named ``cx#'' where # is the channel number, 0..47.
160 All standard network interface parameters could be set by
165 command is used to change some extended channel
166 options, and also for setting the high-level software protocol
167 (e.g. PpP or Cisco HDLC).
169 The universal channels could be used both in asynchronous and synchronous modes.
170 By default the asynchronous mode is set.
171 The mode could be changed by
174 The mode is blocked while the channel is busy (an asynchronous channel
175 in open state or the network interface is up).
176 .Sh "Synchronous Point-to-Point protocol"
177 The Cronyx-Sigma driver uses the built-in implementation of the synchronous
178 Point-to-Point protocol (sppp). It includes the support for such
179 protocols as PpP/HDLC and Cisco/HDLC, and also the automatic
180 connection loss test (via keepalive packets).
181 The sppp protocol set is implemented as an independent module
182 and could be used by other drivers of synchronous serial channels.
183 The version of the driver for BSD/386 (BSDI) operating system
184 also supports the usage of the general set of synchronous
185 protocols, implemented inside the OS.
186 The external protocol set could be selected by ``cxconfig ext'' command
189 .Sh "Channel Options Management"
192 utility is used for setting the channels options.
193 The channel options are generally set at the start of the operating
194 system (for example, from the file
196 Note, that not all options have a sense for every particular
197 case, and an attempt to set some of them can hang up the channel or
200 The actual channel options control functions are implemented via
201 the ioctl-s on the special device file /dev/cronyx.
202 There are the following ioctl-s available:
204 .Bl -tag -width CXIOCXXXXXXX -compact
206 Get the channel option values.
208 Set the channel option values.
211 The data argument of the ioctl call has an address of the options structure:
214 unsigned char board; /* adapter number, 0..2 */
215 unsigned char channel; /* channel number, 0..15 */
216 unsigned char type; /* channel type (read only) */
217 unsigned char iftype; /* chan0 interface */
218 unsigned long rxbaud; /* receiver speed */
219 unsigned long txbaud; /* transmitter speed */
220 cx_chan_mode_t mode; /* channel mode */
221 cx_chan_opt_t opt; /* common channel options */
222 cx_opt_async_t aopt; /* async mode options */
223 cx_opt_hdlc_t hopt; /* hdlc mode options */
224 cx_opt_bisync_t bopt; /* bisync mode options */
225 cx_opt_x21_t xopt; /* x.21 mode options */
226 cx_soft_opt_t sopt; /* software options and state flags */
227 } cx_options_t; /* user settable options */
230 .Bl -tag -width rxbaudxxx
232 The adapter number, 0..2.
234 The channel number, 0..15.
236 The type of the channel (read-only argument).
238 The interface type of the zero (and also the eight) channel: 0 - RS-232,
241 The receiver data baud rate.
243 The transmitter data baud rate.
245 The channel mode: asynchronous/HDLC/Bisync/X.21.
247 The general channel options.
249 The asynchronous mode options.
251 The HDLC mode options.
253 The Bisync mode options.
255 The X.21 mode options.
257 The software protocol options.
260 .Bl -tag -width /dev/cxXXXX -compact
262 Asynchronous channels.
264 The special device file for the channel options management.
267 The sources for the driver reside in:
269 .Bl -tag -width /dev/cxXXXX -compact
270 .It Pa /sys/i386/isa/cronyx.c
271 .It Pa /sys/i386/isa/cx.c
272 .It Pa /sys/i386/isa/if_cx.c
273 .It Pa /sys/i386/isa/cronyx.h
274 .It Pa /sys/i386/isa/cxreg.h
275 .It Pa /sys/net/if_spppsubr.c
276 .It Pa /sys/net/if_sppp.h