Page 1 of 1

Java basic example crashes

Posted: Sun 2. Mar 2014, 10:50
by fengels123
Hi,
When I try to connect to the USB device, the application crashes by pressing the connect buttton
As channel I selected: PCAN_USBBUS1
Baus Rate: PCAN_BAUD_500K

I am using the 64bit version, JAVA demo 1.8.2 with java version 1.7.0_40

Can anyone help me?

#
# A fatal error has been detected by the Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000000007103c60c, pid=9480, tid=6264
#
# JRE version: Java(TM) SE Runtime Environment (7.0_40-b43) (build 1.7.0_40-b43)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (24.0-b56 mixed mode windows-amd64 compressed oops)
# Problematic frame:
# C [EMET64.dll+0xc60c]
#
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
#
# An error report file with more information is saved as:
# C:\Users\fengels\AppData\Local\My Local Documents\Workspace\PeakCan\hs_err_pid9480.log
#
# If you would like to submit a bug report, please visit:
# http://bugreport.sun.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#

Re: Java basic example crashes

Posted: Sun 2. Mar 2014, 22:31
by PEAK-Support
please read here and here - looks like you mix up the 32 and 64 Bit DLLs (JNI and PCANBasic)

Re: Java basic example crashes

Posted: Mon 3. Mar 2014, 15:09
by fengels123
I copied the dll's (PCANBasic_JNI.dll and PCANBasic.dll)in to the right dir c:\windows\system32 for the 32 bit files and C:\Windows\SysWOW64 for the 64 bit file, still did not work
I am using eclipse and set the path in the buidpath, but still the same error.
(libraries are also in C:\Users\engelsflm\AppData\Local\My Local Documents\Workspace\PeakCan\libs\win64)
javabuildpath.png
javabuildpath.png (80.07 KiB) Viewed 8172 times

Re: Java basic example crashes

Posted: Mon 3. Mar 2014, 15:35
by PEAK-Support
We have just tested it here with W7 and W8.1 on 32 and 64 Bit (both with 32Bit RT and on 64Bit also with 64Bit RT)
We use NetBeans Developer Environment - works fine - so it looks like a Eclipsed related problem - please ask Eclipse community. Our LIB, the JNI, PCANBasic DLL and also the Sample Code works fine.

Re: Java basic example crashes

Posted: Thu 13. Mar 2014, 13:29
by compauer
Had the same problem.
For me it helped to download the latest JDK.

Re: Java basic example crashes

Posted: Thu 13. Mar 2014, 13:40
by PEAK-Support
Works fine with Java 1.7_21 RT 32 & 64 Bit