B4J Question Problem with new install

Discussion in 'B4J Questions' started by stevewidget, Jul 13, 2019.

  1. stevewidget

    stevewidget Member Licensed User

    Hi,
    THanks to Microsoft I have had to change my computer to W10. I reinstalled B4J but am having issues with some software that worked on my old machine.
    Its basically the Chat program, slightly modified to not use prefix mode (using a PSOC not Arduino so B4R not option)
    I changed just this line ( I think)
    astream.Initialize(sp.GetInputStream, sp.GetOutputStream, "astream")
    It compiles OK. Sees list of COMPORTS , but as soon as I try to connect it crashes with the following
    #
    # A fatal error has been detected by the Java Runtime Environment:
    #
    # EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000000007110b5db, pid=18508, tid=16992
    #
    # JRE version: OpenJDK Runtime Environment (11.0.1+13) (build 11.0.1+13)
    # Java VM: OpenJDK 64-Bit Server VM (11.0.1+13, mixed mode, tiered, compressed oops, g1 gc, windows-amd64)
    # Problematic frame:
    # C [jSSC-2.8_x86_64.dll+0xb5db]

    Attached is the error log.

    Is this anything to do with Java version, or have I forgotten something .

    Thanks

    Steve
     

    Attached Files:

  2. stevewidget

    stevewidget Member Licensed User

    Update Making things worde.

    OK I realised I wasnt using the latest version so updated to 7.51. Now it doesnt compile!!!
    Is the correct way to update to do a full install over top?

    Log ( Source not changed)
    B4J Version: 7.51
    Java Version: 11
    Parsing code. Error
    Specified argument was out of the range of valid values.
    Parameter name: index

    Steve

     
  3. Peter Simpson

    Peter Simpson Expert Licensed User

    @stevewidget have you tried
    1. Deleting the .meta file
    2. Cleaning the project
     
  4. stevewidget

    stevewidget Member Licensed User

    Thanks Pete,
    Tried that, no differrence, but certainly will intrdouce as standard procedure in future.
    My main concern is , is there any changes due to java11 that might affect jserial? or is it my new setup, or my forgetting something obvious.

    Steve
     
  5. Erel

    Erel Administrator Staff Member Licensed User

  6. stevewidget

    stevewidget Member Licensed User

    Thanks Erel,
    that fixed it!! I assume that master libraries are automatically reloaded on update, but is there any way/documentation on user libraries that need updating, other than trawling the forum.
    Once again thaks.

    Steve
     
  7. stevewidget

    stevewidget Member Licensed User

    Perhaps I spoke a little too quickly. Although it does accept data from my device, I note the following in the log

    Waiting for debugger to connect...
    Program started.
    jssc.SerialPortException: Port name - COM5; Method name - getInputBufferBytesCount(); Exception type - Port not opened.
    at jssc.SerialPort.checkPortOpened(SerialPort.java:878)
    at jssc.SerialPort.getInputBufferBytesCount(SerialPort.java:802)
    at anywheresoftware.b4j.serial.Serial$1.read(Serial.java:128)
    at anywheresoftware.b4j.serial.Serial$1.read(Serial.java:123)
    at anywheresoftware.b4a.randomaccessfile.AsyncStreams$AIN.run(AsyncStreams.java:199)
    at java.base/java.lang.Thread.run(Thread.java:834)
    java.lang.RuntimeException: jssc.SerialPortException: Port name - COM5; Method name - getInputBufferBytesCount(); Exception type - Port not opened.
    at anywheresoftware.b4j.serial.Serial$1.read(Serial.java:138)
    at anywheresoftware.b4j.serial.Serial$1.read(Serial.java:123)
    at anywheresoftware.b4a.randomaccessfile.AsyncStreams$AIN.run(AsyncStreams.java:199)
    at java.base/java.lang.Thread.run(Thread.java:834)
    Caused by: jssc.SerialPortException: Port name - COM5; Method name - getInputBufferBytesCount(); Exception type - Port not opened.
    at jssc.SerialPort.checkPortOpened(SerialPort.java:878)
    at jssc.SerialPort.getInputBufferBytesCount(SerialPort.java:802)
    at anywheresoftware.b4j.serial.Serial$1.read(Serial.java:128)
    ... 3 more
    I'm pretty sure no data was being sent before program started.
    Whats this please

    Steve
     
  8. stevewidget

    stevewidget Member Licensed User

    Sorry
    discount above, it only appearrs after I close program.
    Too early on a Monday morning!!!
    Steve
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice