summaryrefslogtreecommitdiffstats
path: root/scripts/examples/location.qs
blob: 02d9e2eb3893d17374bf11ca47f2c0475c6057dc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// This script changes the current location every few seconds
// Interesting parts:
// location.latitude
// location.longitude
// location.altitude
// Check the documentation for a full list.

var i = 0;
while (i < 10)
{
    location.latitude += 0.0001;
    location.longitude -= 0.0001;
    location.altitude += 0.000001;
    location.useCurrentTimestamp = true;

    print ("Updated position:" + i);
    i = i + 1;

    yield(2000);
}