The earlier Derby mission
Again in June 2023, Lorraine Underwood from element14 Presents was impressed by the basic arcade sport ‘Derby’ and needed to indicate how far she and some others have run by constructing a customized model. This re-imagined setup concerned changing the jockeys with runners and having them transfer alongside a motorized observe till they reached the top. Maybe essentially the most attention-grabbing side is how the Arduino microcontroller fetches runner distance info from the Strava API dynamically, thus eradicating the necessity for handbook knowledge entry.
Designing a ladder
Carrying on with the theme of displaying group working distances, this new mission would change the aggressive aspect for a higher deal with collaboration in direction of a typical aim. A ladder, adorned with two strips of LEDs and pushed by a Raspberry Pi Pico W, reveals the gap everybody within the group has achieved by lighting up a sure amount relying on the cumulative miles of the workforce. Initially, Underwood thought-about snaking a single strip of LEDs all through the ladder, however realized that it might lose the ladder form as soon as illuminated, so she as a substitute positioned a strip on all sides and used translucent rungs to hold the sunshine throughout with out the necessity for further LEDs.
That is no moon; it is a house station
Every rung was 3D printed in a white materials which permits the sunshine to go by means of and create a shiny glow. In the meantime, the moon was shaped by layering strips of paper mache over a balloon and letting it dry. Establishing this mission was going effectively, till Underwood realized that the moon is sort of 240,000 miles away, or about 9.6x the circumference of Earth, making it an not possible problem to beat inside a yr. Nonetheless wanting to include an area theme, the moon was exchanged for a Lego Worldwide Area Station since it’s only 253 miles away.
Retrieving Strava knowledge
Identical to within the Derby working problem mission, there are a number of steps that have to be accomplished so as to get the working knowledge for everybody. First, Underwood’s entry token is retrieved by sending her consumer ID, secret, and refresh token to Strava’s authentication endpoint. Subsequent, that token is used to get a JSON payload containing all actions after a sure date, which in flip allows the entire distance to be accrued and saved to a variable.
Programming
Now that the entire working distance might be discovered, Underwood turned her consideration to how that info may finest be displayed. Every time the gap is fetched, LEDs on all sides are up to date with the particular runner’s colour to point not solely the gap, but in addition which runner has achieved it so as to add again a small aggressive aspect. A rainbow mode was additionally included as a enjoyable startup sequence.
Doable adjustments
Though the ladder works nice for displaying how shut everyone seems to be to the ISS, Underwood states there are a number of modifications she needs to make, with the primary one involving stealthier energy supply so ugly wires can’t be seen. Moreover, she has been toying with the thought of together with extra APIs, such because the one for the ISS’ present location, so the ladder can show when the station is shut through GPS and the web.
For extra info, you’ll be able to watch Underwood’s video right here on the element14 Presents YouTube channel.