How to set channel setting (Mapable Value) Lat/Lon/Alt remotely over API or set from the last Lat/Lon/Alt location field values? | ThingSpeak API | Forum

The ThingSpeak community site has been upgraded to a new site. This site is currently in read-only mode. You can ask questions or post and read discussions on the new site.

Lost password?
Advanced Search

— Forum Scope —

— Match —

— Forum Options —

Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed sp_TopicIcon
How to set channel setting (Mapable Value) Lat/Lon/Alt remotely over API or set from the last Lat/Lon/Alt location field values?
No permission to create posts
December 10, 2020
4:32 pm
New Member
Forum Posts: 2
Member Since:
October 4, 2019
sp_UserOfflineSmall Offline

Dear Thingspeak Community,

The whole implementation of a separate and single Lat/Lon/Alt value under Thingspeak Channel settings that is not editable remotely with an API write key, as far a I know, has been a bit difficult. This is compounded by the confusion of having an identically named data field Lat/Lon/Alt that is not related to the channel setting Lat/Lon/Alt single value and not plotted natively on a map without maybe a plug-in or Matlab Mapping toolbox finagling.

Is there a simplistic way to update the mapable Lat/Lon/Alt value found under channel settings remotely using an API write key or an alternate way to automatically update the single channel setting Lat/Lon/Alt value using data from the most recent Lat/Lon/Alt updated using the API write key (same data visible when Location=true) in hopes that the map display will plot the new value? A last option would be a simplistic method to plot the last several Lat/Lon/Alt values written using the API write key would be fine too.

Future suggestions:
1) If there were a way to pull the header information using CSV at some point, that might be neat, as JSON and XML appear to be the only API method to do this and they are slower to retrieve data than CSV API call requests for data when tested in Matlab with tic; toc;
2) A method to view the exact screen visible under the Private tab with all 8 fields and map visible when a user enters and HTML channel address with read API key for channels set as private. It appears that the current method with API read key will only plot and display a single Field Plot for private channels, which is bizarre for a GUI inspired IoT system.


December 30, 2020
12:15 pm

Forum Posts: 885
Member Since:
March 7, 2017
sp_UserOfflineSmall Offline

There is a way to update the channel location via the API see the write settings documentation.

You can update the feed location using the normal write operation to the channel. Just add &longitude=long&lattitude=latt&elevation=height to your update api call. see write data.

The channel location represents where the data aggregation or analysis is happening. For example your home. If you were tracking a device with GPS, the device would post to the feed position information.

For example, if you look at this channel I have a channel with a fixed location, but the feeds have location information from walking around the grounds with a soil moisture and temperature sensor with GPS data. Each measurement has a slightly different location, but the channel location is constant. You can see more about the device here .

In your suggestions
1. what do you mean by header information? We are definitely interested in users that retrieve ThingSpeak information from MATLAB.
2. Are you talking about using the charts API? You can see the private view in the web interface. If you want to create a separate interface that looks like the web interface in MATLAB, you would have to make separate calls. Are you trying to replicate your channel view in MATLAB? this is an interesting use case.

FYI, MATLAB answers is the preferred location for ThingSpeak Community support.

Forum Timezone: America/New_York

Most Users Ever Online: 166

Currently Online:
16 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

rw950431: 272

Vinod: 240

piajola: 95

turgo: 70

vespapierre: 63

Adarsh_Murthy: 62

Member Stats:

Guest Posters: 1

Members: 8665

Moderators: 1

Admins: 2

Forum Stats:

Groups: 3

Forums: 14

Topics: 1600

Posts: 5760

Newest Members:

kusmumichael, petersmith99, Rambant, blakeharriss09, optisol, Niyonzima Fils

Moderators: cstapels: 460

Administrators: Hans: 405, lee: 457