Use generated code from Simulink Model in Thingspeak

조회 수: 1 (최근 30일)
Artyom
Artyom 2019년 10월 24일
댓글: Peret Lopez 2020년 1월 8일
Hello
I know, that it should be possible to use Simulink-generated code at the edge, which would work with ThingSpeak Data.
But is it possible to deploy generated code at the cloud (e.g. in Thingspeak) to receive a kind of cloud controller for IoT devices, which would receive sensor data, do analitics/control periodically or in response to some event and send commands back over MQTT to IoT devices?
I know this would be a very slow controller, but the main Idea to have it simulated in Simulink, rather than in MATLAB.
Thanks for feedback.

답변 (2개)

Peret Lopez
Peret Lopez 2020년 1월 7일
Very interesting question. I am wondering whether it is possible to publish to a MQTT server. I woul like to publish outputs from a MATLAB Analysis app. That is the way I have thought about to populate results from the MATLAB Analysis app.
  댓글 수: 2
Vinod
Vinod 2020년 1월 7일
Peret: Once you install the MQTT in MATLAB addon, you can publish messages to any MQTT broker of your choice, including ThingSpeak.
Peret Lopez
Peret Lopez 2020년 1월 8일
Can I install addons in ThingSpeak engine? That is my concern

댓글을 달려면 로그인하십시오.


Vinod
Vinod 2020년 1월 7일
It is certainly possible to do, but requires some engineering of wrappers to expose the MATLAB code as a service.
Do you mind writing to vcherian <at> mathworks <dot> com with more details -- what kind of system are you simulating? How often does your device going to call the service? How many devices are going to be connected to the controller in the cloud at any given time? Are the control outputs for each device independent of the other devices? Does your controller need knowledge of previous state of the system?

커뮤니티

더 많은 답변 보기:  ThingSpeak 커뮤니티

카테고리

Help CenterFile Exchange에서 ThingSpeak에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by