Bulk update with thingSpeakWrite to a specified field
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Manfred
el 4 de Mayo de 2023
Comentada: Manfred
el 4 de Mayo de 2023
In the thingSpeakWrite documentation is an example, how to upload a table of data
....
thingSpeakWrite(writeChannelID,dataTable,'WriteKey',writeAPIKey);
This works, but the data are uploaded in Field1. How can i specifie the field - for example field 5?
thingSpeakWrite(writeChannelID,'Fields',[5],dataTable,'WriteKey',writeAPIKey);
or
thingSpeakWrite(writeChannelID,'Fields',[5],'Values',dataTable,'WriteKey',writeAPIKey);
did not work.
0 comentarios
Respuesta aceptada
Christopher Stapels
el 4 de Mayo de 2023
Editada: Christopher Stapels
el 4 de Mayo de 2023
myDates=datetime(2023,1,1):days(1):datetime(2023,1,10)
nullVec=string.empty(10,0);
myNums=1:10;
myTimeTable=table(myDates',nullVec,nullVec,nullVec,nullVec,myNums')
thingSpeakWrite(nnnnnnnnn,myTimeTable,'writeKey','xxxxxxxxxxxxxxxx')
Más respuestas (1)
Christopher Stapels
el 4 de Mayo de 2023
Make your data table with the first four columns of null values.
1 comentario
Comunidades de usuarios
Más respuestas en ThingSpeak Community
Ver también
Categorías
Más información sobre Tables en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!