Gemalto is now part of the Thales Group, find out more.

You are here

Problems accessing File System using MES under High System Load | Thales IoT Developer Community

September 24, 2021 - 11:14am, 214 views

Hi!

We're running a very demanding, multithreaded software on EHS5T, PLS62W, as well as ELS61 Modules and the problem we're experiencing is the following: Since the last expansion to our software, which increased the load on the system even more (additional RS485-Communication, using different parameters, as well as additional calculations) we're experiencing problems accessing the File System using MES at all, while the software is running.

The problem can be reproduced quite easily:
 

	protected void startApp() throws MIDletStateChangeException {
		new Thread(new Runnable(){
			public void run() {
                while(true)
                    ;
            }
		}).start();
	}

The problem is: i know it could be fixed in this case, by just implementing a Thread.sleep() / Object.wait() inside the loop.
This however, is a luxury, we can't have in our main software, since it has to react in realtime (or as near as possible to that) to different interfaces: Sockets, as well as server sockets, RS485 Communication to multiple devices that must not pause for more than ~5 seconds (at worst!), Logging.
I noticed that any sleep/wait can lead to much longer delays to my threads, than requested and noticed, that it isn't even always my own threads that are being executed in the meantime.
These are time frames, that are not comparable at all to the inaccurateness of Thread.sleep / Object.wait on PC systems, where the inacurracy is only in the millisecond-area.
Here, we are talking about Thread.sleep(60), which can take anywhere from 60ms to 60 seconds (but mostly only up to 10 seconds, which is already a big No-Go though!)...
This problem appears to get much worse, whenever the module fails to access the internet at the moment (in specific states, apparently).

According to a colleague, this problem appears to be worse on PLS62, compared to EHS5, which is something i actually couldn't reproduce myself, since i've been having problems accessing the modules using MES with the software running, for as long as i worked with this kind of hardware.

Please help!

Thanks!