EAFDSS::Base - EAFDSS Base Class Driver for all other drivers
Read EAFDSS on how to use the module. This manual page is only of use if you want to find out what it needs to develop a driver for a new EAFDSS device. This Base class is to be inherited by any new driver.
This the constructor, were we make sure we get the correct parameters to handle the initialization of device object. Things like the signatures directory, the serial number of the device. Also parameters special to the type of the device, like ip address, or serial port, or baud rate, etc.
The main job of an EAFDSS device is to produce signatures. Signatures of text files (invoices) or text streams. So in that function we make sure to read the text from the caller of the function in whatever format. Then we feed the text to the device which in return he gives us the signature of that text. The function at tha level handles the saving of the text in the "A file" and of the signature in the "B file", according to the rules set by the law for the filenames of the files.
What this function return is a single line containing the values of the following: serial number, the index of the last Z, the total signatures, the daily signatures, the last signature's data size, remaining signatures until the device will force a Z.
GetTime will return the time in "DD/MM/YY HH:MM:SS" format.
Use this method to set the date/time on the device. Provide the date/time in the "DD/MM/YY HH:MM:SS" format.
This method will return information about the name of the device and version of it's firmware.
This method should Query to find available devicess [NOT IMPLEMENTED]
This method will return the printing headers of the device. The returned array contains 6 couples of values. One for the type of the printing line, and one for the actual printing message.
This method will set the printing headers on the device. The headers are to be provided in the following format
The second most used function is Z report issuing function. At the end of the day ask for the device to close the fiscal day by issuing the Z report. It will return the signature of the day. The function will also take care to save the signature in the "C file"
This is our handy debuging function
This is version 0.80.
Hasiotis Nikos, <email@example.com>
Copyright (C) 2008 by Hasiotis Nikos
This library is free software; you can redistribute it and/or modify it under the terms of the LGPL or the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.