ISS API

Attaching to open-source publicly available APIs are always a good way to learn about how to add external dynamic parameters. One particular source I love to begin with is the the latitude and longitude of the International Space Station. This is a fairly immutable external source (until it is decommissioned in 2030🔥) so I often use it as a basis for my work. Despite utlising JavaScript, these sketches are relatively lightweight. All examples both pull and parse JSON via a REST API – then draws to a ‘canvas’. With just 4kb being the largest file size so far!

Latitude & Longitude Terminal print (3kb)

Below is an example where I just print the Lat and Long, in the aesthetics of a traditional CLI terminal. This is live data, provided as a string. In creative programming, these parameters can manipulated in the code using basic arithmetic to allow for subtle or exaggerated changes in parameters.

Gizmo – interpolated motion (2kb)

Here the Gizmo lags behind a single fetch-cycle, this is because the ISS API only refreshes every second. I wanted a smooth transition for the 3d element and had to interpolate from the previous frame to the current one. I have also exaggerated its rotational axis by a factor of 50 so that movement is easier to interpret at a glance.

Gizmo with CRT shader (3kb)

I wanted the Gizmo to maintain the aesthetic of the CLI Terminal and so removed the interpolation and added a shader that introduces a CRT flicker, and retains the single-second update.

Combined

ISS Plot (4kb)

All of my examples thus far have been predictable use cases for ISS data. One last one is below and utilises the current altitude of the ISS. It plots its course over a rough projection of the earth. These examples live as a pseudo-instrumentation for monitoring such a satellite. The stroke-weight is larger when at a higher altitude and smaller at a lower altitude.