Cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with connection text file.

Creator
Creator

Hello. I have small problem with connection text file.
In method init i have:

datafile.readFile("data.obj");

and when I start proces data from file goes to table but all machines dont moves and when i reset simulation and dont move data from table then everything works. What could be the reason for such thing?

4 REPLIES

Re: Problem with connection text file.

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor

maybe it takes a while to read the data, this may cause some problems in initializing the simulation. What exactly happens?

Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net

Re: Problem with connection text file.

Creator
Creator

This is my model, when I start simulation data from file goes to table "Źródło" and this is ok, but simuation works without the elements and then time is weird
model lewy 1.png

Re: Problem with connection text file.

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor

The source is faster in creating the events in the eventcontroller then your init-method. So the source don't find at the very start of the simulation entries in the table. You can solve this problem, if you use the reset-method instead of the init-method to fill the delivery table of the source (just rename the init-method into reset).

Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net

Re: Problem with connection text file.

Creator
Creator

it works, thank you very much