Gateway crashing when trying to open serial port


I’m having an issue with a system that I’m playing around with. I’m trying to read from a serial port via a tag change gateway script, but every time i try to open it the gateway is crashing.
Gateway version 8.1.7 (b2021060314)

Looking at the wrapper log all I can see is :

INFO | jvm 2 | 2021/07/14 19:40:01 | I [p.DesignSession ] [18:40:01]: Socket connected to session. pageId=session-props session-project=Weighing_Room
ERROR | wrapper | 2021/07/14 19:42:02 | JVM exited unexpectedly.
STATUS | wrapper | 2021/07/14 19:42:07 | Reloading Wrapper configuration…
STATUS | wrapper | 2021/07/14 19:42:08 | Launching a JVM…
INFO | jvm 3 | 2021/07/14 19:42:08 | WrapperManager: Initializing…

I have tried using the system.serial. port script strait from the users manual, but it still does the same thing.

with system.serial.port(
** port = “COM3”,**
** bitRate = system.serial.BIT_RATE_9600,**
** dataBits = system.serial.DATA_BITS_8,**
** handshake = system.serial.HANDSHAKE_NONE,**
** hardwareFlowControl = False,**
** parity = system.serial.PARITY_NONE,**
** stopBits = system.serial.STOP_BITS_1) as port:**

** line = port.readLine(60000)**

Any thoughts?


What OS/version is the Ignition Gateway running on?

Hi Kevin

Server 2016 Standard.
Version 1607
OS Build 14393.4169


Are there any crash dump files in the Ignition install dir or nearby? Probably named hs_err_pid something…

No crash dump files at all :grimacing:

I thought the with (context manager) syntax for system.serial.port() was broken at the moment. Try without using it as a context manager.

The issues with context manager should have been fixed in 8.1.3, though @ggross is still seeing something weird going on with it.

@kevin.keefe Not sure what’s going on with your crash though. We’re unable to reproduce on Server 2016 here.

Issues I was seeing with the context manager were user error. It looks like it is working as expected in the 8.1.3+.

@kevin.keefe is there anything else within Ignition that might be connecting to the same serial port? Also, is Windows Device Manager showing everything being ok with the COM port?



All looks fine with the COM port.
As far as I can see, there is nothing else connecting to that specific serial port.

@Kevin.Herron : I’ll format & reinstall the OS tomorrow to see if anything changes

I’ve just noticed that the serial port monitor that i use is now playing up. Not sure if that is connected


Anything in Windows’ Event Viewer logs after you restart?

This is whats showning up in the Windows Event Viewer when the issue occurs:

Faulting application name: java.exe, version:, time stamp: 0x6069e9a2
Faulting module name: ntdll.dll, version: 10.0.14393.3986, time stamp: 0x5f77fd0d
Exception code: 0xc00000fd
Fault offset: 0x000000000002e7cd
Faulting process id: 0x2f90
Faulting application start time: 0x01d778f4c042846d
Faulting application path: C:\Program Files\Inductive Automation\Ignition\lib\runtime\jre-win\bin\java.exe
Faulting module path: C:\Windows\SYSTEM32\ntdll.dll
Report Id: 9d96e27b-02c2-4044-8b2b-2afbb2b7fb65
Faulting package full name:
Faulting package-relative application ID