© 2000 Ubicom, Inc. All rights reserved. - 15 - www.ubicom.com SX IrDA Virtual Peripheral Implementation AN16 Table 3-4.   LAP State Machine Current State Event Action Next State NDM DiscoveryRequest & Media is idle Slot number = 0.
Send XID command frame.
Start slot timer.
QUERY Send UI request & Media is idle Send a UI command frame NDM uXIDCmd frame If the GenerateNewDeviceAddr flag is set then ask
payload layer to generate a new device address.
If received slot number = 0 the generate a random slot
number.
If received slot number = chosen slot number = 0 then
send a XID response frame.
NDM uNRM frame Apply connection address.
Send UA frame to accept connection.
Apply connection parameters.
Initialize frame numbering registers.
Indicate connection to LMP layer.
NRM uUI frame Pass data to application layer NDM QUERY Timeout & slot number < 8 Increment slot number.
Send XID command frame.
Start slot timer.
QUERY Timeout & slot number = 8 Send XID command frame with slot number of $FF NDM uXIDRsp frame Pass data to user QUERY NRM DisconnectRequest SCLOSE I frame Jump to TestNr. NRM sRR Frame RemoteBusy = false.
Jump to TestNr.
NRM sRNR Frame RemoteBusy = true.
Jump to TestNr.
NRM sREJ Frame or sSREJ Frame Jump to TestNr. NRM SNRM Frame Send RD frame.
Start WD timer
SCLOSE DISC Frame Send UA response
Apply default connection parameters.
Indicate disconnect to LMP layer.
NDM All other frames (command, final) Send S frame NRM Timeout Apply default connection parameters.
Indicate disconnect to LMP layer.
NDM    NRM
(TestNr)
Received Nr = NrAck Start WD Timer.
NrNotAck := NrAck.
Inform LMP layer that transmitted data has been
acknowledged if appropriate.
Jump to TestNs.
same