VMC Configuration Object

The vmc_configuration class is used to set up various parameters and flags that control the behaviour of the VMC. Proper configuration is crucial for ensuring smooth operation and compatibility with different peripherals.

Configuration Object

The code block below displays the vmc_configuration class for the available SDK languages.

public class vmc_configuration 
      public Object port_vpos;
      public int port_vpos_baud;

      public String serial;
      public String model;
      public String sw_ver;
      public int    machine_type;
      boolean explicit_vend_success;
      public boolean price_not_final_support;
      public boolean mag_card_approved_by_vmc_support;
      public boolean mifare_approved_by_vmc_support;

      public boolean debug;
      public int dump_packets_level;

      public boolean reader_always_on;
      public boolean multi_session_support;
      public boolean multi_vend_support;
      public boolean always_idle;
      public 
public class vmc_configuration 
      public string  port_vpos;
      public int port_vpos_baud;

      public string serial;
      public string model;
      public string sw_ver;
      public int    machine_type;

      public bool reader_always_on;
      public bool multi_session_support;
      public bool multi_vend_support;
      public bool always_idle;
      public bool explicit_vend_success;
      public bool price_not_final_support;
      public bool mag_card_approved_by_vmc_support;
      public bool mifare_approved_by_vmc_support;

      public bool debug;
      public int dump_packets_level;

Object Parameters

The table below describes the parameters of the class.

ParameterTypeDescription
port_vposStringThe port to which the VPOS is connected.
port_vpos_baudintThe baud rate for the VPOS communication port.
serialStringThe serial number of the machine. This enables precise tracking, effective inventory management, and streamlined maintenance scheduling.
modelStringModel name of the machine. It assists in troubleshooting by distinguishing different machine types in logs and reports.
sw_verStringThe software version of the VMC.
machine_typeintThe type of machine connected to the VMC.
explicit_vend_successboolFlag to indicate explicit vending success.
price_not_final_supportboolIndicates if the price is not final, which is helpful for pre-authorization.
mag_card_approved_by_vmc_supportboolSupport for magnetic card approval by VMC.
mifare_approved_by_vmc_supportboolSupport for MIFARE card approval by VMC.
debugboolEnables or disables debugging.
dump_packets_levelintSets the level of packet logging for debugging purposes.
reader_always_onboolIt keeps the reader always enabled.
multi_session_supportboolEnables support for multiple sessions.
multi_vend_supportboolEnables support for multi-vend operations.
always_idleboolConfigures the device to start transactions by product selection without initial card presentation.

Mandatory Fields

When configuring a VMC (Vending Machine Controller), there are specific mandatory fields essential for the proper identification of the machine. Properly managing these fields leads to improved troubleshooting, enhanced system integration, and more efficient maintenance processes.

Refer to the code block below for an example of the configuration for these mandatory fields.

vmc_config = new vmc_configuration();

vmc_config.model = "marshall-java-sdk";
vmc_config.serial = "01234567";
vmc_config.hw_ver = "01234567";
vmc_config.manuf_code = "manuf";

vmc_init()
	__strcpy(config.model, "marshall-c-sdk-demo");
	__strcpy(config.serial, "01234567");
	__strcpy(config.sw_ver, "vmc app version");
	__strcpy(config.vmc_hw_ver, “01234567”);
  __strcpy(config. vmc_manuf_code, “manuf”);

The table below describes the parameters:

ParameterTypeDescription
modelStringModel name of the machine. It assists in troubleshooting by distinguishing different machine types in logs and reports.
serialStringThe serial number of the machine. This enables precise tracking, effective inventory management, and streamlined maintenance scheduling.
hw_verStringHardware version of the machine. It ensures that the correct firmware and software are used. Different hardware versions may require specific drivers or compatibility adjustments.
manuf_codeStringIdentifies the machine's manufacturer, enabling proper support and operation.

Nayax Core

These parameters will be saved in Nayax Core. You can find them in Operations > Machines. Find and select your machine and open the VMC tab, as shown in the following image.

See Also