ISS Tracking Globe

The International Space Station is one the pinnacles of human technology and who wouldn’t like to know his location at every minute? Of course, no one.

So, in this Instructables we are going to show you how to build a location tracker using leds, a stepper motor and a NodeMCU. The globe with his base were bought at a local craft store and all the other components could be purchased at any online electronics supplier.

It was supposed to be an afternoon project, but it took us (a two members group) almost two days to build it, mainly by rusted programming skills and mechanical problems trying to assembly it all together, but by following this Instructables (instead of winging it like us) it should not take a person more than an afternoon to build it once the material have been acquired.

Tools:

  • Hot glue gun.
  • Small electric Drill.
  • Needle .

Components:

  • 24 x Leds.
  • 3 x 74HL595.
  • 1 x Power supply 5V.
  • 1 x NodeMCU.
  • 1 x Stepper motor + driver.
  • Wires
  • 1x 47k Resistor (value not critical, can be anything from 10k to 100k).
  • 1x 250 Ohm Resistor 0.5W .
  • 1 x Plastic straw (or anything to attach the shaft of the motor to the globe).

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1: Latitude Indicator - Adding LEDs

To indicate the latitude of the ISS we're going to use LEDs mounted on the support of the globe, for this we need to:

  • Mark the equator on the arc of the support followed by increments of 5 degrees in both directions.
  • Use a hot needle (by a candle in this case) to poke holes in the markings.
  • Pass the long legs of the LEDs (anodes+) through the holes and the short legs (cathodes-) over the support.
  • Solder the cathodes together using wire.

Step 2: Latitude Indicator - LED Controller

Now we need a means to power the LEDs, for this we will use 3 shift registers (74HC595). The diagram for the circuit is presented in the above image.

This circuit will have a 5V power input (in order to use the same supply for the stepper), in this case the voltage supplied by a modified phone charger..

The other 4 inputs are the Serial data (SER), Serial Clock (SCLK), Register Clock (RCLK) and Output Enable (OE). The register clear input will not be used so it's connected to 5V by a pull-up resistor.

Note that using a single resistor is not the best practice when driving multiple LEDs, in this situation it can be forgiven as we plan to only light one LED at a time.

After building the circuit and hooking up the inputs to a 12 V supply and an Arduino you can use the provided code to test if everything's working, you should see a single LED lighting up that "moves" along the arc.

Step 3: Longitude Indicator

As the on LED hoovers over the globe signaling the latitude of the ISS the globe itself will rotate under it to match the longitude, for this a small stepper motor is used to control the position of the globe.

We drill a hole in the support to make room for the shaft of the stepper motor that is later glued to the bottom of the globe while the body of the motor is glued to the base of the support.

Depending on the stepper you are using the driver will change to, in this case we are using the 28BYJ-48 stepper motor and ULN2003 driver on breakout board. so we will need to control 4 digital inputs to make the motor spin.

Step 4: Getting Real-time Location of the ISS

Now that we have means to show the latitude and longitude on the globe, we need to get the actual values for them from the ISS in real time.

The test code for this step is the following:

#include <ESP8266WiFi.h>
#include <ESP8266HTTPClient.h>
#include <ArduinoJson.h>

// WiFi Parameters
const char* ssid = "XXXXX"; 
const char* password = "XXXXX";

void setup() {
Serial.begin(115200);
WiFi.begin(ssid,password);

while (WiFi.status()!= WL_CONNECTED) {
    delay(1000);
    Serial.println("Connecting...");
    }
}
void loop() {
// Check WiFi Status
if (WiFi.status() == WL_CONNECTED)
	{   HTTPClient http;  //Object of class HTTPClient
	http.begin("http://api.open-notify.org/iss-now.json");

	int httpCode = http.GET();   //Check the returning code  

	if (httpCode >0) { // Parsing

		const size_t bufferSize = JSON_OBJECT_SIZE(2) + JSON_OBJECT_SIZE(3) + 100;
		DynamicJsonBuffer jsonBuffer(bufferSize);
		JsonObject& root = jsonBuffer.parseObject(http.getString());

		// Parameters
		const char* message = root["message"];
		const char* lon = root["iss_position"]["longitude"];
		const char* lat = root["iss_position"]["latitude"]; 

		// Output to serial monitor

		Serial.print("Message:");
		Serial.println(message);
		Serial.print("Longitude: ");
		Serial.println(lon);
		Serial.print("Latitude: ");
		Serial.println(lat);
	}
	http.end();   //Close connection
}
delay(50000);
}

This program connects the NodeMCU to the WiFi, then connects to the API, get the data and print it to by serial.

Step 5: Putting It All Together

Now that we have the longitude and latitude of the ISS we need to write some code to use the previously built indicators to show the Spacial Station position on our globe!

The additional code needs the following:

  • A function to move the stepper a single step while remembering the active coils.
  • A function to light a single LED using the shift registers.
  • A pair of linear functions to relate the longitude and latitude to a position for the stepper motor and an on LED correspondingly.
  • To use the previous portions to control the indicators accordingly to the ISS position.

The code for this portion is attached below (the digital pins used to control the stepper and the shift register can be selected there fin the initial definitions for your preferred wiring).

Step 6: Enjoy Your ISS Globe Tracker!

Position the arc of LEDs over England (the initial position of the stepper is longitude 0° at the Greenwich meridian) and plug the whole system to the 5V supply. Now you and everybody lucky enough to share office/house/shop with you can know the position of the ISS over the globe at any moment by looking this neat piece of decoration!

Maps Challenge

Second Prize in the
Maps Challenge

Be the First to Share

    Recommendations

    • Instrument Contest

      Instrument Contest
    • Make it Glow Contest

      Make it Glow Contest
    • STEM Contest

      STEM Contest

    17 Discussions

    1
    None
    Soumojit

    Question 7 weeks ago

    I am having a problem, I made this at first it sets the correct position but after that the globe is rotating a bit faster so after some time the globe postion and the iss position is not same, how to fix that problem on the code?

    5 answers
    0
    None
    javier.borquezSoumojit

    Answer 7 weeks ago

    Great to know that you are doing this project! If you are using the same stepper motor it might be because of the weight of the globe attached, the maximum torque is quite small so it often skip steps
    and after multiple revolutions it lags further and further. This happened at first so we changed to a smaller globe.

    0
    None
    Soumojitjavier.borquez

    Reply 7 weeks ago

    Thanks for your reply, I also used a very small globe, but my problem is its not lagging behind its going faster than the iss location, any way to tweak the values to set the globe at perfect speed?

    0
    None
    javier.borquezSoumojit

    Reply 7 weeks ago

    I can imagine two possible reasons for that, the coordinates you are using might have something strange, check if the ISS latitude and longitude data you are receiving is the actual position shown on a ISS tracking website.

    The second option is tweaking the line of the code
    "int target_step = round(5.658*lon + 1018.5);"
    This is a simple linear relationship between the longitude value and the corresponding number of steps.

    0
    None
    Soumojitjavier.borquez

    Reply 7 weeks ago

    so I checked the serial monitor the coordinate data is okey.
    so maybe their something wrong with steps, but I when I first boot it it go to the correct position but then its going faster, can you please explain that part of the code or is their any other way to keep track it after at position

    0
    None
    javier.borquezSoumojit

    Reply 5 weeks ago

    Sorry for not answering, things have been complicated on my country the last weeks.

    The code in my previous comment assigns a step position relative to Greenwich to the longitude obtained through the API.

    After that the present position (step) of the motor is compared to this new position and moves the globe while counting the steps until both values match, this process is looped to track the position during the day.

    If the globe moves faster it probably means that the "step position" calculated doesn't match the actual latitude on the globe because of the number of steps for a full turn not being 2037, tweak the code and make the globe do a full turn by inputting the step position as 2037 to check this.

    0
    None
    Soumojit

    Question 7 weeks ago

    Another thing, in exactly which degrees you placed the leds?

    1 answer
    0
    None
    javier.borquezSoumojit

    Answer 5 weeks ago

    I placed them 5 degree apart becase of the size of the LEDs.

    1
    None
    donvukovic

    2 months ago

    Now this is a real maker !! Use what you have on hand rather then buying.
    I have several bags of loose 5mm LEDs. Have been wondering for years what to do with them. Now if someone would build a wooden globe.

    1 reply
    0
    None
    jeanniel1donvukovic

    Reply 7 weeks ago

    I second this remark! We have so many extra items lying around unused these days, still working or usable. Good for you guys for using things on hand.

    1
    None
    Soumojit

    7 weeks ago

    every time at first how to set the globe position at Greenwich location? cause the stepper motor will stuck at its position after turned off, and it will be very hard to move it

    1 reply
    0
    None
    javier.borquezSoumojit

    Reply 7 weeks ago

    Because of its small size in this case the stepper is easily turned by hand!

    1
    None
    nivini

    8 weeks ago

    Wow, brilliant idea, man.

    3
    None
    SteveJ73

    2 months ago

    VERY cool.. I think I'm too lazy to do all the wiring quite like this though - Did you consider using addressable LEDs so you could just daisychain them, and have only 4 wires coming off the base? I haven't looked, but I'm wondering if maybe they aren't available in a form factor that would have worked.. Nice job! Could be used to track ANYTHING with software changes too.. like showing kids where "grandma's plane" is, when she's coming to visit from overseas or something..

    1 reply
    0
    None
    javier.borquezSteveJ73

    Reply 2 months ago

    Addressable LEDs are ideal for this situations, as you said it would have reduced the wiring and we could even skip the whole shift register circuit! We used this approach mainly because we had a lot of ICs lying aroud and this was a good excuse to give them some use.

    1
    None
    Cinnamonik

    2 months ago

    This is the coolest thing I've seen all day! Good job

    2
    None
    Penolopy Bulnick

    2 months ago

    I really like how you've connect a globe and LEDs for this project :)