Development - “Cashier's Workplace” under LINUX. GPL

Last news


The system works at 15 cash desks. It is added. git here github.com/redeyser/IceCash . my mail is here redeyser@gmail.com Video
www.youtube.com/watch?v=69AF7n6sxDY

Background


It so happened that I work as a programmer / admin in a retail chain. I’ve been working for two years, before that I had never encountered servicing specialized programs and equipment, but I figured it out over time. A feature of my organization is that the authorities are not going to categorically invest in normal equipment. That is, it doesn’t smell like modernization at all, but it is often necessary to rush to replace something that has again become exhausted. In addition, most outlets do not have a license for the installed Windows XP OS. At retail outlets there is one or two cash desks based on computers that are dying of old age, the same old fiscal devices Shtrikh-M PRK, various barcode scanners (COM, USB, Keyboard) and METTLER TOLEDO scales. Of the software, initially there was only a license (with a key) 1C v7.7 "STRICH-M Cashier".

Deploying Linux Wherever Possible


In addition to the duties of monitoring the ticket offices, I had on my shoulders an office and a remote branch with all 1C computers, hardware (also not new), servers. And something I hardly managed to serve all this at first. Honestly, I'm Unixophile, so I hastened to introduce linux. Gradually, we managed to transfer office clients to Linux, and immediately it became easier to breathe, computers stopped growing with viruses, it remained only to monitor the hardware and select and install the necessary programs. The main client work continued on Windows, but it was already a terminal on the server, it is easier with it. If possible, the server I also transferred to Linux, leaving only one with windows server 2003.


Windows at the checkout - superfluous work to the administrator.


Viruses from flash drives often entered the ticket office (music and games corresponded constantly) and the OS had to be changed periodically. Of course, on newly installed OSes, a ban was made on connecting external media, but there was no way to refuse the administrator user - the Bar-M Cashier program refused to work adequately. Local hackers-sellers constantly broke the protection and recorded viruses, games, not licensed software on working computers! I don’t know, maybe I didn’t have enough perseverance to eliminate all these troubles, but the idea arose of putting linux at the box office. There was a problem with the drivers for the fiscal registrar, the special program for loading the scales wanted to work exclusively under windows (and no wine!), And there was also no PMK program itself (Cashier's workplace).

DENSY-CASH under LINUX


Having searched the Internet, DENSI-CASS was found. The workplace of the cashier under linux. The program costs 1000r, which is quite sane. I try to install on ubuntu / debian, it seems to work. I solved the problem with loading the scales through downloading via VPN from the server where windows is installed. After six months of work at DENSI-CASHI, certain experience has accumulated. I was not happy that the new keyboard scanners were working buggy, and it was because of the program itself. The program itself also fell out, although maybe I was wrong about its compatibility with ubuntu. From version to version, the program changed concepts and had to adapt to updates. The developers announced free code, but this code is not all open, and not fresh enough. Making your own branch from DENSY-CASHIER is just a pointless exercise, because it works with the closed PRK driver.
For me, the GPL means that the project must be completely OPEN, ENCOURAGING JOINT DEVELOPMENT. There was a purely commercial project with an unfriendly co-design policy.
I do not want to say that the guys are doing their job poorly, but if they did not protect their intellectual property in such a way (as they think the key to their commercial success), then development would have gone much more efficiently.

Cash desk under LINUX, based on the python SHTRIH-M GLP driver


On sourceforge there was a gpl driver written in python by a certain Dmitry Shamov project on sourceforge . I wrote to the author, he confirmed - the GPL project, do whatever you want with it. Inspired, I figured out the following new client scheme:
the fiscal registrar and the database will be controlled by a daemon with which you can communicate through a socket (even a simple telnet) using a simple API. This is in order to have direct access from the network to the most problematic equipment, as well as to be able to develop any kind of clients and bind them to this API. Thus, I do not seem to impose on anyone the interface of my client, the method of registering sales and my other personal views on the process of registering sales. In addition, it immediately becomes possible to work with one fiscal account of several clients, this is not necessary for me, but it may be useful to someone. I chose mysql database, it is easier with it. For tests, you can use the socket client to stream requests from STDIN. All this should be written in python, it is easier to modify and understand, in addition, it is a lot of platform. I decided to make the client itself on WEB, that is, using html + javascript + php. Of course, this will require a web server (apache2 is again easier). This structure, in my opinion, is simple for revision, branching in the project and allows you to access the box office in the form of a web page without resorting to rdp, vnc, ssh (although this will not be superfluous)

What happened


Now is the testing phase, though there is a lot of work and it is not possible to test everything properly. Actually, what happened, I liked it. It works quickly, I added fiscal book programming in the driver for check segments, technological zeroing, and opening a cash drawer. The daemon frk does transaction uploading, loading the price list and discount cards in the SHTRIH-M file format. Visual selection of goods, discount cards, works in registration mode with both visual buttons and the keyboard. OS took debian 6, without gnome, just installed IceWM, made autorun of X session, added a minimum of programs, except required ones (mysql, apache, php, ...) installed ssh, openvpn, x11vnc, samba, pidgin (on its jabber-server ), a simple browser. I deployed this whole thing to a USB flash drive and I’m testing it directly on it, since I suggest not using the hard drive - they are expensive now, and the old ones are not reliable. The system itself takes up 1.4GB, so even a 2GB flash drive will go in. I had already exchanged with the back-office already through the socket client, which only corrected a little. Features of interaction with the back office: communication through a modem or dedicated via VPN. The scales are connected via the network via a second network card, the port for loading the scales is forwarded by a firewall at the checkout. Soon I am going to install on outlets. I will post my project on sourceforge as soon as I test everything. the project will be called IceCash. In general, I saw other drivers on sourceforge, to other fiscal registrars, but for me it was enough to implement the SHTRIH-M PRK functionality. so even a 2GB flash drive will go in. I had already exchanged with the back-office already through the socket client, which only corrected a little. Features of interaction with the back office: communication through a modem or dedicated via VPN. The scales are connected via the network via a second network card, the port for loading the scales is forwarded by a firewall at the checkout. Soon I am going to install on outlets. I will post my project on sourceforge as soon as I test everything. the project will be called IceCash. In general, I saw other drivers on sourceforge, to other fiscal registrars, but for me it was enough to implement the SHTRIH-M PRK functionality. so even a 2GB flash drive will go in. I had already exchanged with the back-office already through the socket client, which only corrected a little. Features of interaction with the back office: communication through a modem or dedicated via VPN. The scales are connected via the network via a second network card, the port for loading the scales is forwarded by a firewall at the checkout. Soon I am going to install on outlets. I will post my project on sourceforge as soon as I test everything. the project will be called IceCash. In general, I saw other drivers on sourceforge, to other fiscal registrars, but for me it was enough to implement the SHTRIH-M PRK functionality. communication via modem or leased line through VPN. The scales are connected via the network via a second network card, the port for loading the scales is forwarded by a firewall at the checkout. Soon I am going to install on outlets. I will post my project on sourceforge as soon as I test everything. the project will be called IceCash. In general, I saw other drivers on sourceforge, to other fiscal registrars, but for me it was enough to implement the SHTRIH-M PRK functionality. communication via modem or leased line through VPN. The scales are connected via the network via a second network card, the port for loading the scales is forwarded by a firewall at the checkout. Soon I am going to install on outlets. I will post my project on sourceforge as soon as I test everything. the project will be called IceCash. In general, I saw other drivers on sourceforge, to other fiscal registrars, but for me it was enough to implement the SHTRIH-M PRK functionality.

I wrote this article in the hope that there will be people interested in such a project, ready to complete the project for their tasks, because my ideological goal is to create a cashier’s workplace with really open source, with the possibility of joint development. Any opinions of Khabrahabrovites on this matter will also be interesting.
Thanks for attention.


Also popular now: