I need to transmit LLDP packets.
An LLDP packet is framed like this
Code: Select all
Frame Encapsulation
An LLDP PDU is encapsulated within an 802 frame that cooresponds to frame
formatted to meet the requirements of an 802 Slow Protocol as defined by Std
802.3, 2000 Edition, Annex 43B. The format is shown in the following figure:
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Slow Protocols Multicast DA |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Multicast DA (cont) | Station SA |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Station SA (cont) |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Slow Protocols Type | Subtype | reserved |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| LLDP PDU Message |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
[ figure 1 – Slow Protocols LLDP Message Format ]
The Slow Protocol encapsulation has the following fields:
Slow Protocols Multicast DA
The Slow Protocols Multicast destination address is 01-80-C2-00-00-02.
This address is within the range reserved by ISO/IEC 15802-3 (MAC Bridges)
for link-constrained protocols and will not be forwarded by conformant MAC
bridges.
Station SA
The source MAC address of the sending station
Slow Protocols Type
The Slow Protocols Type field encoding of the Length/Type field is 88-09
Subtype
The Slow Protocols Subtype field is TBD
All reserved fields shall be set to zero.
01-80-C2-00-00-02
The ethernet library only provides SendUDP which takes a destination ip address.
regards peter