MATLAB: Does the Inport block inherit data type from the block it is connected to, when its datatype is set to ‘auto’ in Simulink 6.4

simulink

When I execute the RootInportDataTypeError.mdl whose Inport block's datatype is set to 'auto', by first loading the RootInportDataTypeError.mat file, I receive the following error:
Invalid data type for root level inport 'RootInportDateTypeError/In1'. The model is configured to load its root level inports from the workspace. These external inputs must have data type 'double'. This data type does not agree with the data type, 'boolean', that is being set for this root level inport. Loading external inputs from the workspace is turned off by going to the Simulation menu and selecting Configuration Parameters. On the Data Import/Export page, locate the Load from workspace group and uncheck the Input checkbox.
Since in the simulation environment, the root inport must be a double, the Constant block should inherit the double type from the root inport (rather than incorrectly inheriting the boolean type from the OUTPUT of the comparison block). This would allow the system engineer to use the model without concern for typing issues while the software engineer can use the exact same model with mpt parameters to generate code with the desired signal typing.

Best Answer

The ability to inherit datatype in the forward direction when the datatype of the Inport port is set to 'auto' is not available in SIMULINK 6.4.
To work around the issue explicitly set the data type of the Inport block to 'double' by double clicking on the Inport block and then going to Signal Specification tab and selecting double for ' Data Type'.