Create a block to read keyboard inputs
이전 댓글 표시
I want to create a block in simulink which prompts me to enter a key & reads ASCII values from keyboard while running a simulation. Input to the block is through keyboard & output is its ASCII value.
I think this can be done either in S-function or embedded matlab function blocks. But I dont know how to use these blocks.
Can someone help???
채택된 답변
추가 답변 (1개)
Kaustubha Govind
2011년 6월 17일
편집: John Kelly
2015년 2월 26일
0 개 추천
The Embedded MATLAB Fcn block should be sufficient for your purpose. You can use the input function to read inputs from the keyboard.
Here is an example using the Embedded MATLAB Block: Creating an Example Model That Uses a MATLAB Function Block.
댓글 수: 2
Raju Purohit
2011년 6월 21일
Kaustubha Govind
2011년 6월 21일
You can use eml.extrinsic to call functions unsupported for code generation.
카테고리
도움말 센터 및 File Exchange에서 Event Functions에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!