HP UX 11i v1 I/O Cards manual 272

Page 272

ZCOM C I/F Library Routines

ZREAD (3X)

2.If the received message (or response) is from a terminal, the request code is returned in mhp->mrq.mrqcode. The request code and the returned status may be used to retrieve an appropriate status/error message by zcomstatus(3X). Refer to Appendix B ZCOM Status Codes of the Multiprotocol ACC Programmers’ Reference Guide for more information. The mhp->mrq.mrqcodefield contains 0 if the message is from a program or is a System Event Message (SEM).

3.A System Event Message (SEM) is generated by the ZCOM subsystem in response to special events that occur within the ZCOM subsystem. A program may choose to receive event messages by supplying its primary ZLU in a zevent_rcvr call. All ZCOM Event messages are divided into a header and event specific data section. The header is defined for all types of Event messages while the data portion depends on the ZCOM Event Message type. Refer to the subsection ‘System Event Messages’ in the Multiprotocol ACC Programmers’ Reference Guide for more information. The SEM’s structure is defined in /opt/acc/include/zcom/zcomsys.h.

4.The tag parameters (mhp->mid.mtagw1and mtagw2) are the tag parameters from the originating zsend(3X) call.

5.The type of message received is returned in mhp->mid.mstype. Its values are as follows (defined in /opt/acc/include/zcom/zcomsys.h):

#define ZCOM_MSTYPE_REMOTE

0x08

/* Mask for remote message bit */

#define ZCOM_MSTYPE____0

0

/* Undefined type */

#define ZCOM_MSTYPE_MSLT

1

/* From local terminal */

#define ZCOM_MSTYPE_LPLP

2

/* Local program to program */

#define ZCOM_MSTYPE_TOLZ

3

/* Timer message for local ZLU */

#define ZCOM_MSTYPE_LPLT

4

/* Local program to terminal */

#define ZCOM_MSTYPE_LSEM

5

/* Local system event message */

#define ZCOM_MSTYPE_RSLT

6

/* Response from local terminal */

#define ZCOM_MSTYPE_RSLP

7

/* Response from local program */

#define ZCOM_MSTYPE____8

8

/* Undefined type */

#define ZCOM_MSTYPE_MSRT

9

/* Remote terminal message */

#define ZCOM_MSTYPE_RPLP

10

/* Remote program to program */

#define ZCOM_MSTYPE_TORZ

11

/* Timer message for remote ZLU */

#define ZCOM_MSTYPE_RPLT

12

/* Remote program to terminal */

#define ZCOM_MSTYPE_RSEM

13

/* Remote system event message */

#define ZCOM_MSTYPE_RSRT

14

/* Response from remote terminal */

#define ZCOM_MSTYPE_RSRP

15

/* Response from remote program */

272

Chapter 4

Image 272
Contents ACC Programmer’s Reference Guide Page Legal Notices Page Printing History Ninth Edition April Release B.03.10 HP-UXRelated Documentation Hardware ManualsContents Zcom Tables and Data Structures Zcom C I/F Library Routines Contents Zcom Subsystem Introduction Zcom Software Overview Overview of Zcom Software Structure ZcomZcom Subsystem Components Zcom Software Overview Zcom Concepts Definition and Features of ZLUs Program ZLUs Zcom Concepts User Interface References Zcom Message Handling Overview ZLU Definition Mapped ZLUs Message Queuing Program Message QueueingPhysical Terminal Table Priorities Multiplexing Outbound Multiplexing Outbound MultiplexingInbound Multiplexing Inbound Multoplexing PTZRVR=PZLU PzluTerminal State Terminal StateError Handling Error Handling Zcom Tables and Data Zcom Tables and Data Structures Memory Organization Memory OrganizationDifferences in 32-bit and 64-bit Data Structures Differences in 32-bit and 64-bit Data Structures Zcom Header Structure Hpzlu HpttblHpptbl HpiftpZcom Header Structure Zcom Header Structure Zcom Header Structure Zcom Header Structure Zcom Header Structure Ttgen Zcom Header Structure Qlbgrp QlbnamQlbqnb QlbrsvSlbgrp SlbnamSlbsze SlboffZcom Header Structure Node Entries Table FLAGS.event FLAGS.validFLAGS.status FLAGS.localNode Entries Table ZLU Tables Individual ZLU EntriesZLU Type Values Type DescriptionZLU Tables Logical Terminal Tables Ltzshrcvrs LthldqLthdqn LtaddrLogical Terminal Tables System Status flags LTCWCT, LTTXCT, LTRXCT, Lterct Message and error counters Logical Status Structure LtstatLTINST, LTBRCH, LTWORK, Ltarea Terminal logical ID Physical Terminal Tables Physical Terminal Tables User Maintainable Area Ptuser Field Name Field Description Field Type Size BytesPhysical Terminal Tables Physical Terminal Tables Physical Terminal Tables Terminal Status Field Ptdrst Firmware terminal status Ptfwst Physical Terminal Tables Physical Terminal Tables Interface Table Ifwinfo Interface HPA Value Inhpa 63-32 31-28 27-18 17-14 13-12 10-6Symbol Value hex Meaning Interface Card Status IfstatScheduler Event Flags Ischdl Interface Table Interface Table Ipendgbufs Isubchbuf Ifirqbp Nextl Interface Table Zcomipstatund Zcomipstattxb Port Configuration Buffer Iportn Channel E1/T1 ACC Card FormatEcode SyncWhere Timeslot Array Element StructureTxSubch TxFillSubchannel Specification Array Element Structure 31-30 29-24 23-8IFIRQBUF, IRESPBUF, Istdtbuf DMA response buffers Datadelay Response Records Response Type Field Symbol Value Meaning ZcomrptypebufferZcomrptyperemote ZcomrptypeirrResponse Records Queue Header Queue Header AreaQfunc QlimitQfdata Queue Header Queue Flags Chapter 101 Data Buffer Pool Organization of Buffer PoolBuffer Pool Layout when first initialized Free Buffer Header Structure zfbhtype Buffer flags Bfflag Field Block Size Used flag106 MRQ Message HeaderMID Mstype MsrespMzdest MzsrceMessage Type Mstype Response code for message type 2 Response code for all other message typesMrqcode MrqtermMrqstat MrqtagMrqcode Terminal request codes Request Value DescriptionSetype SeflagSenode SetimeNode Status Change Event Fields Zcomsetypenode NodenumNstat SpareCFGINFO1 Dynamic Reconfiguration Event ZcomsetypereconfigCfgclass 116 Chapter 117 Zcom Kernel Data NcardChapter 119 HPA value of I/F card Hpano Chapter 121 SYS structure Zcom system global information, zsystype Name Value hex State Current Zcom system status Name Value hex StateCurrent Zcom system status Higher Order Bits Debug Level Field Format Debug Level Field Values Bit Name Value hex MeaningChapter 125 Zcglock ZcmlockZcrlock ZcslockLockp RefcountZcom Kernel Data 128 Zcom C I/F Library Routines 130 ZLU configuration calls Zltstore Logical data storage allocationZLU data transfer calls Chapter 133 ZLU Definition Man Pages Getdevice Getdevice Read Zcom device definitionsConsiderations Dpp Return paramExample File, /opt/acc/cfg/zcomdevice Multiprotocol ACC Utilities ReferenceAscii file, /opt/acc/cfg/zcomdevice.txt Zdgen1, malloc3CLtfind DescriptionLen Length in bytes of ibuf Logical terminal table. Note that if the logicalTerminal is not found, ibuf will not contain valid data 142 Chapter 143 Ltqdget Ltqdget Posix 1003.1c kernel threads API package. This routine has146 Ltqdput 148 Chapter 149 MYZLU01 MakezlunameTTY Name Returned Name Comment Makezluname Parameter and from the same TTY, the same ZLU name will be Ptfind 154 Pointer to a buffer into which the Zcom physical Terminal table data will be placed. Note that ifPhysical terminal is not found i.e., ierr != 0, then no Data is moved into zpttReturn Value Zclos Cancellation point Chapter 159 Zcntl Send no wait, report errors Send no wait, report errors with bufferSend no wait Send no wait, definite statusMhp ACC Programmers’ Reference Guide Ibuf, lenRstat ReturnParamFor rcode not all of them are applicable to zcntl Rtyp164 Chapter 165 166 Zcomerror Not a cancellation point168 Async-cancel safe ZcomlnameZcomlog3x Zcomlog 172 Int Unix error code, usually errno Unix error string will be loggedInt Zcom error code Zcom error string will be logged174 Chapter 175 Zcomstatus ACC Programmers Reference Guide under ‘ZCOM Status MessageChapter 177 Zconfig Zap Return Param Response data Chapter 181 Zcomzconfigcntl ZcomzconfigsysZcomzconfigcard ZcomzconfigportChapter 183 Configuration Data Header.configDSC Control Header.actionNo specific response data or error Data.setctl.cfgclassData.setctl.cfginfo1 Zcom subsystemData.sysret.error Header.tag1 Header.tag2Data.setsys.sysname Data.setsys.qlimitChapter 187 Dscreassignift Data.setcard.iftnoData.setcard.itype Data.setcard.fnameData.cardret.error Data.cardret.iftnoData.setport.spare Data.setport.portnoData.setport.rcode Data.setport.cnfg Value Encoding modesFM1 transition = FM0 transition = Value Parity select No Parity Odd parity Even parityValue Rate Value Clock multiplierValue Rate 0000 Use Baud2 1000 19,200 Pmode Pmode2 FsyncValue Other port for clock synchronization Port Value T1 Transmit Attenuation Z7330B only 15 dB 22.5 dBOtherwise by default there is a delay to avoid T1/ESF mode contain an address whichUser device. By default the ACC is a user Performance report messages in T1/ESF modeData.portret.status Data.setport.qlimitData.portret.iftno Data.portret.portno Chapter 197 Configuration Data header.config Data.setportsc.iftno Data.setportsc.portnoData.setportsc.subchno Data.setportsc.rcodeData.setportsc.ptcfg-ptinfo.subchb.tmsl RTISet to Mode Data.setportsc.ptcfg-ptinfo.subchb.specSet to Data.setportsc.lenData.portscret.status Chapter 203 Header.action ZcDSCCREATELTTPTT Create a new terminal LTT ZcDSCCREATELTTONPTT Create a new LTT on an existingData.setterm.daddr Data.setterm.iftnoData.setterm.portno Data.setterm.subchnoData.setterm.dtype Data.setterm.ltypeResponse Data data.termret.zaddr Chapter 207 208 Name Zeventrcvr210 Chapter 211 ‘C’ structure for a Zcom Event Message is shown below ZcomsetypenodeFiles Zgetshrcvrlist Zgetshrcvrlist Get list of current shared receiversShould have ZcMAXSHAREDRCVRS+1 entries Table entry from which you want the shared receivers listType of shared receiver list is set to ZcMAXSHAREDRCVRS 216 Name ZinfoParam Return, Tables and Data Structures section Returnvalue Files Zinit Zinit Zcom routine initializationParameters Following fieldsChapter 223 Zltmg Zltmg Move a logical terminal between groupsZltmg 226 Zltmx Zltmx Control logical terminal multiplexingParameters Chapter 229 Zltqueue Zltqueue Logical data queue allocationApplication number of terminal group ApplnAppln Queue Returned Program Nmbr Label Queue No Chapter 233 Zltstore Zltstore Logical data storage allocationTerminal table, for the storage in the extension area 236 Zltup 238 Chapter 239 Zluopen Zcom error codes and their meanings This return parameter is undefined242 Zmapr 244 Zname 246 Chapter 247 Zopen Node contains the local node as defined in the Ttgen Ld1Zap Zcom address node, ZLU number, and checksum 250 Chapter 251 Zpeek Error codes and their meanings Zread3X, zluopen3XZport Zcomzmuxportall ZcomzmuxportconfZcomzmuxportbaud ZcomzmuxportportNo error Some terminals in this port not disabledIllegal port mode Break routine not installedValue Operating mode Value Parity selectClk Value Clock source258 T1 ESF Value Port ModeValue 260 Chapter 261 Zptup Chapter 263 Zqmve Chapter 265 Zqsze Zqhdp Return param 268 Zread Mode ZcREADWWAIT 0 Read with wait After the timeout period has elapsedThere is no message on the queue, error Zenodata Same ZLU. When a message arrives, only oneChapter 271 272 Chapter 273 274 Zrntimer 276 Chapter 277 Zsend Mhp-mid.ztagw2Zsend 280 Chapter 281 282 Chapter 283 284 Chapter 285 286 Chapter 287 Zsetql Chapter 289 290 Zsetrcvr 292 Zsetrcvr 294 Ztimr 296 Chapter 297 298
Related manuals
Manual 20 pages 4.89 Kb