Community mailing list archives

community@mail.odoo.com

POS Odoo 8 on Mac

by
Alejandro Perez Cosio
- 03/17/2015 11:38:31
Hello all, 

I got a TM20II printer and I’m trying to run Odoo 8 with hw_escpos module to print the receipts from my macbook (OS X 10.10.2), but when I install hw_escpos and go to localhost:8069/hw_proxy/status I get some errors at the console:

------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/ale/Projects/odoo/addons/hw_escpos/controllers/main.py", line 158, in run
    printer = self.get_escpos_printer()
  File "/Users/ale/Projects/odoo/addons/hw_escpos/controllers/main.py", line 115, in get_escpos_printer
    printers = self.connected_usb_devices()
  File "/Users/ale/Projects/odoo/addons/hw_escpos/controllers/main.py", line 103, in connected_usb_devices
    if usb.core.find(idVendor=device['vendor'], idProduct=device['product']) != None:
  File "/Users/ale/.virtualenvs/odoo/lib/python2.7/site-packages/usb/core.py", line 1199, in find
    raise ValueError('No backend available')
ValueError: No backend available
------------------------------------------------------------

Exception in thread Thread-5:
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 810, in __bootstrap_inner
    self.run()
  File "/Users/ale/Projects/odoo/addons/hw_escpos/controllers/main.py", line 197, in run
    if printer:
UnboundLocalError: local variable 'printer' referenced before assignment

(I’m also getting this last one in ubuntu)


After this, I’m getting a 500 internal error at the browser and if I try to print a receipt from the POS, I get this (which seems to be fine), but nothing is being printed.

2015-03-17 15:26:56,473 10660 INFO odoo-9 werkzeug: 127.0.0.1 - - [17/Mar/2015 15:26:56] "GET /hw_proxy/hello HTTP/1.1" 200 -

Did you ever had these errors? how can I solve it?


Thanks in advance, regards

Alejandro