How can I send variable from workspace to simulink?
이전 댓글 표시
I have a simulink model. And ı have a constant block that ı want to send to variable from workspace. How can I send?
답변 (1개)
Fangjun Jiang
2018년 2월 15일
0 개 추천
If you have the variable 'a' in base workspace, double click the Constant block, put in 'a' (without the quote) under "Constant value:"
댓글 수: 7
bayram özmen
2018년 2월 15일
Fangjun Jiang
2018년 2월 15일
which one you want?
1. A is changing from 0 to 30, increased by 1 at a time, run the simulation 31 times, or
2. Run the simulation just one time but the value of A is changing from 0 to 30? (you still need to specify how A is changed depending on the simulation time)
bayram özmen
2018년 2월 15일
Fangjun Jiang
2018년 2월 15일
In that case, it is not a "Constant" any more. Use the "Repeating Sequence" block from "Source" library. Specify the [StartTime EndTime] and [StartValue EndValue].
bayram özmen
2018년 2월 15일
Fangjun Jiang
2018년 2월 15일
That is something on a different topic. Double click the "Simulinnk-PS Converter" block, read the description regarding "derivatives", click the "Input Handling" panel, play with the "Filtering and derivatives" and "Provided signals:" settings.
bayram özmen
2018년 2월 15일
카테고리
도움말 센터 및 File Exchange에서 Sources에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!