PCAP format for MDB
The MDB (Multi-Drop Bus) protocol is used inside a vending machine. MDB defines the communication between the main control board (VMC = Vending Machine Controller) and peripheral components, e.g. a payment terminal or a bill validator.
The VMC acts as bus master and sends a request to one peripheral at a time. A peripheral may send data only in response to such a request.
The MDB specification is maintained by the National Automatic Merchandising
Association (NAMA). As of August 2023, the current version of the MDB
specification is 4.3. It is available from
Data Link Type
300 (DLT_MDB) was assigned for MDB.
For pcap files, this value shall be set in the global header’s network field. Pcapng defines an Interface Description Block, its LinkType must be set to this value.
The packet data consists of an MDB pseudo-header plus the captured MDB data.
The pseudo-header has information about the type of the captured data.
|version||1||yes||set to 0 for now|
|event||1||yes||see the table below|
|peripheral address||1||no||required only for event 0xFE|
The peripheral address must be set in the header for packets from a peripheral to the VMC (packets from the VMC to a peripheral have the peripheral address in the MDB data). The possible values for peripheral address are defined in section 2.3 of the MDB specification, the xxx bits in this definition should be set to 0.
The event byte may be set to one of the following values.
|value||description||periph. address||MDB data|
|0xFF||data from VMC to peripheral||no||yes|
|0xFE||data from peripheral to VMC||yes||yes|
|0xFD||VMC initiated a bus reset||no||no|
The VMC sends a vend request to the Cashless #1 peripheral.
|0x00 0xff||0x13 0x00 0x00 0x3c 0x00 0x01 0x50|
The Cashless #1 peripheral sends a response to the VMC and approves the vending operation.
|0x00 0xfe 0x10||0x05 0x00 0x10 0x15|
Please send any questions or comments to ‘www(at)kaiser(dot)cx’