简体   繁体   中英

Trouble with using Epson JavaPOS ADK 1.11.18.0

I recently bought a Epson TM-T20 Printer and I am currently trying to build a java application that will utilize this. I have the included JavaPOS that came with the printer installed and its related .jar files added into my build path. With all this said, I keep getting this error when trying to run some of the sample examples that are packaged along with it.

Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: no jp_co_epson_upos_firm_FirmNativeAccess_1_11_0001 in java.library.path

In case the rest of the trace stack helps

at java.lang.ClassLoader.loadLibrary(Unknown Source) at java.lang.Runtime.loadLibrary0(Unknown Source) at java.lang.System.loadLibrary(Unknown Source) at jp.co.epson.upos.core.v1_11_0001.pntr.CommonPrinterService.(Unknown Source) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Unknown Source) at jp.co.epson.uposcommon.creator.EpsonJposServiceInstanceFactory.createInstance(Unknown Source) at jpos.loader.simple.SimpleServiceConnection.connect(Unknown Source) at jpos.BaseJposControl.open(Unknown Source) at Step1Frame.processWindowEvent(Step1Frame.java:79) at java.awt.Window.processEvent(Unknown Source) at java.awt.Component.dispatchEventImpl(Unknown Source) at java.awt.Container.dispatchEventImpl(Unknown Source) at java.awt.Window.dispatchEventImpl(Unknown Source) at java.awt.Component.dispatchEvent(Unknown Source) at java.awt.EventQueue.dispatchEventImpl(Unknown Source) at java.awt.EventQueue.access$200(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue$4.run(Unknown Source) at java.awt.EventQueue$4.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue.dispatchEvent(Unknown Source) at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.run(Unknown Source)

OTHER INFORMATION

  • OS: W7 x64
  • IDE: Eclipse Juno Service Release 1 x64
  • Have the latest JDK installed
  • JavaPOS has a application called setupPOS. I have also added my printer in this setup

Any help would be greatly appreciated. Thank you

According to the java documentation the UnsatisfiedLinkError exception is:

Thrown if the Java Virtual Machine cannot find an appropriate native-language definition of a method declared native.

According to another question in SO that you can read here the problem might be in your library path. Try to include the option

-Djava.library.path=./XXX

Where ./XXX would be the relative or full path to where your printer driver may be stored (the directory where jp_co_epson_upos_firm_FirmNativeAccess_1_11_0001.dll or .so is located).

Good luck!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM