On Tuesday, September 8th a user posted "Cannot open POS" regarding
configuring javapos for a surepos 500. I have a surepos 741 (older
with rs485), and have had some success.
I used the svn version of ofbiz though I don't think that should
matter. I am on linux, but others can hopefully help with the
difference in operating systems. I am not familar enough with
windows.
One thing unusual I had to do was to create links in
/ofbiz/specialpurpose/pos to the /ibm/javapos and /javax-usb
directories.
ln -s /opt/ibm/javapos/ .
ln -s /opt/javax-usb/ .
Edited /ofbiz/specialpurpose/pos/ofbiz-component.xml to include those
directories.
<ofbiz-component name="pos"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/ofbiz-component.xsd">
<resource-loader name="main" type="component"/>
<classpath type="dir" location="config"/>
<classpath type="dir" location="styles"/>
<classpath type="dir" location="screens"/>
<classpath type="jar" location="lib/*"/>
<classpath type="jar" location="build/lib/*"/>
<!-- These 4 lines are the lines I added →
<!-- They must be relative to the current directory, possibly under
this directory →
<classpath type="dir" location="javapos/etc"/>
<classpath type="jar" location="javax-usb/lib/*"/>
<classpath type="dir" location="javax-usb/etc"/>
<classpath type="jar" location="javapos/lib/*"/>
Merged the correct devices from ibm jpos.xml into the
ofbiz/specialpurpose/pos/config/jpos.xml file.
This was easiest by using the IBM tools to create a jpos file and then
putting all of the devices from that into the ofbiz jpos.xml file.
Then modified ofbiz/framework/base/config/pos-containers.xml to use
the correct device from the jpos.xml file.
I then did an ant run-install and ant run-install-seed
After that everything worked.
I am using a sun-java with ibm java and javax-usb files in my system
class path, but it would not run links and changes to the
/ofbiz/specialpurpose/pos/ofbiz-component.xml file.
I have gotten both the pos printer an epson with an RS485 module that
mimics a model 4 and the ibm cash drawer RS485 working.
I would like to get the keyboard msr (not keyboard wedge) and display
device working but I am not sure they are implemented in ofbiz. IBM
does include sample code in their control center for both. I have
zilch in programming skills so that probably wouldn't help.
If anyone can give me some advice, I would give it a try though.