MATLAB: Do i receive error as invalid sample time in periodic subsystem(R2012b)

periodic subsystemssimulink

I am using a periodic subsystem in my simulink model. I am running the model with 50e-6 sample time and i want to run this particular subsystem at 1e-3 sample time. As soon as i change the sampletime of subsystem from '-1' to '1e-3', simulink is throwing the error saying 'Your model has an invalid sample time of 5e-05. Periodic atomic subsystem may contain only blocks that have constant (inf), inherited (-1), or periodic (0.001) sample times'. After this I checked the sample time of each block inside said automic subsystem, every block has '-1' (inherit) sample time. Still I am getting this error. please help.

Best Answer

error is occurring because parent subsystem was automic subsystem. You cannot have automic subsubsystem inside an already automic subsystem.