how i can solve error Undefined function or variable 'thingSpeakRead' in matlab 2015a
조회 수: 10 (최근 30일)
이전 댓글 표시
writeChId = 123; % Replace with your channel number
writeKey = 'XXX'; % Replace with your channel write key
[temp,time] = thingSpeakRead(readChId,'Fields',4,'NumPoints',20);
humidity = thingSpeakRead(readChId,'Fields',3,'NumPoints',20);
tempC = (5/9)*(temp-32);
b = 17.62;
c = 243.5;
gamma = log(humidity/100) + b*tempC./(c+tempC);
dewPoint = c*gamma./(b-gamma)
dewPointF = (dewPoint*1.8) + 32;
thingSpeakWrite(writeChId,[temp,humidity,dewPointF],'Fields',[1,2,3],...
'TimeStamps',time,'Writekey',writeKey);
댓글 수: 0
답변 (1개)
Walter Roberson
2019년 5월 27일
thingSpeakRead was introduced in R2019a.
In your release, there were Simulink blocks available for Arduino and Raspberry Pi to write for ThingSpeak.
To read for thingspeak in your release, you would use webread(), or perhaps webwrite() . See the https://www.mathworks.com/help/releases/R2015a/matlab/ref/webwrite.html webwrite() documentation for your release for an example of writing for thingspeak.
댓글 수: 0
커뮤니티
더 많은 답변 보기: ThingSpeak 커뮤니티
참고 항목
카테고리
Help Center 및 File Exchange에서 Visualize Data에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!