Commit 6b04cace authored by Hafiz Muhammad Wahaj Aziz's avatar Hafiz Muhammad Wahaj Aziz
Browse files

sampling time is now converted to milliseconds

refs 3281
parent ea1c1a05
......@@ -77,6 +77,8 @@ import org.fortiss.af3.project.extension.data.Executable;
* @author aravantinos
*/
public class FMUGeneratorExecutionTarget extends ExecutionTargetBase {
/** {@inheritDoc} */
@Override
......@@ -201,7 +203,8 @@ public class FMUGeneratorExecutionTarget extends ExecutionTargetBase {
message += baseMsg + "return a constant value.";
} else {
// Multiplying with 1000 to convert time to milliseconds
samplingTime = ((DoubleConst)returnStatement.getValue()).getValue();
samplingTime =
((DoubleConst)returnStatement.getValue()).getValue();
}
}
}
......@@ -227,7 +230,7 @@ public class FMUGeneratorExecutionTarget extends ExecutionTargetBase {
samplingTime = 1 / lastSelectedFrequency;
}
final double toMilliseconds = 1000.0;
samplingTime = samplingTime * toMilliseconds;
samplingTime = samplingTime*toMilliseconds;
return samplingTime;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment