This file conatins examples on how to use various methods in SPI.
- Author
- Ido Algom
- Date
- 1/12/2017
- Copyright
- Copyright (C) 2017 by Modularity Ltd. All rights reserved. No part of this software may be used, stored, compiled, reproduced, modified, transcribed, translated, transmitted, or transferred, in any form or by any means whether electronic, mechanical, magnetic, optical, or otherwise, without the express prior written permission of Modularity Ltd.
{
TranObj.SetPinpadId(1);
if (TranObj.GetTransactionResultCode() == 0) {
std::vector<ReceiptLine> MerchentReceipt = TranObj.GetMerchentRecipt();
}
}
return 1;
}
{
string Version;
if ( (AshraitServiceHandle = PaymentInterface.
GetServiceHandler(
"AshraitEMV")) == NULL)
if (AshraitServiceHandle == NULL)
return -1;
AshraitServiceHandle->
Init(
"Machine_Serial_Number");
{
std::string ReportResult;
AshraitServiceHandle->
EndOfDay(&ReportObject);
if (ReportObject.GetPrintableString(ReportResult) == SPI_SUCESS)
std::cout << ReportResult;
}
std::cout << "Ready to use";
return 0;
}