Data Logging of events along with Time using SimEvents 2016a

347 views Asked by At

I am working with SimEvents 2016a to simulate an Manufacturing Assembly line which can handle multiple Variants (ex.: part 1 is for BMW 5-series, part 2 for BMW 3-series, something like that)

I would like to record data coming IN and going OUT of the model. Data such as:

  1. Part ID
  2. Time Spent at each Block (Block such as: Entity server or Queue...) [As far as my understanding on this, it similar to timestamping the entity at every block it passes through]

These data I would like to transfer to another Excel file (initially to the workspace at least).

It would be grateful, if any resources or methods to implement it or tutorial is shared so that I implement the above mentioned. :)

1

There are 1 answers

0
titus On

Here are a few helpful clues to complete your task :

  1. PartID : you can trigger a Simulink Function in the Event Actions of a standard block, and then write the output using the "To Workspace" block.
  2. Time spent at each block : you can get the current simulation time using the "get_param" function, and use that in Event Action scripts. Indeed, if you can stamp time, then you can evaluate the difference between entry and exit of an entity. However, make sure to write values in fields of the entity.

    get_param(bdroot,'SimulationTime')