communicating with USB cash drawer

gphillipk

Registered
Hi guys,
I'd like to know if it's possible to send commands (using Terminal) to a USB cash drawer (part of a Point of Sale setup) in order to pop the drawer open.
Here's an example of how I do it in DOS:
command:CON>LPT1
type Ctrl + G then Enter
will simply pop open the cash drawer if its connected to LPT1
If it is, please post commands or resources which I can use. Thanks in advance.
 
I don't think it would be that easy. Plug it in and see if there are any new entries in the /dev folder. Then you can pipe some input into the device file. However, it is more likely that Mac OS would not have any suitable drivers for it, so you would have to write a program.
 
That command should not work for a USB drawr under DOS, IIRC. That is for a parallel connection. So your first task is figuring out how it connects via usb. If it presents a serial interface then all you have to do is type

cat > /dev/serial_device_name
Ctrl + g
Enter
Ctrl + d

The last Ctrl + d will close the pipe and return to the command line.

So I think it would work fine if we can get the connection stuff figured out.
 
if you know the trigger code, then perhaps you can try this

echo -e "trigger code" >/dev/serial_device_name
 
Back
Top