There are two simulation level functions:
•vsmInit(). Called at Embed start-up. You use this function to insert one or more blocks in the Blocks menu.
•vsmEvent(). Called at simulation-wide events, such as simulation start, end of time step, and simulation end.