These are chat archives for CORE-POS/IS4C

17th
Aug 2016
danry25
@danry25
Aug 17 2016 00:28
Hmm, the receipt printer is showing its at /dev/usb lp2 and I've manually entered that in Lane Install under extras, but I can't print
I can echo things to this TM-T88V and it prints
Andy Theuninck
@gohanman
Aug 17 2016 00:28
permissions?
danry25
@danry25
Aug 17 2016 00:30
www-data is in the right group to access it
crw-rw---- 1 root lp 180, 2 Aug 16 20:20 /dev/usb/lp2
and www-data is in the lp group so it can access it
www-data@lane-4:~$ echo dickbutt > /dev/usb/lp2
that prints
but lane doesn't
Andy Theuninck
@gohanman
Aug 17 2016 00:34
Dunno. Check logs. Any issue printing ought to show up there. Otherwise it's a configuration problem.
danry25
@danry25
Aug 17 2016 00:38
which logs should I look at?
Andy Theuninck
@gohanman
Aug 17 2016 00:38
POS's
danry25
@danry25
Aug 17 2016 00:38
all I see in syslog is
Aug 16 20:37:54 lane-4 mono[702]: Received: goodBeep
Aug 16 20:37:54 lane-4 mono[702]: Received: rePoll
Aug 16 20:37:54 lane-4 mono[702]: Received: termReset
besides setting /dev/usb/lp2, is there anything else I should have done to enable the printer?
Andy Theuninck
@gohanman
Aug 17 2016 00:40
joel brock
@joelbrock
Aug 17 2016 00:41
check that reciept pritning is enabled in the receipt tab of Lane's install GUI.
If so try chmod 777 /dev/usb/lp2 and see if that helps
danry25
@danry25
Aug 17 2016 00:44
Damn, I'm being pretty dumb here, it was just not enabled under receipt. Thanks @joelbrock & @gohanman !
Ok, onto the pinpad
hardest part will be getting it internet :P
danry25
@danry25
Aug 17 2016 05:39
So I got the pinpad internet, everything worked for 2 transactions (1 cash, 1 credit) except the cash drawer (coin dispenser, receipt printer, scale/scanner, Pax Pinpad) and then i enabled the cash drawer and it stopped scanning. Then PHP5-FPM locked up with 5 open connections, then live weight also broke
danry25
@danry25
Aug 17 2016 05:54
I've disabled the Pax module and the coin dispenser, it will work for 1 transaction (but only pick up 1 barcode from /var/www/IS4C/pos/is4c-nf/scale-drivers/drivers/NewMagellan/ss-output when there are 7 in there, only after I scan a new item), then it stops scanning at all or displaying the live weight
danry25
@danry25
Aug 17 2016 06:40
I cleared out /var/www/IS4C/pos/is4c-nf/scale-drivers/drivers/NewMagellan/ss-output and turned off the customer display, same issue though
6 barcodes just fill up ss-output, and upon scanning the 7th it'll work a few times for the first and second transaction, then just stop working entirely
danry25
@danry25
Aug 17 2016 06:58
I'm going to give this 1 more go with an hour of my time tomorrow, and failing that we're just gonna tell this customer they have to go with Autostar + Datacap and pay what'll end up being $12k in licensing and hardware without signature capture or multistore
@joelbrock any chance I could get a hand with this issue around 11am EST?
Andy Theuninck
@gohanman
Aug 17 2016 12:01
What does "enabled the cash drawer" mean - is your drawer not connected through the printer? When the system stops responding can you even refresh the browser window or does that just hang? PHP5-FPM locking up sounds like you've got a request that hangs indefinitely (or a very long time) and further requests all deadlock waiting for that to complete.
danry25
@danry25
Aug 17 2016 13:14
I set kicker-kicker instead of the default, since the default kicker didn't seem to kick the drawer
danry25
@danry25
Aug 17 2016 15:33
@gohanman are you around
Andy Theuninck
@gohanman
Aug 17 2016 15:33
on & off
danry25
@danry25
Aug 17 2016 15:33
mk
I'm getting a red receipt with a red box around it in core. Lane status indicator is green
Also php5-fpm keeps crashing
^^ @thefinn93
Andy Theuninck
@gohanman
Aug 17 2016 15:49
Sounds like you're hitting https://github.com/CORE-POS/IS4C/blob/master/pos/is4c-nf/gui-modules/js/pos2.js#L98-L103 and the ajax request that prints the receipt is failing. It's possible the "failure" is just malformed JSON data, but if php5-fpm is crashing I'd guess that request is returning a non-200 status code. Your webserver and/or php5-fpm logs ought to show something about what's going wrong.
danry25
@danry25
Aug 17 2016 15:50
yeah
@thefinn93 want me to try printing a reciept?
you watching the logs?
[17-Aug-2016 11:34:00] WARNING: [pool www] server reached pm.max_children setting (5), consider raising it
2016/08/17 11:35:00 [error] 804#0: *18031 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 127.0.0.1, server: _, request: "POST /pos/is4c-nf/ajax/AjaxPollScale.php HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock", host: "127.0.0.1", referrer: "http://127.0.0.1/pos/is4c-nf/gui-modules/pos2.php"
Andy Theuninck
@gohanman
Aug 17 2016 15:56
That sounds like requests hanging or locking up so child processes are never released. And then the webserver times out waiting for php5-fpm
danry25
@danry25
Aug 17 2016 15:56
yeah
pretty much
only the cashier screen is up
there is no install pages up, or the customer display (I've disabled it)
Finn
@thefinn93
Aug 17 2016 16:04
note that it's actually timing out on a ton of requests
Andy Theuninck
@gohanman
Aug 17 2016 16:04
Well, once all php5-fpm's processes are blocked up, anything is going to time out
Finn
@thefinn93
Aug 17 2016 16:06
yeah
Andy Theuninck
@gohanman
Aug 17 2016 16:06
I've mostly seen this with printers. When PHP calls fwrite on a printer device that isn't ready (off, paper jam, out of paper, waiting to endorse a check, etc) it just hangs indefinitely.
danry25
@danry25
Aug 17 2016 16:08
the scanner just stopped responding @thefinn93
Finn
@thefinn93
Aug 17 2016 16:08
:\
danry25
@danry25
Aug 17 2016 16:08
I've got the red reciept with the box around it
Andy Theuninck
@gohanman
Aug 17 2016 16:08
Everything'll stop once php5-fpm can't service requests
Finn
@thefinn93
Aug 17 2016 16:09
/pos/is4c-nf/ajax/AjaxEnd.php?receiptType=full&ref=undefined&_=1471450040166
is the first request it breaks
danry25
@danry25
Aug 17 2016 16:09
also the receipt and cash drawer doesn't work
Finn
@thefinn93
Aug 17 2016 16:09
that breaks*
@danry25 does this happen if you set the receipt printer to a text file?
danry25
@danry25
Aug 17 2016 16:10
haven't tested
Andy Theuninck
@gohanman
Aug 17 2016 16:10
Good suggestion
Finn
@thefinn93
Aug 17 2016 16:11
if it's an issue with writing to the printer as @gohanman suggests, that would sort it out
danry25
@danry25
Aug 17 2016 16:11
I can print to the epson using echo
Finn
@thefinn93
Aug 17 2016 16:11
i know, i can too
danry25
@danry25
Aug 17 2016 16:11
php5-fpm is locked up up
Finn
@thefinn93
Aug 17 2016 16:11
so restart it
oh
oh shit i think it's the receipt printer
danry25
@danry25
Aug 17 2016 16:12
that is part of it
Finn
@thefinn93
Aug 17 2016 16:12
see how it's got the receipt printer subprocess spawned in the status?
danry25
@danry25
Aug 17 2016 16:12
yeah
Finn
@thefinn93
Aug 17 2016 16:12
that shouldn't be running for any amount of time
yeah, that's totally locking up
er, shit, i said receipt printer, i meant coin dispeners
i did not get much sleep
danry25
@danry25
Aug 17 2016 16:13
mk, I'll change it back from fakereceipt.txt
Finn
@thefinn93
Aug 17 2016 16:13
okay
Andy Theuninck
@gohanman
Aug 17 2016 16:13
Coin dispenser doesn't hook into the printer like a cash drawer, does it?
danry25
@danry25
Aug 17 2016 16:13
coin dispenser disabled
Finn
@thefinn93
Aug 17 2016 16:13
ok
@gohanman na, coin dispenser is a separate thing, connects over it's own serial port, etc
danry25
@danry25
Aug 17 2016 16:15
it seems better
I rang out a chas transaction
Finn
@thefinn93
Aug 17 2016 16:16
yeah, so the coin dispenser is locking up
im working on it now, if you could confirm that it's def plugged into /dev/ttyUSB0?
danry25
@danry25
Aug 17 2016 16:17
scanning/weighing is laggy
yep, its at /dev/ttyUSB0
Finn
@thefinn93
Aug 17 2016 16:17
kk
Andy Theuninck
@gohanman
Aug 17 2016 16:18
Out of curiosity, what's the coin dispenser code look like?
danry25
@danry25
Aug 17 2016 16:18
reciept prints but drawer doesn't pop
Finn
@thefinn93
Aug 17 2016 16:19
@gohanman it looks horrible
:P
it spawns a python script
cuz we couldn't get php serial stuff working
Andy Theuninck
@gohanman
Aug 17 2016 16:19
I meant functionally more the aesthetically
*than
Finn
@thefinn93
Aug 17 2016 16:19
uh, lemme check @asapdx wrote it
Andy Theuninck
@gohanman
Aug 17 2016 16:19
Whenever, obv less pressing than getting this working
danry25
@danry25
Aug 17 2016 16:20
@thefinn93 Drawer Behavior Module: got changed back to RAFC-Kicker
Finn
@thefinn93
Aug 17 2016 16:20
mmm
danry25
@danry25
Aug 17 2016 16:20
which only kicks the drawer on signout
I need kicker-kicker
Finn
@thefinn93
Aug 17 2016 16:20
okay, shut off Ansible on the fannie server
danry25
@danry25
Aug 17 2016 16:20
how?
Finn
@thefinn93
Aug 17 2016 16:20
crontab -e
danry25
@danry25
Aug 17 2016 16:20
kk
Finn
@thefinn93
Aug 17 2016 16:20
comment out the ansible line
as root
it tries to set as many defaults as possible, although it shouldn't be overriding them after the first run actually.....
hrmm
idk
danry25
@danry25
Aug 17 2016 16:22
I did
Finn
@thefinn93
Aug 17 2016 16:22
@gohanman so the coin dispenser has a plugin_transaction_reset() function that appears to calculate change, then it calls the python script
with the amount to dispense in argv1
danry25
@danry25
Aug 17 2016 16:22
also, it takes a good 30sec after the transaction for the reciept to print and drawer to kick
Andy Theuninck
@gohanman
Aug 17 2016 16:24
Primary culprits of slow receipt are either building the receipt text itself takes too long or transmitting data to the server takes too long. If cancelling a transaction rather than finishing it gives a receipt quicker, then it's a receipt text problem. If cancelling is just as slow, it's a data transmit problem
danry25
@danry25
Aug 17 2016 16:25
how'd I cancel?
Andy Theuninck
@gohanman
Aug 17 2016 16:26
CN
danry25
@danry25
Aug 17 2016 16:27
it prompts for password but it won't take my password
Finn
@thefinn93
Aug 17 2016 16:28
does it think it's in standalone mode?
danry25
@danry25
Aug 17 2016 16:28
I have manager priveleges
no
green indicator
not in standalone mode
Finn
@thefinn93
Aug 17 2016 16:29
hrm, any ideas @gohanman ?
Andy Theuninck
@gohanman
Aug 17 2016 16:30
Should take any password w/ employees.frontendsecurity >= 20
(by default; I think you can turn it up to 30 on the security tab)
Finn
@thefinn93
Aug 17 2016 16:31
is that on lane?
the lane db
i get the three db's on lane confused :(
danry25
@danry25
Aug 17 2016 16:31
I've gotta go
Finn, passowrd is 9317 if you wanna VNC in
we're gonna start loading this machine with Win8.1 here in about a half hour
Finn
@thefinn93
Aug 17 2016 16:32
yeah, and it has fronendsecurity = 30
danry25
@danry25
Aug 17 2016 16:33
are manager security provieleges sufficent?
Andy Theuninck
@gohanman
Aug 17 2016 16:34
should be
Finn
@thefinn93
Aug 17 2016 16:34
+--------+-----------------+---------------+-----------+----------+----------+-----------+------------------+-----------------+---------------------+
| emp_no | CashierPassword | AdminPassword | FirstName | LastName | JobTitle | EmpActive | frontendsecurity | backendsecurity | birthdate           |
+--------+-----------------+---------------+-----------+----------+----------+-----------+------------------+-----------------+---------------------+
|      1 | 9317            | 9317          | Dan       | Ryan     |          |         1 |               30 |              30 | 0000-00-00 00:00:00 |
+--------+-----------------+---------------+-----------+----------+----------+-----------+------------------+-----------------+---------------------+
danry25
@danry25
Aug 17 2016 16:34
I gtg
Finn
@thefinn93
Aug 17 2016 16:34
kk
17/08/2016 12:36:00 Using X display :0
17/08/2016 12:36:00 rootwin: 0xaa reswin: 0x1800001 dpy: 0x1187e00
:/
cant VNC in
oh nvm just gave it the wrong flags
yeah its not so much rejecting the password as simply re-displaying the password dialog
Finn
@thefinn93
Aug 17 2016 16:41
nothing in any of the debug logs
Andy Theuninck
@gohanman
Aug 17 2016 16:41
Sounds like a JS problem if the page is refreshing
Finn
@thefinn93
Aug 17 2016 16:43
ReferenceError: mgrlogin is not defined
Andy Theuninck
@gohanman
Aug 17 2016 16:43
well that isn't going to help
Finn
@thefinn93
Aug 17 2016 16:43
sorry, that happens after i correctly enter the password
Andy Theuninck
@gohanman
Aug 17 2016 16:43
Right, it's the onsubmit action on the form
Finn
@thefinn93
Aug 17 2016 16:44
there's also SyntaxError: missing ; before statement that comes up before i enter any password and after the mgrlogin is not defined
the missing ; is on line 10 of mgrlogin.js
yeah
Andy Theuninck
@gohanman
Aug 17 2016 16:49
CORE-POS/IS4C@90bef54. Not clear to me how acorn missed that
Finn
@thefinn93
Aug 17 2016 16:49
huh
idk, at this point he's setting up windows 8 for the other thing, im gonna go worry about other shit for now :(
danry25
@danry25
Aug 17 2016 17:20
Yeah, just re-enabled secureboot and am loading HP OEM Win8.1 onto this