Siemens 7 manual Buffer Handling

Page 29

Multiplexer Driver Developer’s Guide

7.3 Buffer Handling

s

7.3Buffer Handling

SerMux

SerPortN

Mulitplexer Control Port 0

Channel number

 

 

 

 

Send

 

RCV

 

Priority with MaxSequence

 

 

Timeouts (Request Timeouts and

Queue

 

Queue

 

Scanning Timeouts)

Requests

 

Requests

 

Statistics

 

 

 

 

V24 Status from itself and the

 

 

 

 

Modem

Circular

 

Circular

 

Handshake Status

 

 

Current Read and Write Status

buffer

 

buffer

 

Circular Buffer Params

Send

 

RCV

 

ScanSendRequest

 

 

 

 

 

 

 

 

 

SerPort 0

Special control functions:

EstablishDLC

ReleaseDLC

CloseDown

SetModemStatus

SendVersionCommand

ConfirmCommand

Buffer

Circular

buffer

Send

CommandBuffer

GetFrameBufferPort0()

if receive a Control Command

SerPort0IndicateFrame()

Timer functions:

WrTimer()

OnTimerSerPort0()

OnTimerSerPort()

Control Timeouts for Send and Receive Queue Requests for repeating Control Commands and Timeouts for scanning the Escape Sequence

Send function:

while(GetWriteBuffer) { SerPort=GetNextSerPort(); SerPort->GetFrame(); SubmitWriteBuffer();

}

Frame Assembly and check

state machine Demux

IndicateRead {

ProcessData(); // check frame, crc SerPortIndicateFrame()

//indicate frame to a SerPort instance

}

WrGetWriteBuffer(void *Buffer,ULONG &Length);

void WrIndicateReadBuffer(void *Buffer,ULONG Length);

WrSubmitWriteBuffer(void *Buffer,ULONG

 

Length);

 

WrWriteComplete();

 

WrReturnWriteBuffer();

 

Write Buffer

Read Buffer

Pool

Pool

Wrapper

Figure 5: Driver internal buffer handling

Mux_Drv_DevGuide_v07

Page 29 of 36

2006-9-27

Confidential / Released

 

 

Image 29
Contents User’s Guide Copyright General NotesContents Multiplexer Driver Developer’s Guide List of Tables TablesList of Figures FiguresDocument History Chapter What is newDocument History Multiplexer Driver Developer’s Guide Introduction IntroductionSupported Product Versions Supported Product VersionsAbbreviations Related DocumentsRelated Documents Abbreviation DescriptionArchitecture Hierarchy Chart in the SystemUser ArchitectureHandling of the Physical Serial Port Signal DescriptionModule Detection Handling of the Physical Serial PortHandling of Control Lines on Virtual Ports Handling of Control Lines on Virtual PortsLimitation of Virtual Ports Module Initializing Sequence Command Response Function Associated Registry ValueModule Initializing Sequence Power Down on PC Suspend Power DownPower Down after Closing the Last Port Module Re-initializationPower Down Power Down on PC ShutdownFiles Required for WinMux2k Driver Installation InstallationInstalling the WinMux2k Driver InstallationDeinstalling the Driver Deinstalling the DriverWindows Windows XP new desktop, not the classic desktopDevice Settings and Properties Device Settings and PropertiesSettings on the Serial Multiplexer Properties Value Data Example Properties Settings Stored in the Windows RegistrySettings Stored in the Windows Registry TC45, XC18 only Multiplexer Driver Developer’s Guide Values Data Example Properties Dial-up Network Settings Settings for ApplicationsFax Settings Settings for ApplicationsSoftware Requirements Translate Source CodePreparing the Translation Compiler FlagsAdditional Source Documentation Additional Source DocumentationInteraction of the Different Driver Objects Internal Driver States Internal Driver StatesBuffer Handling Buffer HandlingTo th e S e rM u x O b je c t a re in d ic a te d Data TransferMultiplexer Driver Developer’s Guide SerMuxSend and SerMuxSendPort0 Functions SerMuxSend FunctionStart +++-Parser +++-ParserBooting Operating System Known ProblemsShutdown of the Operating System Standby of the Operating SystemOperation on Virtual USB Port Special EnvironmentsAutomatic Shutdown in case of Emergency Special Environments