Coder Social home page Coder Social logo

viewtouch / viewtouch Goto Github PK

View Code? Open in Web Editor NEW
156.0 22.0 44.0 4.67 MB

ViewTouch Point of Sale (PoS) - official

Home Page: http://www.viewtouch.com

License: GNU General Public License v3.0

C++ 93.83% C 0.02% Shell 0.72% CMake 1.24% Makefile 0.02% Perl 4.14% sed 0.02%
gnu hospitality hacktoberfest point-of-sale touchscreen-user-interface x-window-system

viewtouch's Introduction

ViewTouch©

Build Status

Join the chat at https://gitter.im/ViewTouch/viewtouch ViewTouch is a registered trademark in the USA.

History

ViewTouch© is the ORIGINAL Graphical Touchscreen Restaurant Point of Sale Interface, first created by restaurateur Gene Mosher and C programmer, Nick Colley, in 1986. Initial funding of the development of the code in '86 was due to the effort of Ed Ramsay. Barbara Mosher has been a perennial financial supporter from the beginning in 1986 and continuing into present day. ViewTouch was first demonstrated to the public at ComDex, Las Vegas in November, 1986. https://commons.wikimedia.org/wiki/File:Comdex_1986.png Early funding was due, in part, by the generosity of John King, M.D., Chicago. The current version of ViewTouch was first created in 1995-98 by Gene Mosher and C Programmer, Richard Bradley. Major funding of the development of the code during the '95-'98 period is due to the much appreciated effort of Billy Foster. Extensive enhancement of the code was carried out from 2000-04 by Bruce King. Major funding of the development of the code during the '00-'04 period is due to the effort of Doug DeLeeuw. Since the arrival of ViewTouch under the GNU Public License in 2014 ViewTouch code has been available at GitHub and a great deal of refinement and modernization of the code has taken place. Special thanks to Jack Morrison for amazing debugging skills and to Reinhold Gschweicher for major refactoring and code standardization. Gene and Barbara Mosher have provided lifetime support and funding for ViewTouch from its inception. Gene owns the ViewTouch copyright. He began writing Point of Sale Code in 1979. His passion and vision has overseen the development, management and maintainance of the code on a wide array of computers and point of sale equipment across six decades.

Contact

With the availability of ViewTouch source code under the GPL and the arrival of the Raspberry Pi Foundation's computers a restaurateur can automate one's own restaurant. ViewTouch makes available Point of Sale computers powered by the Raspberry Pi Compute Module. These are made by the Chinese company, Chipsee.

The availability of ViewTouch source code and documentation at GitHub benefits the clients, customers and associates of Gene Mosher and it facilitates the development and maintenance of ViewTouch source code.

An important link at the top of this page is the Wiki link. It contains a page with build instructions and an 'Announcements' page with the latest news.

Restaurateurs who are clients or customers of ViewTouch and who wish training and 24/7 support need only contact Gene at http://www.viewtouch.com/contact.html or phone: 541-515-5913.

Official website: http://www.viewtouch.com

License

ViewTouch is released under the GNU Public License, version 3.

The ViewTouch Point of Sale Computer, Commercial Support and Enquiries

ViewTouch all-in-one Point of Sale (PoS) Computer with Raspberry Pi and 15.8" Display: $399 plus shipping and bank fund transfer charges. MicroSD card available separately from Gene Mosher, ViewTouch maintainer/guardian, 2842 Wingate Street, Eugene, Oregon,
ViewTouch Point of Sale Computer with 15.8" Display The ViewTouch website and contact point is http://www.viewtouch.com Email: [email protected] Phone: 541-515-5913. Shown here and on the ViewTouch home page, the ViewTouch all-in-one touchscreen PoS computer powered by the Raspberry Pi, manufactured by Chipsee, Bejing, China and shipped directly to customers via FedEx.

ViewTouch microSD image

The latest ViewTouch image for the Raspberry Pi can be downloaded, decompressed and copied to a 32Gb or larger microSD card. This image boots to the ViewTouch desktop and offers many desktop support features for the ViewTouch Point of Sale program. A bootable 32Gb microSD card with this image is available for $25.

Screenshots

These screenshots are in 1280 x 1024 resolution, however, default graphical resolution is 1920 x 1080.

Time Clock and Secure Log On Touchscreen Password, Log On and Timeclock

Order Breakfast, then Display and/or Print in Kitchen A Lightning Fast, High Resolution Interface Order Breakfast, then Display and/or Print in Kitchen

Time Clock Review and Edit - Control Labor Expense Back Office, Comprehensive Labor Costing, Overtime Alerts Interactive Time Clock Review and Editing Time Clock Review and Edit - Control Labor Expense

Decision Support: Fly-Over, Drill-Down in Real Time Touch 'n' View Any Day or Any Period Updated Every Minute Decision Support: Fly-Over, Drill-Down in Real Time ViewTouch doesn't just store all of your data for you - it keeps your entire transaction history in RAM. Rely on ViewTouch for the report data you need with perfect accuracy and lightning speed. Auditors can see compliance across every period. Control NON CASH revenue adjustments and labor costs, including non-intuitive details. The only way you can run a business is 'by the numbers' and here are the numbers you need, Shift By Shift, Weekly, Monthly, Quarterly and Yearly.

More Viewtouch POS (Point of Sale) History

ViewTouch first ran as a C program on the Atari ST computers in 1986. The Atari ST was a very exciting platform under Jack Tramiel from 1985 until 1993/4. In 1995 development of ViewTouch under UNIX began. At that time we were using Power Computing (i.e., Power PC) computers manufactured by The Computer Group at Motorola and the operating system was IBM's version of UNIX, (AIX). When computer manufacturer Atari ceased operations, in 1993, if one didn't want to use Microsoft DOS or Apple computers, UNIX was one's only choice, and MIT's X Window System was the only practical choice with which one could build tools which could then be used to create a network transparent graphical interface. This is precisely the decision which was made for ViewTouch in early 1995. In 1997 the decision was made to move from AIX on the Motorola PowerPC to the Red Hat Linux distribution on the Intel X86 platform. In 2000 a transition from C to C++ and from Red Hat to Debian took place. ViewTouch remains on Debian as the default distribution and features the XFCE desktop. Since 2016 the default hardware platform for Viewtouch is the family of Raspberry Pi computers. ViewTouch production POS computers provide a desktop icon which compiles and installs the latest version of the code from GitHub. ViewTouch Point of Sale isn't just about the advantage of the power of Linux; it's also about the advantage of the remote display capability of The X Window System. To add additional ViewTouch PoS sessions, use either Android Tablets running the ViewTouch Android XServer .apk file or or touchscreen monitors driven by any Raspberry Pi computer. Then just add the IP address of such a device to the ViewTouch page 'View & Manage Displays & Printers'.

Payment gateway/processors

The ViewTouch GUI has the Monetra Credit/Debit Card Verification engine integrated into it and can be used with virtually any payment processor. Visit the Monetra web site to see the certifications and the site licenses charges, which are quite reasonable, and the role they play in all this. ViewTouch does not have to play with any payment gateway at all - it's 100% optional.

ViewTouch POS on Android

ViewTouch can send a remote display/input session to any Android tablet or smartphone. The Android X Server is based on XSDL and can be downloaded from QR Codes found either on the ViewTouch desktop or from http://www.viewtouch.com/nc.html. Many, many thanks to Sergii Pylypenko, of Kiev, Ukraine for creating and maintaining a special version of XSDL for ViewTouch !!

viewtouch's People

Contributors

genemosher avatar gitter-badger avatar goofybud16 avatar jackdigitalinsight avatar jasonwartell avatar mreierson avatar neroburner avatar norbertwenzel avatar partoneoftwo avatar pelya avatar steve132 avatar yurivict avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

viewtouch's Issues

Android X Server Update: July 10, 2020

Sergii Pylypenko's initial version of the Android X Server for ViewTouch works only on Android versions 8 or earlier. Sergii's followup version, released in July, 2020 works on Android versions 9 and later. Both of these can be easily installed on one's tablet or phone by scanning the appropriate QR-Code at http://www.viewtouch.com/nc.html It may well be that the new version can also be used on Android versions 8 or earlier but I have not tested this yet or heard from anyone who has. The new version has several nice improvements, too.

The ViewTouch X Server for Android is, of course, the remote display/input session which turns a tablet or smartphone into a portable ViewTouch Point of Sale device. Note that a tablet or smartphone must support the ViewTouch default display resolution of 1920 x 1080 or better. This new code defaults to 24-bit video, dispenses with the startup dialog and includes the ViewTouch bit-mapped fonts, allowing for a much faster startup !

Announcing ViewTouch Bounties!

Visit the Announcement page in the ViewTouch wiki to read about ViewTouch Bounties. I am closing this issue because in a year no one has responded to it.

conf_file setValue does not what comment says

viewtouch/conf_file.cc

Lines 170 to 180 in 18a4d96

// if the key does not exist in that section, and the value passed
// is not t_Str("") then add the new key.
if (key == NULL) {
key = new t_Key;
key->key = keyName;
key->value = value;
dirty = true;
section->keys.push_back(*key);
return true;

The comment says, that the entry is created if the value is not "", but there is no check for empty string (neither key nor value). Should I add the check or just remove the comment?

Obsolete Buildfiles

Can I remove build-configuration files from buildsystem than cmake? They are now obsolete and would need to be changed to work properly (Makefile, configure, netbeans project)

can we remove the HELLO file?

can we remove some of the scrips in the scripts folder?

failed to create symbolic link

root@debian:~/viewtouch/build# ln -s /usr/viewtouch/dat/ dat ..
ln: failed to create symbolic link ‘../dat’: File exists
on debian 8.1 fresh install

is the /usr/viewtouch/dat/ supoosed to soflink link folder located at ~/viewtouch/??

Broken on FreeBSD: license_hash.cc

First, BSD isn't defined. I had to apply this patch:

--- main/license_hash.cc.orig   2019-05-15 21:27:05 UTC
+++ main/license_hash.cc
@@ -62,7 +62,11 @@ int GetUnameInfo(char* buffer, int bufflen)
     return 0;
 }
 
-#ifdef BSD
+#if defined(__FreeBSD__)
+
+#include <sys/types.h>
+#include <sys/sysctl.h>
+
 /* bkk bsd6 compile */
 typedef unsigned int u_int;
 

Then, there is this failure:

/usr/ports/misc/viewtouch/work/viewtouch-19.04.1/main/license_hash.cc:100:9: error: no matching function for call to 'sysctl'
    if (sysctl(mib, 6, buffer, &len, NULL, 0) < 0)
        ^~~~~~
/usr/include/sys/sysctl.h:1081:5: note: candidate function not viable: no known conversion from 'const char *' to 'void *' for 3rd argument; take the address of the argument with &
int     sysctl(const int *, u_int, void *, size_t *, const void *, size_t);
        ^
/usr/ports/misc/viewtouch/work/viewtouch-19.04.1/main/license_hash.cc:103:19: error: read-only variable is not assignable
    stringbuff[0] = '\0';
    ~~~~~~~~~~~~~ ^
/usr/ports/misc/viewtouch/work/viewtouch-19.04.1/main/license_hash.cc:109:32: error: use of undeclared identifier 'RTM_IFINFO'
        if (ifmsg->ifm_type == RTM_IFINFO)
                               ^
/usr/ports/misc/viewtouch/work/viewtouch-19.04.1/main/license_hash.cc:112:21: error: member access into incomplete type 'struct sockaddr_dl'
            if ((sdl->sdl_alen > 0) && (sdl->sdl_alen < 256))
                    ^
/usr/ports/misc/viewtouch/work/viewtouch-19.04.1/main/license_hash.cc:86:12: note: forward declaration of 'sockaddr_dl'
    struct sockaddr_dl *sdl;
           ^
/usr/ports/misc/viewtouch/work/viewtouch-19.04.1/main/license_hash.cc:112:44: error: member access into incomplete type 'struct sockaddr_dl'
            if ((sdl->sdl_alen > 0) && (sdl->sdl_alen < 256))
                                           ^

Make error

[ 15%] Building CXX object CMakeFiles/vtpos.dir/loader/loader_main.cc.o
/home/viewtouch/viewtouch/loader/loader_main.cc: In function ‘void OpenStatusBox()’:
/home/viewtouch/viewtouch/loader/loader_main.cc:218:44: error: ‘gtk_label_set_xalign’ was not declared in this scope
gtk_label_set_xalign(GTK_LABEL(label),0);
^
/home/viewtouch/viewtouch/loader/loader_main.cc:219:44: error: ‘gtk_label_set_yalign’ was not declared in this scope
gtk_label_set_yalign(GTK_LABEL(label),1);
^

Users have to once again Clock In when ViewTouch exits and is restarted.

ViewTouch is designed to hold all data in RAM and to write all data through to storage. When the program exits, either by intent of the user or not, when the program is again started, all data is reloaded from storage. The effect is that in every case, absolutely no data is lost if the program is interrupted.

There is, however, a single recent instance where some data is now being lost if the program is interrupted. The information no longer being reloaded is the Start Time data about users who were Clocked In when the program exits and is started again. The reload formerly recalled who was Clocked In and their Start Time. It is not currently reloading this data.

When ViewTouch exits and restarts it no longer contains the Clock In data for users who were Clocked In at the moment when the exit occured. Timeclock data for users who were Clocked In AND had also Clocked Out is correctly reloaded and retained. In short, on program restart, ViewTouch no longer retains data of which users were Clocked In for the current day unless they had also already Clocked Out. Users who were Clocked In and had not already Clocked Out must again Clock In. Users should not have to do this; on program exit and restart the program should retain the Clock In status of all users.

The history of Clock In and Clock Out written in the /usr/viewtouch/dat/labor/labor_000000001 file. I am assuming that the information about each user's Clock In and Clock Out information for the current day is written to this file and reloaded from this file if the program has exited during the day and is run again because the size of the file does increase. This file contains the complete history of all Timeclock data for all users.

Formatting issue: An extra line and line feed is issued at the top of some buttons

An extra line and line feed is issued at the top of some pages after text headers are printed. The bug can be seen when selecting the 'Displays & Tablets' button located at the right on Page One. The button in this case displaying the unnecessary line is a Button Type 'Hardware'.

The bug can also be seen in another button on page -61, Revenue & Productivity Analysis Report, where Button Type 'Report' and Report Type 'System Balance' also displays this line. (To see this, Select 13524 > Administration > Manager's Gateway > Reports > Revenue & Productivity.) The color of the extra line is always black and seems to be printed after any text is printed at the top of the buttons. Any lines at the top which are colored are OK.

The bug also shows on the remote kitchen and bar pages which are also located at the right on Page One if any menu items have been ordered. The buttons on these pages are: Button Type 'Report', Report Type 'Check'.

Bug Report: Date

Users have identified a bug in the date shown at upper right of Page One and in the Date Selector used to view archived transactions and employee histories.
On August 1 the date shown is July 1. The date selector shows the previous day as June 31. August 1 is correctly shown as the date of the Sales Archive and the August 1 is correctly shown on receipts.
NeroBurner has identified Howard Hinnant's tz.h The TimeZone Database Parser as the path toward not only a resolution of this bug but also integrates all the benefits of this new worldwide standard for handling date & time into ViewTouch.
It would be hard to overstate the significance of this step forward. It's precisely the kind of upgrade to ViewTouch which will give longevity to ViewTouch. Some work has been done and more work lies ahead, but we should all be as grateful to NeroBurner as I myself am for what he has done and is doing.

xfonts-50dpi

You have this in the apt install command but it doesn't exist in either Debian or Ubuntu

Version-info from cmake

I'm working on a PR to get some more versioning information into the ViewTouch binary

The examples have a short version, a long version and a detailed version info each.
The major, minor and patch number are hard coded in version.cmake. The fourth number is the number of commits since the last git tag.

version when no git repo is found or no git executable is found. The timestamp is the current UTC time

ViewTouch 4.2.79
ViewTouch 4.2.79-~+dev+dirty
ViewTouch 4.2.79-~+dev+dirty (dirty (detached, dirty), x86_64-linux-gcc8.2.1, 2018-10-22 21:18:24 +0000)

version when there are changes in the git repository (git repo is dirty), The timestamp is the current UTC time.

ViewTouch 4.2.79
ViewTouch 4.2.79-301+dev+1be90a8
ViewTouch 4.2.79-301+dev+1be90a8 (1be90a8 (nb_dev, dirty), x86_64-linux-gcc8.2.1, 2018-10-22 21:19:59 +0000)

version info on a branch (nb_dev in this case), clean git repo. The timestamp is the time the current git commit has been commited

ViewTouch 4.2.79
ViewTouch 4.2.79-301+dev+1be90a8
ViewTouch 4.2.79-301+dev+1be90a8 (1be90a8 (nb_dev), x86_64-linux-gcc8.2.1, 2018-10-22 23:07:04 +0200)

Version info on a git tag v4.2.79-rc1. Can be used for releases and release candidates. The timestamp is the time the current git commit has been commited

ViewTouch 4.2.79
ViewTouch 4.2.79-0+rc1+c013f47
ViewTouch 4.2.79-0+rc1+c013f47 (c013f47, x86_64-linux-gcc8.2.1, 2018-10-22 23:22:33 +0200)

Version info on a git tag v4.2.79. Can be used to mark releases. The timestamp is the time the current git commit has been commited

ViewTouch 4.2.79
ViewTouch 4.2.79-0+c013f47
ViewTouch 4.2.79-0+c013f47 (x86_64-linux-gcc8.2.1, 2018-10-22 23:22:33 +0200)

Is the Versioning scheme acceptable? If yes where should we use which version string?

Code Errors (two)

Two code errors which cause a program exit have been reported. To see them, Logon as Editor (User ID 42) > Start > Manager's Gateway

First code error: > Reports > Receipts Balance

The next page which should appear is System Page -62, Accountant's Report. Sometimes the program exits before System Page -62 displays and sometimes the program exits after System Page -62 displays but when any button on System Page -62 is selected.

Second code error: > Configuration > Customize Job Titles, Families, Phrases

The program exits when Page 13 (of 16) is selected.

Hopefully it's useful to mention that both of these program exits have shown themselves and were fixed in the past.

The 'install' target fails: file INSTALL cannot find "/usr/ports/misc/viewtouch/work/viewtouch-19.04.1/dat"

-- Up-to-date: /usr/ports/misc/viewtouch/work/stage/usr/local/viewtouch/bin/runonce
CMake Error at cmake_install.cmake:149 (file):
  file INSTALL cannot find
  "/usr/ports/misc/viewtouch/work/viewtouch-19.04.1/dat".


FAILED: CMakeFiles/install/strip.util 
cd /usr/ports/misc/viewtouch/work/.build && /usr/local/bin/cmake -DCMAKE_INSTALL_DO_STRIP=1 -P cmake_install.cmake
ninja: build stopped: subcommand failed.

A couple of small omissions during startup reported in the file: error_log.txt

These are not code errors introduced during refactoring. There are omissions in the program boot sequence which have been around for quite a while.

Background: When ViewTouch starts, the following subdirectories are created in /usr/viewtouch/dat/ if they don't exist:

  • account
  • archive
  • backups
  • current (this directory is automatically populated with six .dat files)
  • customers
  • expenses (this directory is automatically populated with expensedb)
  • html
  • labor
  • languages
  • pageexports
  • pageimports
  • stock
  • text
  • updates

When ViewTouch starts these directories should also be created

  • /usr/viewtouch/dat/conf (if this directory exists it is automatically populated with three .ini files)
  • /usr/viewtouch/dat/screensaver

and ViewTouch should execute this command if the file: /usr/viewtouch/dat/tables.dat doesn't exist.
wget2 -P /usr/viewtouch/dat http://www.viewtouch.com/tables.dat

wget2 is GNU's rewrite of wget. It is available in Debian and in Raspbian. https://guix.gnu.org/packages/wget2-1.99.2/

If running ViewTouch on 64-bit Linux

ViewTouch does not need display compositing enabled and becomes unstable when enabled !! Disable display compositing. If using the XFCE desktop, select: Applications > Settings > Window Manager Tweaks > Compositor Tab > Uncheck "Enable display compositing"

The Unique Advantage of the RPi 4 in the hospitality environment: Mirrored displays

The RPi 4 makes it 'easy as pie' to add a second display which mirrors the first touchscreen display and allows customers to watch the process of having their order entered by hospitality employees. This is not something which hospitality customers are typically allowed to view on proprietary point of sale systems. It can be done for well under $200, on displays as small as 12", or even on large TVs.

Remove Update functionality

Can we remove the automatic remote update functionality from Viewtouch? For example in manager.cc. I don't think this functionality is used anymore

Segfault at button press

Sometimes when pressing a button rapidly a segmentation fault occurs a segmentation fault

1  XtRemoveTimeOut                              0x7fc227f40bc7 
2  RemoveTimeOutFn             manager.cc  2929 0x557c6d42b7c1 
3  Terminal::ClearSelectedZone terminal.cc 3153 0x557c6d444485 
4  Terminal::Mouse             terminal.cc 1536 0x557c6d43e13e 
5  Terminal::MouseInput        terminal.cc 4175 0x557c6d4488f7 
6  TermCB                      terminal.cc 267  0x557c6d4398b5 
7  ??                                           0x7fc227f4082d 
8  XtAppNextEvent                               0x7fc227f41570 
9  StartSystem                 manager.cc  944  0x557c6d423979 
10 main                        manager.cc  454  0x557c6d4214af 

Direct link to RemoveTimeOutFn

viewtouch/main/manager.cc

Lines 2925 to 2931 in f72b113

int RemoveTimeOutFn(int fn_id)
{
FnTrace("RemoveTimeOutFn()");
if (fn_id > 0)
XtRemoveTimeOut(fn_id);
return 0;
}

AMA on reddit

This is not an issue but rather a heads up to everyone that I will be doing an AMA (ask me anything) on reddit on Sunday, November 13, at 3pm, Pacific Standard Time. I'll be online for three hours, until 6pm, Pacific Standard Time.

This AMA coincides with the 30th anniversary of when I first unveiled ViewTouch at the Comdex show in Las Vegas, on November 17, 1986. I had just been married and my wife generously agreed to allow me to spend our honeymoon demonstrating ViewTouch to thousands of people during the five day show.

Nicholas Turnbull has been working at a fever pitch for the past three weeks and in the next few days will be introducing several stability fixes and miscellaneous improvements into the ViewTouch code base here at GitHub. I have a deep appreciation for Nicholas and for all who have made so many improvements and fixes in the code during the two years it's been at GitHub. I especially am grateful to Nicholas for the step he has taken in using the Eclipse IDE and the GDB (Gnu Debugger). After many visible and obvious bugs have been fixed in the past couple of years I regard it as quite a significant achievement, as would be expected, that Nicholas has been able to put the GDB to use and uncover some other bugs (serious, it turns out) which would certainly never have been discovered, much less fixed. Special thanks to Nick for that, then. And I hope that everyone who is not yet 100% committed to the use and value of GDB would take the cue from this.

I don't know of any other method to use GitHub to give everyone a heads up but if there is one I would appreciate being made wise to it so that I don't have to use the Issues component in the future to make announcements such as this one.

Touchscreen Lag in Debian 9 Stable (but no longer in Testing)

There has recently been introduced in ViewTouch a significant delay, or lag, in the processing of touch and mouse input on certain platforms. This may be the result of something in the Linux event handling code or perhaps in the xorg input device code and in the way the ViewTouch handles touch (and mouse) events. I would very much appreciate it if someone who can debug code could figure out what the source of this problem is. Curiously, and fortunately, this problem does NOT occur when ViewTouch runs on the Raspberry Pi, both Jessie or Stretch. As of August 1, 2018, this problem no longer occurs under Debian 9 Testing.

[suggestion] You need to segragate read-only vs. writeable directories, and make the installed structure unix-like

Currently you install everything under $(PREFIX)/viewtouch/. This isn't how software is installed on unix-like systems. About every package there is installs binaries into $(PREFIX)/bin, data into $(PREFIX)/share/{name}. These two are read-only. The writable data can't go under $(PREFIX), it normally goes either into /var/db/{name}/, or is written into the home directory, or is written into some specifically designated, separate directory.

The above discrepancy is why no linux distros created a package for ViewTouch - it doesn't fit the way how they do things.

Here's what you can do to adjust:

  1. Expose the variable VIEWTOUCH_INSTALL_PATH as a cmake option, have "/usr/viewtouch" as a default. Install all read-only files under it, with data going into ${VIEWTOUCH_INSTALL_PATH}/share/ViewTouch, and executables - into ${VIEWTOUCH_INSTALL_PATH}/bin,
  2. Expose the variable VIEWTOUCH_DB_PATH for writable files. Keep the default of "/usr/viewtouch/dat", but this would allow people to set it to "/var/db/ViewTouch", for example.
  3. It writes into bin/.vtpos_command, this also should go under the writeable directory VIEWTOUCH_DB_PATH, etc.
  4. Ideally, you could also have a variable USE_HOME_DIR_FOR_DB, in which case it would just write the DB into a home directory.

If you make alterations that I am suggesting in the above instructions, it would be possible to install it into a single directory, like before, and in a way how unix-like systems install software.

I've ported ViewTouch, but encountered these discrepancies that prevent me from creating a port at this point.

unused-but-set-variables

I'm trying to squash some warnings. With the following variables I have no Idea what they should be doing. Can you shed some light on them? Maybe they were intended to do/check something

l_width

int l_len = 0, l_width = 0, r_len = 0, r_width = 0;

status

int status = -1;

ismanager

int ismanager = 0;

term_hardware

int term_hardware = 0;

firstmod

int firstmod = 0;

labor_percent

Flt labor_percent[MAX_SHIFTS];

can they savely be removed? or should they be used for something?

Please do not install the 'date' library

These files should be used only internally, and there's no need to install them:

include/date/chrono_io.h
include/date/date.h
include/date/ios.h
include/date/islamic.h
include/date/iso_week.h
include/date/julian.h
include/date/ptz.h
include/date/tz.h
include/date/tz_private.h
lib/cmake/date/dateConfig.cmake
lib/libtz.a

Graphics files

The graphics files - These should be comitted to this repository as well.
How can they be added by a user, can they be designed by a user? If so, which resolutions?

Touchscreen Lag has disappeared for Debian Testing users.

I am happy to report that the touchscreen 'lag' bug no longer affects ViewTouch running under Debian 9 Testing. The bug still exists in Debian 9 Stable, however. I don't know which code update in which package is responsible for fixing this bug. There are many thousands of packages in Debian and in any Linux Distribution, but one has to suspect that the bug was in one of the xorg files.

Debian 9 Testing is actually quite stable and is certainly MUCH more up to date than Debian 9 Stable is. It's quite a thrill to be able to run ViewTouch on the latest Intel and AMD processors again, although ViewTouch production systems will continue to ship on the newest Raspberry Pi 3 Model B+ which features a XFCE desktop with many Point of Sale Customized Features and Functions.

Revenue & Productivity Report Bug

One of the few remaining bugs is in the "Reports" area when selecting "Accounting: Receipts Balance & Cash Deposit" report. Selecting this causes the program to crash.

New vt_data file

The vt_data file is a rather unique file; it is the graphical user interface which is largely created not by the source code but by the GUI building tools available in ViewTouch's Edit Mode.

I have used Edit Mode as SuperUser to make a LOT of changes which I regard as improvements and enhancements to this file and the ViewTouch GUI in the past few weeks. Today (December 8, 2017) I have uploaded the latest version of this file to http://www.viewtouch.com/vt_data. Anyone running ViewTouch can simply go to this web link and download the latest version of vt_data to their computer.

Typically, people have been taught to expect that only improvements can be made to software through changes in the source code, but ViewTouch is different in this regard. Improvements and enhancements in the GUI are usually made by making use of the integrated Edit Mode of ViewTouch, the same Edit Mode which is used to create point of sale menus for the hospitality organizations which use ViewTouch.

Go ahead and download the latest vt_data, copy it to /usr/viewtouch/bin and enjoy what I feel is a much improved collection of Pages in the Administrative Index, aka the 'backend' of the PoS system!

RaspberryPi Image: a journey

I'd like to log my adventures using the Rapsberry Pi image http://viewtouch.com/RPi.debian9.img.bz2

  • I've loaded the Image to a 32GB SDHC card (previously used Kodi) and put it into my RPi 3B
  • RapsberryPi starts, xfce visible and up and running
  • try to run viewtouch (using the button on the right side linked to /usr/viewport/bin/runonce)
  • ViewTouch interface stays black with the following message unable to find jump target (-1,5) for ViewTouch Host Computer
  • hmm, what to do next? Maybe update Viewtouch. Pushing pull-build button. Terminal starts and vanishes again
  • Manually starting ./pull-build in /home/viewtouch/viewtouch directory
  • Pb src directory not clean (build timestamp), removing the conflict using git checkout build_number.h and trying again
  • Getting error src directory does not exist". ~/src/viewtouch directory is wrong. On the image it is just ~/viewtouch
  • After updating the pull-build script cmake works the RPi hard, compiles and installs the updated viewtouch binaries
  • Restart to be safe. run /usr/viewtouch/bin/runonce again, just to get the same error unable to find jump target (-1,5) for ViewTouch Host Computer again

I hope this little story helps :)

If I can try anything else or I've forgotten to provide essential information please let me know

As yet unresolved warnings in GCC 7 & GCC 8

There has been an especially great deal of development in the GNU C++ compiler in recent years. If one compiles with GCC 6 or earlier you will not get warning messages when compiling but compiling with GCC 7 or GCC 8 there will be multiple warning messages. As of today, May, 2018, the latest release of GCC is 8.1. These warning messages can, of course, be eliminated by anyone who would compile under GCC 7 or GCC 8 and update the code in response to the stricter warnings of GCC 7 and GCC 8.

Transfer of user data files in /usr/viewtouch/dat to another Raspberry Pi can cause a program failure

Hope this proves useful to someone.

Going from an Intel NUC to a Raspberry Pi 4.

First discovery is that due to the variation in actual sizes of SD cards the 32G image file available to use for Raspberry Pi was 96 megs too big. I ended up just imaging a 64G card. I'm sure I could have somehow reduced the image size but didn't waste any time on that.

Once Raspberry Pi was running and verified ViewTouch launched I copied the files from the NUC /dat/ folder to the Raspberry Pi.

Launching ViewTouch now abruptly crashes just as the GUI is about to load with no indication in the log file as to what caused it.

After systematically moving files over I discovered the issue was a /dat/text/command.log file which seems to have network settings specific to the NUC. I deleted this file and ViewTouch now loads all the way into the GUI with all the settings, menus, etc where they should be.

blobfish.h defines unsigned int to be 32bit long

/* Define IntU32 to be an unsigned in 32 bits long */
typedef unsigned int IntU32;

this was true for 32bit linux, but is not true anymore for amd64 systems. I have no idea if this may lead to problems, but I'd like to document this flaw

To get a real 32bit unsigned int the uint32_t type from stdint.h can be used http://www.cplusplus.com/reference/cstdint/

As a side question: This header was introduced with C++11, is it OK to require newer C++ versions like C++11 or C++14 (or even C++17?)

Cmake Error at CMakeLists.txt

from the build directory, when issuing the cmake .. command
Cmake Error at CMakeLists.txt:181 (add executable)
Target "vt_main" links to target "Freetype::Freetype" but the target was not found.
Perhaps a find_package() call is missing for an IMPORTED target, or an ALIAS is missing?

Cmake Error at CMakeLists.txt:216 (add executable)
Target "vt_main" links to target "Freetype::Freetype" but the target was not found.
Perhaps a find_package() call is missing for an IMPORTED target, or an ALIAS is missing?

when issuing the make command
Linking CXX executable vt_main
/usr/bin/ld: cannot find -lFreetype::Freetype

Add GitHub Actions for better CI integration

GitHub doesn't show travis-ci pipelines anymore (at least not for me). GitHub itself now provides CI capabilities with GitHub Actions

I think the Catch2 workflows could be a good reference to create Actions for ViewTouch

https://github.com/catchorg/Catch2/blob/devel/.github/workflows/linux-simple-builds.yml

as base image I suggest using ubuntu-20.04 or maaaaaybe ubuntu-latest

https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners

I'd like to keep the explicit debian builds. For that we need to still use docker images

https://docs.github.com/en/actions/creating-actions/creating-a-docker-container-action

Executable Descriptions

I'm trying to figure out what the executables are doing and how they can be used.

vt_cdu

connect to a printer? A touchscreen? What is a CDU

vt_main

main thread. Can't directly start from command line, always exits

vt_print

connect to a printer?

vt_term

open a user terminal? GUI?

vtpos

main binary, runs vt_main, opens GUI, only executable that stays open

is it possible to have a raspberry PI as central (headless) server and other devices with touchscreens (PC oas well as Android Devices) connect to the raspberry/server?
How are printers included into the system? Could you give me a high level overview on how a viewtouch system (with multiple endpoints and printers) is set up? I can't seem to figure out how viewtouch works (just schematic)

A couple of minor bugs, one fixed!

There are a couple of quite minor bugs in the current code.

  1. When exiting Edit Mode the message at the top center of the screen is "Saving" should only be shown for about one second but it is persisting.
  2. When adding a new menu button the name given to the new button appears in duplicate. For example, a new button with the intended name 'Tomato Soup' becomes 'Tomato SoupTomatoSoup'.

OK, you've downloaded and compiled the code. what next?

When you first run ViewTouch there are several directories and several files which are automatically created, but there are some files you need which are not automatically created. Here's how you can copy them from the ViewTouch web site to the proper directories in your file system

curl -O http://www.viewtouch.com/vt_data /usr/viewtouch/bin
curl -O http://www.viewtouch.com/tables.dat /usr/viewtouch/dat
curl -O http://www.viewtouch.com/menu.dat /usr/viewtouch/dat
curl -O http://www.viewtouch.com/zone_db.dat /usr/viewtouch/dat

The file sizes for these files should be:

  1. 65127 vt_data
  2. 239 tables.dat
  3. 5305 menu.dat
  4. 1713 zone_db.dat

If you don't get these file sizes, try these curl commands

curl -O http://www.viewtouch.com/viewtouch.com/vt_data /usr/viewtouch/bin
curl -O http://www.viewtouch.com/viewtouch.com/tables.dat /usr/viewtouch/dat
curl -O http://www.viewtouch.com/viewtouch.com/menu.dat /usr/viewtouch/dat
curl -O http://www.viewtouch.com/viewtouch.com/zone_db.dat /usr/viewtouch/dat

ViewTouch has a lot of internal documentation which is now accessible from a new 'Documentation' button in the upper right corner of Page One. The documentation has long been there but it was not readily accessible from Page One. Without vt_data you cannot reach Page One, where everything begins. It is the 'Home Page' for the ViewTouch application.

The first command above will provide all of the graphics ViewTouch needs except for Table Pages and Menu Pages. A 'Starter' set of Table Pages arrives with the second command. A 'Starter' set of Menu Pages arrives with the combination of the third and fourth commands because the Menu Page file must be accompanied by the Zone Database file. The Zone Database file is the appearance of all the buttons themselves and the Menu is the information which populates the buttons.

There is a Copyright button at top center of Page One which contains buttons which will perform the same functions as the 2nd, 3rd and 4th curl commands above.

I have seen a lot of graphical toolkits over the years but I do think that ViewTouch outstrips them all because it has the advantage of being created for a specific target, a real purpose in the real world - Point of Sale, which is an advantage over challenge one faces when developing a new desktop or window manager. I identified and met the unique requirements of Point of Sale Software in 1986 when I created the first graphical touchscreen point of sale software. These requirements are:

  1. the user interface is never complete until the end user, the customer, completes it
  2. the interface which remains to be created will be unique in every case.
  3. the point of sale software must include all of the tools and instructions which enable users to complete the interface.

The software must, therefore, of course, be intuitive and simple, for each end user, customer, to learn and to use to complete the interface. The 'Starter' Pages mentioned above are the beginning of the journey to do this.

One is in pretty good shape with these files - the application will run - but it will be incomplete until the unique Table and Menu Pages have been created, and these Pages then populated with Table Buttons and Menu Item Buttons. Menu Item Buttons will need support from Modifier (Descriptor) buttons and Qualifier Buttons. The analogy of nouns, adjectives and adverbs applies to these Button types.

The process of traversing ViewTouch Pages and the Buttons on them is a serial process which is quite similar to moving within a hierarchy of higher and lower levels. It is largely automatic but it is also somewhat, and crucially, dependent upon how the Menu Pages and Buttons are built. This is covered in the program's internal documentation.

My phone number is available, as is my email and the tools here at github for everyone who has questions. Thank You for your interest in ViewTouch and for your appreciation for software and user interface ideas which will soon be in its Sixth Decade!

Issues with vt_data

Hi all,

Has anyone else experienced the bizarre phenomenon of the vt_data file provided on viewtouch.com failing to download correctly via wget (as the update.sh script states that the checksum has failed) but, if manually downloaded, resulting in a weird series of invalid POSZone types and pages? It ultimately ends in "Unable to find jump target (-1, 10) for ViewTouch Host". When I emailed Gene I thought it had something to do with endianness as it seems primarily to happen on AMD64, on an ARM device the downloaded vt_data file looks quite different in certain places. However, if either is converted with dat2txt in /scripts, they both look reasonable. What is irritating is that on the "cursed" architectures (or devices) on which this occurs, I am yet to find a reasonable solution. It has something to do with the base64 decoding in data_file.cc which is obviously not working properly according to some circumstances. What I can't work out is whether the file is genuinely corrupt when the CRC checksum fails or whether it's purely to do with the difference in machine architecture. Either way, vt_data should be wrapped as a tar.gz even though it's already a gzip stream to ensure that endianness and length is protected.

If anyone has encountered this frustrating issue I'd really love to know how you solved it!

Cheers, Nick

tz needs timezone database

tz needs IANA timezone, this is provided by the tzdata package on Ubuntu. Otherwise TimeInfo::Set() throws an exception

  • update CI
    • update Ubuntu Dockerfile to install package
    • update Debian Dockerfile to install package
  • update readme for runtime dependencies

Running GDB (the GNU Debugger): Update

How to Debug with GDB: Frank Graziano offers this correction / update.

Open two terminals, Window 1 and Window 2.
Window 1:
gdb vtpos
b 153 - this is where loader calls vt_main
run

Window 2:
gdb vt_main
b xxx - any line number

Window 1:
jump 154 - skip over calling vt_main

Within a few seconds switch to Window 2 and issue GDB command:
run /tmp/vt_main

GDB will run vt_main, stopping at the specified breakpoint.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.