how run .c program in matlab
現在この質問をフォロー中です
- フォローしているコンテンツ フィードに更新が表示されます。
- コミュニケーション基本設定に応じて電子メールを受け取ることができます。
エラーが発生しました
ページに変更が加えられたため、アクションを完了できません。ページを再度読み込み、更新された状態を確認してください。
古いコメントを表示
if i have program print.c
#include<stdio.h>
#include<conio.h>
main()
{
printf('hello')
getchar()
}
how i can run this code in MATLAB
採用された回答
Shashank Prasanna
2013 年 1 月 29 日
If you want to call your C function from within MATLAB you have to create a MEX file. Which mean you will have to modify your C code with the following guidelines:
8 件のコメント
Titus Edelhofer
2013 年 1 月 29 日
Or compile your C code in your favourite C programming environment into a dll/shared object and use loadlibrary to run it inside MATLAB.
rui gao
2019 年 4 月 26 日
How about now? I guess I can call C directly without the compiling. I am curious about it.
Walter Roberson
2019 年 4 月 26 日
It is not possible to call C or C++ directly from MATLAB without compiling the C or C++.
Noam Greenboim
2020 年 2 月 2 日
The links are not working anymore
LeChat
2020 年 4 月 17 日
indeed the links do not work anymore...
Walter Roberson
2020 年 4 月 17 日
The second one is currently at
I am not sure what the equivalent of the first one is. Possibly
LeChat
2020 年 5 月 14 日
thank you Walter
Francis Tiong
2021 年 11 月 3 日
Here is an updated link to the same topic:
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Write C Functions Callable from MATLAB (MEX Files) についてさらに検索
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Web サイトの選択
Web サイトを選択すると、翻訳されたコンテンツにアクセスし、地域のイベントやサービスを確認できます。現在の位置情報に基づき、次のサイトの選択を推奨します:
また、以下のリストから Web サイトを選択することもできます。
最適なサイトパフォーマンスの取得方法
中国のサイト (中国語または英語) を選択することで、最適なサイトパフォーマンスが得られます。その他の国の MathWorks のサイトは、お客様の地域からのアクセスが最適化されていません。
南北アメリカ
- América Latina (Español)
- Canada (English)
- United States (English)
ヨーロッパ
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
