⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 z8530drv.txt

📁 《嵌入式系统设计与实例开发实验教材二源码》Linux内核移植与编译实验
💻 TXT
📖 第 1 页 / 共 2 页
字号:
You can now axattach a pseudo-TTY:	axattach /dev/ptys0 axlinkand start your NOS and attach /dev/ptys0 there. The problem is thatNOS is reachable only via digipeating through the kernel AX.25(disastrous on a DAMA controlled channel). To solve this problem,configure "rxecho" to echo the incoming frames from "9k6" to "axlink"and outgoing frames from "axlink" to "9k6" and start:	rxechoOr simply use "kissbridge" coming with z8530drv-utils:	ifconfig scc3 hw ax25 dl0tha-9	kissbridge scc3 /dev/ptys03. Adjustment and Display of parameters=======================================3.1 Displaying SCC Parameters:==============================Once a SCC channel has been attached, the parameter settings and some statistic information can be shown using the param program:dl1bke-u:~$ sccstat scc0Parameters:speed       : 1200 baudtxdelay     : 36persist     : 255slottime    : 0txtail      : 8fulldup     : 1waittime    : 12mintime     : 3 secmaxkeyup    : 7 secidletime    : 3 secmaxdefer    : 120 secgroup       : 0x00txoff       : offsoftdcd     : onSLIP        : offStatus:HDLC                  Z8530           Interrupts         Buffers-----------------------------------------------------------------------Sent       :     273  RxOver :     0  RxInts :   125074  Size    :  384Received   :    1095  TxUnder:     0  TxInts :     4684  NoSpace :    0RxErrors   :    1591                  ExInts :    11776TxErrors   :       0                  SpInts :     1503Tx State   :    idleThe status info shown is:Sent		- number of frames transmittedReceived	- number of frames receivedRxErrors	- number of receive errors (CRC, ABORT)TxErrors	- number of discarded Tx frames (due to various reasons) Tx State	- status of the Tx interrupt handler: idle/busy/active/tail (2)RxOver		- number of receiver overrunsTxUnder		- number of transmitter underrunsRxInts		- number of receiver interruptsTxInts		- number of transmitter interruptsEpInts		- number of receiver special condition interruptsSpInts		- number of external/status interruptsSize		- maximum size of an AX.25 frame (*with* AX.25 headers!)NoSpace		- number of times a buffer could not get allocatedAn overrun is abnormal. If lots of these occur, the product ofbaudrate and number of interfaces is too high for the processingpower of your computer. NoSpace errors are unlikely to be caused by thedriver or the kernel AX.25.3.2 Setting Parameters======================The setting of parameters of the emulated KISS TNC is done in the same way in the SCC driver. You can change parameters by usingthe kissparms program from the ax25-utils package or use the program "sccparam":     sccparam <device> <paramname> <decimal-|hexadecimal value>You can change the following parameters:param	    : value------------------------speed       : 1200txdelay     : 36persist     : 255slottime    : 0txtail      : 8fulldup     : 1waittime    : 12mintime     : 3maxkeyup    : 7idletime    : 3maxdefer    : 120group       : 0x00txoff       : offsoftdcd     : onSLIP        : offThe parameters have the following meaning:speed:     The baudrate on this channel in bits/sec     Example: sccparam /dev/scc3 speed 9600txdelay:     The delay (in units of 10 ms) after keying of the      transmitter, until the first byte is sent. This is usually      called "TXDELAY" in a TNC.  When 0 is specified, the driver      will just wait until the CTS signal is asserted. This      assumes the presence of a timer or other circuitry in the      MODEM and/or transmitter, that asserts CTS when the      transmitter is ready for data.     A normal value of this parameter is 30-36.     Example: sccparam /dev/scc0 txd 20persist:     This is the probability that the transmitter will be keyed      when the channel is found to be free.  It is a value from 0      to 255, and the probability is (value+1)/256.  The value      should be somewhere near 50-60, and should be lowered when      the channel is used more heavily.     Example: sccparam /dev/scc2 persist 20slottime:     This is the time between samples of the channel. It is      expressed in units of 10 ms.  About 200-300 ms (value 20-30)      seems to be a good value.     Example: sccparam /dev/scc0 slot 20tail:     The time the transmitter will remain keyed after the last      byte of a packet has been transferred to the SCC. This is      necessary because the CRC and a flag still have to leave the      SCC before the transmitter is keyed down. The value depends      on the baudrate selected.  A few character times should be      sufficient, e.g. 40ms at 1200 baud. (value 4)     The value of this parameter is in 10 ms units.     Example: sccparam /dev/scc2 4full:     The full-duplex mode switch. This can be one of the following      values:     0:   The interface will operate in CSMA mode (the normal           half-duplex packet radio operation)     1:   Fullduplex mode, i.e. the transmitter will be keyed at           any time, without checking the received carrier.  It           will be unkeyed when there are no packets to be sent.     2:   Like 1, but the transmitter will remain keyed, also           when there are no packets to be sent.  Flags will be           sent in that case, until a timeout (parameter 10)           occurs.     Example: sccparam /dev/scc0 fulldup offwait:     The initial waittime before any transmit attempt, after the      frame has been queue for transmit.  This is the length of      the first slot in CSMA mode.  In full duplex modes it is     set to 0 for maximum performance.     The value of this parameter is in 10 ms units.      Example: sccparam /dev/scc1 wait 4maxkey:     The maximal time the transmitter will be keyed to send      packets, in seconds.  This can be useful on busy CSMA      channels, to avoid "getting a bad reputation" when you are      generating a lot of traffic.  After the specified time has      elapsed, no new frame will be started. Instead, the trans-     mitter will be switched off for a specified time (parameter      min), and then the selected algorithm for keyup will be      started again.     The value 0 as well as "off" will disable this feature,      and allow infinite transmission time.      Example: sccparam /dev/scc0 maxk 20min:     This is the time the transmitter will be switched off when      the maximum transmission time is exceeded.     Example: sccparam /dev/scc3 min 10idle     This parameter specifies the maximum idle time in full duplex      2 mode, in seconds.  When no frames have been sent for this      time, the transmitter will be keyed down.  A value of 0 is     has same result as the fullduplex mode 1. This parameter     can be disabled.     Example: sccparam /dev/scc2 idle off	# transmit forevermaxdefer     This is the maximum time (in seconds) to wait for a free channel     to send. When this timer expires the transmitter will be keyed      IMMEDIATELY. If you love to get trouble with other users you     should set this to a very low value ;-)     Example: sccparam /dev/scc0 maxdefer 240	# 2 minutestxoff:     When this parameter has the value 0, the transmission of packets     is enable. Otherwise it is disabled.     Example: sccparam /dev/scc2 txoff ongroup:     It is possible to build special radio equipment to use more than      one frequency on the same band, e.g. using several receivers and      only one transmitter that can be switched between frequencies.     Also, you can connect several radios that are active on the same      band.  In these cases, it is not possible, or not a good idea, to      transmit on more than one frequency.  The SCC driver provides a      method to lock transmitters on different interfaces, using the      "param <interface> group <x>" command.  This will only work when      you are using CSMA mode (parameter full = 0).     The number <x> must be 0 if you want no group restrictions, and      can be computed as follows to create restricted groups:     <x> is the sum of some OCTAL numbers:     200  This transmitter will only be keyed when all other           transmitters in the group are off.     100  This transmitter will only be keyed when the carrier           detect of all other interfaces in the group is off.     0xx  A byte that can be used to define different groups.            Interfaces are in the same group, when the logical AND           between their xx values is nonzero.     Examples:     When 2 interfaces use group 201, their transmitters will never be      keyed at the same time.     When 2 interfaces use group 101, the transmitters will only key      when both channels are clear at the same time.  When group 301,      the transmitters will not be keyed at the same time.     Don't forget to convert the octal numbers into decimal before     you set the parameter.     Example: (to be written)softdcd:     use a software dcd instead of the real one... Useful for a very     slow squelch.     Example: sccparam /dev/scc0 soft on4. Problems ===========If you have tx-problems with your BayCom USCC card please checkthe manufacturer of the 8530. SGS chips have a slightlydifferent timing. Try Zilog...  A solution is to write to register 8 instead to the data port, but this won't work with the ESCC chips. *SIGH!*A very common problem is that the PTT locks until the maxkeyup timerexpires, although interrupts and clock source are correct. In mostcases compiling the driver with CONFIG_SCC_DELAY (set withmake config) solves the problems. For more hints read the (pseudo) FAQ and the documentation coming with z8530drv-utils.I got reports that the driver has problems on some 386-based systems.(i.e. Amstrad) Those systems have a bogus AT bus timing which willlead to delayed answers on interrupts. You can recognize theseproblems by looking at the output of Sccstat for the suspectedport. If it shows under- and overruns you own such a system.Delayed processing of received data: This depends on- the kernel version- kernel profiling compiled or not- a high interrupt load- a high load of the machine --- running X, Xmorph, XV and Povray,  while compiling the kernel... hmm ... even with 32 MB RAM ...  ;-)  Or running a named for the whole .ampr.org domain on an 8 MB  box...- using information from rxecho or kissbridge.Kernel panics: please read /linux/README and find out if itreally occurred within the scc driver.If you cannot solve a problem, send me- a description of the problem,- information on your hardware (computer system, scc board, modem)- your kernel version- the output of cat /proc/net/z85304. Thor RLC100==============Mysteriously this board seems not to work with the driver. Anyonegot it up-and-running?Many thanks to Linus Torvalds and Alan Cox for including the driverin the Linux standard distribution and their support.Joerg Reuter	ampr-net: dl1bke@db0pra.ampr.org		AX-25   : DL1BKE @ DB0ABH.#BAY.DEU.EU		Internet: jreuter@yaina.de		WWW     : http://yaina.de/jreuter

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -