Raspberry Pi RASPIVEND User manual

Raspberry PI
vending solution
(RASPIVEND)
v.28. .20 6
Quick Reference
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

Table of Contents
I. General in ormations...........................................................................................................5
1. Terms.............................................................................................................................5
2. Working modes..............................................................................................................5
A. Low level mode.........................................................................................................5
B. High level mode........................................................................................................6
2. Communication parameters...........................................................................................7
II. Hardware overview............................................................................................................8
1. Power supply requirements...........................................................................................8
2. Connector description....................................................................................................8
III. Low level mode...............................................................................................................10
1. Multiplexer GPIO truth table........................................................................................10
2. MDB bill validator initialization.....................................................................................10
3. MDB bill enable............................................................................................................10
4. MDB bill disable...........................................................................................................11
5. MDB bill read setup vector...........................................................................................11
6. Coin acceptor initialization...........................................................................................11
7. Coin acceptor enable...................................................................................................11
8. Coin acceptor disable..................................................................................................12
9. Coin acceptor read setup vectors................................................................................12
10. Set maximum credit...................................................................................................12
11. Reset the current credit..............................................................................................13
12. Return change...........................................................................................................13
13. Set current cash credit...............................................................................................13
14. Poll credit and devices status....................................................................................14
15. Reset all devices' status............................................................................................17
16. Cashless INIT............................................................................................................17
17. Cashless ENABLE.....................................................................................................18
18. Cashless DISABLE....................................................................................................18
19. Cashless VEND CANCEL.........................................................................................18
20. Cashless VEND REQUEST......................................................................................19
21. Cashless VEND SUCCESS......................................................................................19
22. Cashless VEND FAIL.................................................................................................19
23. Cashless REVALUE..................................................................................................20
24. Cashless READ VECTORS.......................................................................................20
25. Cashless END SESSION..........................................................................................20
26. RTC set......................................................................................................................21
27. RTC get......................................................................................................................21
IV. High level mode with xinetd............................................................................................23
1. Con iguring xinetd........................................................................................................23
2. MDBBillInit...................................................................................................................23
3. MDBBillEnable.............................................................................................................23
4. MDBBillDisable............................................................................................................24
5. MDBCoinInit.................................................................................................................24
6. MDBCoinEnable..........................................................................................................24
7. MDBCoinDisable.........................................................................................................25
8. MDBBillSettings...........................................................................................................25
9. MDBCoinSettings........................................................................................................26
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

10. MDBSetMaxCredit.....................................................................................................27
11. MDBSetMaxCreditOK................................................................................................27
12. MDBSetCurrentCredit................................................................................................28
13. MDBSetCurrentCreditOK...........................................................................................28
14. MDBSetChange.........................................................................................................29
15. MDBSetChangeOK....................................................................................................29
16. MDBCreditReset........................................................................................................29
17. MDBPoll.....................................................................................................................30
18. MDBResetStatus.......................................................................................................30
19. MDBCashlessInit.......................................................................................................31
20. MDBCashlessEnable.................................................................................................31
21. MDBCashlessDisable................................................................................................31
22. MDBCashlessSettings...............................................................................................32
23. MDBCashlessVendRequest......................................................................................32
24. MDBCashlessVendRequestOK.................................................................................33
25. MDBCashlessVendSuccess......................................................................................33
26. MDBCashlessVendFailed..........................................................................................33
27. MDBCashlessRevalue...............................................................................................34
28. MDBCashlessEndSession.........................................................................................34
29. KBSet + KBSetOK.....................................................................................................35
30. RTCSet......................................................................................................................36
31. RTCGet......................................................................................................................36
V. High level mode with Python 3 service daemon..............................................................37
1. Con iguring Python 3...................................................................................................37
2. MDBBillInit...................................................................................................................37
3. MDBBillEnable.............................................................................................................37
4. MDBBillDisable............................................................................................................38
5. MDBCoinInit.................................................................................................................38
6. MDBCoinEnable..........................................................................................................38
7. MDBCoinDisable.........................................................................................................39
8. MDBBillSettings...........................................................................................................39
9. MDBCoinSettings........................................................................................................40
10. MDBSetMaxCredit.....................................................................................................41
11. MDBSetMaxCreditOK................................................................................................41
12. MDBSetCurrentCredit................................................................................................42
13. MDBSetCurrentCreditOK...........................................................................................42
14. MDBSetChange.........................................................................................................43
15. MDBSetChangeOK....................................................................................................43
16. MDBCreditReset........................................................................................................43
17. MDBPoll.....................................................................................................................44
18. MDBResetStatus.......................................................................................................44
19. MDBCashlessInit.......................................................................................................45
20. MDBCashlessEnable.................................................................................................45
21. MDBCashlessDisable................................................................................................45
22. MDBCashlessSettings...............................................................................................46
23. MDBCashlessVendRequest......................................................................................46
24. MDBCashlessVendRequestOK.................................................................................47
25. MDBCashlessVendSuccess......................................................................................47
26. MDBCashlessVendFailed..........................................................................................47
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

27. MDBCashlessRevalue...............................................................................................48
28. MDBCashlessEndSession.........................................................................................48
29. SetMUXChannel........................................................................................................48
30. CCTHopperInit...........................................................................................................49
31. CCTHopperDispense.................................................................................................49
32. CCTHopperCheckDispense......................................................................................50
33. CCTHopperDispenseCipher......................................................................................50
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

I. General informations
1. Terms
- RASPIVEND = Raspberry PI vending board (shield).
- RASPIVEND DAEMON - xinetd based RASPIVEND management daemon.
- MDB PERIPHERALS = payment systems connected on the MDB bus.
- CCTALK PERIPHERALS = payment systems and peripherals, connectod to ccTalk bus.
- HOST APPLICATION = the application executed by the xinetd superserver installed on
the Raspberry PI
- CLIENT APLICATION = the client application that will connect to the socket o the HOST
APPLICATION
- LOW LEVEL APPLICATION = the application that can directly communicate using
Raspberry PI serial port (/dev/ttyAMA0) and also can handle it's GPIO pins.
- ACK = acknowledge
- NACK = not-acknowledge
RASPIVEND board and RASPIVEND daemon, toghether with VTLCOMBUS keyboard
simulator module, can be used to upgrade any Necta hot and universal machines and alos
any Wurlitzer universal spring machine.
2. Working modes
The RASPIVEND can be used to communicate with peripherals using two methods:
a. A low level communication method that can o er access to all peripherals by the
Raspberry PI serial port (/dev/ttyAMA0) and using 3 o it's GPIO to handle the multiplexers
to select the proper communication channel.
b. A high level communication method that simpli ies the user inter ace development,
o ering a language independent support.
A. Low level mode
In low level mode, there are simple commands to manage the MDB devices. The built-in
irmware will handle MDB commands and it is the ideal mode where the developers don't
need to learn any MDB command and response. Also there is no need to calculate the
MDB checksum since this is automatically calculated by the RASPIVEND and correctly
sent to the MDB peripheral. When the RASPIVEND will receive a low level command, it
automatically turn low level mode ON and begin to continuously poll the MDB
PERIPHERALS.
In this mode, there is no limit accessing any other peripheral and the LOW LEVEL
APPLICATION (created by the user) has the entire responsibility o multiplexer controls pin
manipulation by using the appropriate GPIO. The only channel that is automatically
selected is the MDB channel, which is selected every time a MDB low level command is
sent to the board (see page 9 or pin usage).
A proprietary simple message structure is available to communicate with bill validators,
coin acceptors/changers and cashless devices. The general message ormat is detailed in
table 1.
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

B. High level mode
This mode is using a xinetd driven application that can use a socket to communicate.
For the moment, there are some limitations, depending on the level mode, but we are
constantly work to add more and more unctions on the high level mode too, because this
mode can be used with less or no complications, even with a browser based application.
Below you can ind a table with a level modes comparison:
Function/Level mode Low level High level
MDB coin acceptor/changer yes yes
MDB bill validator yes yes
MDB cashless # yes yes
MDB cashless #2 yes yes
ccTalk yes Only with Python 3
RS232 # yes yes
RS232 #2 yes yes
GPRS communication port yes yes
VTLCOMBUS Necta keyboard Only with xinetd Only with xinetd
VTLCOMBUS Wurlitzer keyboard Only with xinetd Only with xinetd
RTC set/get Only with xinetd Only with xinetd
Raspberry PI GPIO yes uture development
POWER GOOD signal for autoshutdown uture development uture development
Direct peripheral selection and communication yes yes
Table 1: Level modes comparison
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
always 0xFE 1 byte 1 byte variable length, depending on subcommand 1 byte
Table 2: Low level message format
- <HEADER> – Is always a byte with a value o 0xFE.
- <CMD> - De ines the command group sent to the RASPIVend.
- <SUBCMD> - De ines the speci ic subcommand o the command group.
- <PARAMETERS> - De ines the command parameters that will be send to the MDB
peripheral ( or example, the maximum credit that the INTERFACE should accept or the
change it should return rom changer). Some commands are not requiring parameters.
Also, the variable length depends on subcommand.
- <CRC> - De ines the message checksum. The <CRC> is calculated as an XOR o all
message bytes, including the <HEADER>. For example, the command to enabled the bill
validator is: 0xFE 0x42 0x02 and the CRC or this command is 0xBE. Transparent mode
can be used or any application.
2. Comm nication parameters
The communication settings should meet the ollowing speci ications:
a. For the peripherals (excepting the MDB bus), there is no restriction regarding the serial
port settings you need.
b. For then MDB communication parameters:
Parameter Value
baud 57600
data bits 8
parity NONE
hardware low YES (RTS/CTS)
so tware low NO
Table 3: MDB communication parameters
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

II. Hardware overview
1. Power s pply req irements
The RASPIVEND can be powered with stabilized 24VDC or 12VDC, depending on your
MDB PERIPHERALS and CCTALK Peripherals. You must use a stabilized DC power
supply with at least 2A output. It is necessary to ollow the correct polarity. In the
eventuality o an accidental polarity reversal, the entire board, the MDB PERIPHERALS
and the CCTALK PERIPHERALS are protected, but will not work. The board also supplies
the 5V/2A or Raspberry PI (or compatible). The system eliminates the separate 5V
microUSB power supply or Raspberry PI. You will only need one power supply or the
entire system.
2. Connector description
- <J 7> – POWER connector or the RASPIVEND and MDB PERIPHERALS. Use only
stabilized power supplies, with a voltage rating according to your MDB PERIPHERALS.
Also, be care ul at the current rating, since this may vary rom one MDB peripheral to
another. Use your MDB peripheral manual to identi y the power needs.
- <J 0> - RS232 connector. General purpose RS232 serial port, with no hardware low
wires.
- <J > - RS232 connector. General purpose RS232 serial port, with no hardware low
© 2016 – AUTOMATROM SRL – www.vendingtools.ro
Picture 1: Board overview

wires
- <J7> - Used to connect the MDB PERIPHERALS.
- <ccTalk> - Used to connect he CCTALK PERIPHERALS.
- <J 2> - VTLCOMBUS. This is a proprietary protocol that can be used to expand the
board with any needed boards (I/O ans sensr boards, etc.). For the moment there is one
single board available or this device and it's unction is to simulate keyboard press or
Necta hot and spring machines and or Wurlitzer universal spring machines.
- <J 5> - Communication port. For the moment there is one device available or this port
and it is a GPRS communication module based on SIMCOM M2M block.
- <J > - 40 pins Raspberry PI (or compatible) single board computer connector. This
connector provides access to POWER, GPIO and serial port. This connector, also supplies
the power or Raspberry PI. Used pins and unctions can be ind in the table below. Pins
marked by green background are available or user applications and alos, the power and
GND pins. Pins marked with red background are reserved or RASPIVEND.
Pin
No.
Rpi function RASPIVEND Pin
No.
Rpi function RASPIVEND
1 3.3V 3.3V 2 5V 5V
3 GPIO2/SDA1/I2C MODEM DCD 4 5V 5V
5 GPIO3/SCL1/I2C MODEM RTS 6 GND GND
7 GPIO4/GPCLK0 MODEM PWR 8 GPIO14/TXD Serial TX
9 GND GND 10 GPIO15/RXD Serial RX
11 GPIO17 MUX A 12 GPIO18/PCM_CLK Modem stat
13 GPIO27 MUX B 14 GND GND
15 GPIO22 MUX C 16 GPIO23 Not used
17 3.3V 3.3V 18 GPIO24 Not used
19 GPIO10/MOSI/SPI Not used 20 GND GND
21 GPIO9/MISO/SPI Not used 22 GPIO25 Not used
23 GPIO11/SCLK/SPI Not used 24 GPIO8/CE0/SPI Not used
25 GND GND 26 GPIO7/CE1/SPI Not used
27 SDA0/I2C/ID EE Not used 28 SCL0/I2C/IDEE Not used
29 GPIO5/GPCLK1 Not used 30 GND GND
31 GPIO6/GPCLK2 Power good 32 GPIO12/PWM0 Not used
33 GPIO13/PWM1 Not used 34 GND GND
35 GPIO19/PCMFS/PWM1 Not used 36 GPIO16 MDB CTS
37 GPIO26 MDB RTS 38 GPIO20/PCMDIN Not used
39 GND GND 40 GPIO21/PCMDOUT Not used
You do not need to per orm any settings on the RASPIVEND, neither hardware or
so tware.
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

III. Low level mode
To use this mode, your application must handle the ollowing:
a. GPIO pins o the Raspberry PI, needed to switch the multiplexers to the correct
communication channel (to select the peripheral).
b. Serial port o the Raspberry PI (/dev/ttyAMA0).
c. or MDB handling you need, also, to manipulate MDB RTS and MDB CTS pins.
The MDB communication is handled by setting MDB RTS pin to lo and waiting or CTS
PIN to be set as lo by the board. Only messages sent by reading lo on MDB CTS will be
correctly received by the device. Please be sure that will keep MDB RTS high when you
do not need to communicate to MDB bus.
. Multiplexer GPIO truth table
GPIO22 GPIO27 GPIO 7 Selected peripheral
(the peripheral currently connected to RasPI)
0 0 0 MDB
0 0 1 RS232 #1 (J10)
0 1 0 RS232 #2 (J11)
0 1 1 VTLCOMBUS
1 0 0 ccTalk
1 0 1 Modem
2. MDB bill validator initialization
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x42 0x01 [none] 0xBD
RASPIVEND answer
0xFE 0x42 0x01 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will execute the initialization procedure or the MDB bill validator connected
on the MDB port.
3. MDB bill enable
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x42 0x02 [none] 0xBE
RASPIVEND answer
0xFE 0x42 0x02 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will enable the bill validator that will start accepting all the banknotes it can
recognize.
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

4. MDB bill disable
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x42 0x03 [none] 0xBF
RASPIVEND answer
0xFE 0x42 0x03 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will disable the bill validator that will no longer accept any banknote.
5. MDB bill read set p vector
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x42 0x04 [none] 0xB8
RASPIVEND answer
0xFE 0x42 0x04 - <BILL SETUP> - 27 bytes
- <BILL EXPANSION IDENTIFICATION> - 29 bytes
CRC
This command will return the settings vector or the MDB bill validator. Those vectors are
read on the initialization phase. There are two vectors available and the contained data are
detailed in the MDB documentation. This command is optional and is used only i you need
to handle some lower in ormations (bill validator MDB level, so tware version, ISO country
code, etc.).
6. Coin acceptor initialization
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x43 0x01 [none] 0xBC
RASPIVEND answer
0xFE 0x43 0x01 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will execute the initialization procedure or coin acceptor/changer
connected on the MDB port.
7. Coin acceptor enable
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x43 0x02 [none] 0xBF
RASPIVEND answer
0xFE 0x43 0x02 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will activate the coin acceptor/changer. All recognized coins/tokens will be
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

accepted and deposited.
8. Coin acceptor disable
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x43 0x03 [none] 0xBE
RASPIVEND answer
0xFE 0x43 0x03 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will deactivate the coin acceptor/changer.
9. Coin acceptor read set p vectors
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x43 0x04 [none] 0xB9
RASPIVEND answer
0xFE 0x43 0x04 - <COIN SETUP> - 23 bytes
- <COIN EXPANSION IDENTIFICATION> - 33 bytes
CRC
This command will return the settings vector or the MDB coin acceptor/changer. Those
vectors are read on the initialization phase. There are two vectors available and the
contained data are detailed in the MDB documentation. This command is optional and is
used only i you need to handle some lower in ormations (coin acceptor/changer MDB
level, so tware version, ISO country code, etc.).
10. Set maxim m credit
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x52 0x01 <MAXIMUM CREDIT> - 4 bytes – MSB
Example: 0xFE 0x52 0x01 0x00 0x00 0x02 0x58 0xF7 –
this will set the maximum credit to 600 units. In case o
EUR or USD, this means 600 cents or 6.00EUR/6.00USD
CRC
RASPIVEND answer
0xFE 0x52 0x01 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will set the maximum acceptable credit or bills. Any bill exceeding this
value will be rejected. For coins, you should disable the MDB coin acceptor a ter reaching
the maximum credit value.
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

11. Reset the c rrent credit
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x52 0x02 [none] 0xAE
RASPIVEND answer
0xFE 0x52 0x02 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
The RASPIVEND has an internal cash counter which is incremented or each bill or coin
deposited by the MDB PERIPHERALS. This counter can be read by using a POLL
command, detailed on “12. Poll credit and devices status”. For simplicity reasons, this
counter can be reseted by this command. You can use this command a ter each
transaction, or anytime you need.
12. Ret rn change
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x52 0x03 <CHANGE TO RETURN> - 4 bytes – MSB
Example: 0xFE 0x52 0x03 0x00 0x00 0x01 0x5E 0xF0 –
this command will return 350 change, which means, or
EUR and USD, 350cents or 3.50EUR/3.50USD
CRC
RASPIVEND answer
0xFE 0x52 0x03 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will start returning change i the RASPIVEND has a changer connected on
the MDB port.
13. Set c rrent cash credit
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x52 0x04 <SET CURRENT CASH CREDIT> - 4 bytes – MSB
Example: 0xFE 0x52 0x03 0x00 0x00 0x01 0x5E 0xF0 –
this command will set current credit to 350, which means,
or EUR and USD, 350cents or 3.50EUR/3.50USD – This
is used to adjust credit in multivend mode and be ore the
cashless revalue command to set only remaining credit
or revalue.
CRC
RASPIVEND answer
0xFE 0x52 0x04 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will sest the current credit on the RASPIVEND. It is indicated to use this
command a ter every cash transaction inished with a success ul vend.
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

14. Poll credit and devices stat s
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x50 0x01 [none] 0xAF
RASPIVEND answer
0xFE 0x50 0x01 - <CURRENT CREDIT CASH> - 4 bytes MSB ( or
example, 0x00 0x00 0x04 0xE2 representing 1250 cents
or 12.50EUR/12.50USD)
- <CURRENT CREDIT CASHLESS> - 4 bytes MSB ( or
example, 0x00 0x00 0x04 0xE2 representing 1250 cents
or 12.50EUR/12.50USD)
- <BILL validator status> - 4 byte, according to MDB bill
validators status (see Table 3) – this register contains last
4 bill validator status. I the register has the value
0xFFFFFFFF, then the bill validator is not initialized. The
rightmost byte o this register is the last status.
- <COIN acceptor/changer status> - 4 bytes, according to
MDB coin acceptors/changers status (see Table 4)
- <CASHLESS #1 status> - 4 bytes, according to the
MDB cashless status (see Table 5)
- <CASHLESS #2 status> - 4 bytes, according to the
MDB cashless status (see Table 5)
- <CASHLESS MEDIA ID> - 4 bytes, card/tag serial
number
CRC
This command must be run periodically, at least one per second, to interrogate the
payment systems status and to take all needed decisions.
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

Value Description
0x00 Idle
0x0 De ective Motor - One o the motors has ailed to per orm its expected
assignment.
0x02 Sensor Problem - One o the sensors has ailed to provide its response.
0x03 Validator Busy - The validator is busy and can not answer a detailed command
right now.
0x04 ROM Checksum Error - The validators internal checksum does not match the
calculated checksum.
0x05 Validator Jammed - A bill(s) has jammed in the acceptance path.
0x06 Validator was reset - The validator has been reset since the last POLL.
0x07 Bill Removed - A bill in the escrow position has been removed by an unknown
means. A BILL RETURNED message should also be sent.
0x08 Cash Box out o position - The validator has detected the cash box to be open
or removed.
0x09 Validator Disabled - The validator has been disabled, by the VMC or because o
internal conditions
0x0A Invalid Escrow request - An ESCROW command was requested or a bill not in
the escrow position.
0x0B Bill Rejected - A bill was detected, but rejected because it could not be
identi ied.
0x0C Possible Credited Bill Removal – There has been an attempt to remove a
credited (stacked) bill.
0xFF Not known or not initialized status
Table 2: Bill validators status codes
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

Value Description
0x00 Idle
0x0 Escrow request - An escrow lever activation has been detected.
0x02 Changer Payout Busy - The changer is busy activating payout devices.
0x03 No Credit - A coin was validated but did not get to the place in the system when
credit is given.
0x04 De ective Tube Sensor - The changer has detected one o the tube sensors
behaving abnormally.
0x05 Double Arrival - Two coins were detected too close together to validate either
one.
0x06 Acceptor Unplugged - The changer has detected that the acceptor has been
removed.
0x07 Tube Jam - A tube payout attempt has resulted in jammed condition.
0x08 ROM checksum error - The changers internal checksum does not match the
calculated checksum.
0x09 Coin Routing Error - A coin has been validated, but did not ollow the intended
routing.
0x0A Changer Busy - The changer is busy and can not answer a detailed command
right now.
0x0B Changer was Reset - The changer has detected an Reset condition and has
returned to its power-on idle condition.
0x0C Coin Jam - A coin(s) has jammed in the acceptance path.
0x0D Possible Credited Coin Removal – There has been an attempt to remove a
credited coin.
0xFF Not known or not initialized status
Table 3: Coin acceptors/changers status codes
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

Value Description
0x00 Idle
0x0 Not used in this con iguration
0x02 Display request – not used in this con iguration
0x03 Begin cashless session
0x04 Cancel request rom cashless to VMC
0x05 Vend approved.
0x06 Vend denied.
0x07 End cashless session.
0x08 Cancel
0x09 Not used in this con iguration.
0x0A Not used in this con iguration.
0x0B Command out o sequence.
0x0C Not used in this con iguration.
0x0D Revalue approved.
0x0E Revalue denied
0x0F Not used in this con iguration.
Table 4: Cashless status codes
15. Reset all devices' stat s
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x50 0x02 [none] 0xAC
RASPIVEND answer
0xFE 0x50 0x02 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will set to 0x00 all devices' status. It is used to clear status and let the
RASPIVEND to update it in accordance with the new devices' status. It will not reset
credits
16. Cashless INIT
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x53 0x01 <CASHLESS NUMBER> (0x01 = cashless #1, 0x02 =
cashless #2)
CRC
RASPIVEND answer
0xFE 0x53 0x01 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

This command will init the cashless device with the corresponding number
17. Cashless ENABLE
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x53 0x02 <CASHLESS NUMBER> (0x01 = cashless #1, 0x02 =
cashless #2)
CRC
RASPIVEND answer
0xFE 0x53 0x02 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will enable the cashless device with the corresponding number
18. Cashless DISABLE
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x53 0x03 <CASHLESS NUMBER> (0x01 = cashless #1, 0x02 =
cashless #2)
CRC
RASPIVEND answer
0xFE 0x53 0x03 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will disable the cashless device with the corresponding number
19. Cashless VEND CANCEL
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x53 0x04 <CASHLESS NUMBER> (0x01 = cashless #1, 0x02 =
cashless #2)
CRC
RASPIVEND answer
0xFE 0x53 0x04 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will send “CANCEL CURRENT SESSION” command to the cashless
device.
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

20. Cashless VEND REQUEST
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x53 0x05 <CASHLESS NUMBER> 1 byte (0x01 = cashless #1,
0x02 = cashless #2)
<VEND VALUE> - 4 bytes - the value o the selected
product to sell - MSB ( or example, 0x00 0x00 0x04 0xE2
representing 1250 cents or 12.50EUR/12.50USD)
CRC
RASPIVEND answer
0xFE 0x53 0x05 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will send ask the permission to sell a product using cashless. This
command requires to use POLL command to obtain the answer rom the cashless device
(according to Table 5).
21. Cashless VEND SUCCESS
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x53 0x06 <CASHLESS NUMBER> (0x01 = cashless #1, 0x02 =
cashless #2)
CRC
RASPIVEND answer
0xFE 0x53 0x06 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command must be sent a ter a success ul vend using cashless. Following this
command, the RASPIVEND will substract the product value rom the cashless credit, and
the cashless device will be instructed to substract th same amount rom the customer's
credit.
22. Cashless VEND FAIL
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x53 0x07 <CASHLESS NUMBER> (0x01 = cashless #1, 0x02 =
cashless #2)
CRC
RASPIVEND answer
0xFE 0x53 0x07 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command must be sent a ter a ailed sale situation (due to VMC error). The cashless
will be instructed to re und the product price to the customer's account.
© 2016 – AUTOMATROM SRL – www.vendingtools.ro

23. Cashless REVALUE
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x53 0x08 <CASHLESS NUMBER> (0x01 = cashless #1, 0x02 =
cashless #2)
CRC
RASPIVEND answer
0xFE 0x53 0x08 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will trans orm the remaining cash credit into cashless credit and will re und
this amount on customer's account.
24. Cashless READ VECTORS
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x53 0x09 <CASHLESS NUMBER> (0x01 = cashless #1, 0x02 =
cashless #2)
CRC
RASPIVEND answer
0xFE 0x53 0x09 <CASHLESS SETUP> - 8 bytes
<CASHLES EXPANSION INFORMATION> - 30 bytes
CRC
This command will return the low level settings o the cashless device, according to MDB
protocol.
25. Cashless END SESSION
<HEADER> <CMD> <SUBCMD> <PARAMETERS> <CRC>
0xFE 0x53 0x0A <CASHLESS NUMBER> (0x01 = cashless #1, 0x02 =
cashless #2)
CRC
RASPIVEND answer
0xFE 0x53 0x0A 0xFB – command execution ailed
0xFC – command success ully executed
0xFD – command CRC error
CRC
This command will return turn the session o and will orce the cashless device to return to
idle state.
© 2016 – AUTOMATROM SRL – www.vendingtools.ro
Table of contents
Popular Vending Machine manuals by other brands

Royal Vendors
Royal Vendors Merlin IV Service and parts manual

Seaga
Seaga JDL-2 COMBO Service and parts manual

Crane
Crane Dixie-Narco Glassfront BevMax 3 5800 Installation & setup guide

Westomatic
Westomatic Sigma Simplicity instructions

BIANCHI VENDING
BIANCHI VENDING Gaia Fresh Milk Use and maintenance manual

RSL
RSL Bag & Overstrom B4 Cleaning guide