Echelon LonTal Stack User Manual

Page 42

Advertising
background image

30

Loading the Echelon Smart Transceiver or Neuron Chip

Function

Syntax

Description

l2ml_freel2packet()

extern system far void
l2ml_freel2packet(unsigne
d *mp);

Frees any packet buffers

returned by

l2ml_getl2packet()
method. This method does

not check for NULL

pointers. You can only free
packet buffers after

processing.

l2ml_allocl2buffer()

extern system far
unsigned
*l2ml_allocl2buffer(void)
;

The length field indicates the
size of the packet buffer

(including overhead).
The miCOMM field is
[miCOMM|miTQ] 0x12.
The format of this buffer is

[length] [miCOMM|miTQ]
[backlog/altpath] NPDU.

Allocates a L2 packet buffer

for transmitting. This
method returns NULL if

there are no L2 packet

buffers available.

l2ml_sendl2packet()

extern system far void
l2ml_sendl2packet(unsigne
d *mp);

Queues the packet buffer

allocated by

l2ml_allocl2buffer()
method for transmission.

This method does not check

for NULL pointers.

l2ml_l2buffsize()

extern system far
unsigned
l2ml_l2txbuffsize(void);

Returns the largest possible
size that the NPDU can be

for transmission to a
like-sized device (same

network input buffer size).

This is a better
measurement than the size

passed in from

l2ml_allocl2buffer()
method because it accounts

for internal overhead and

the receiver's capabilities

Advertising