Hello,
I'm working on a set of S-Functions to interface with an implementation of Open Sound Control (liblo to be complete). I have 'blocks' that set up a nlo_server, an lo_address, send and receive. The blocks setting up the server and address have no inputs, the send and receive blocks expect at least the connection as their 1st input.
The code itself works correctly, but I must have missed something concerning sampletimes. I run a test model with a fixed, 1ms fundamental timestep and an ode4 (Runge Kutta) solver (this is what's used in the models where my S-functions will be deployed). It seems my functions are not called at the (1ms) fundamental sample time, but once a simulated second only.
I specify that my functions should use inherited sample time in the mdlIntializeSampleTimes method, and have no discrete or continuous states. Where am I going wrong?
I'm working on a set of S-Functions to interface with an implementation of Open Sound Control (liblo to be complete). I have 'blocks' that set up a nlo_server, an lo_address, send and receive. The blocks setting up the server and address have no inputs, the send and receive blocks expect at least the connection as their 1st input.
The code itself works correctly, but I must have missed something concerning sampletimes. I run a test model with a fixed, 1ms fundamental timestep and an ode4 (Runge Kutta) solver (this is what's used in the models where my S-functions will be deployed). It seems my functions are not called at the (1ms) fundamental sample time, but once a simulated second only.
I specify that my functions should use inherited sample time in the mdlIntializeSampleTimes method, and have no discrete or continuous states. Where am I going wrong?