Earth, Sun & Moon Tellurium Improvements

by illusionmanager in Circuits > Arduino

479 Views, 2 Favorites, 0 Comments

Earth, Sun & Moon Tellurium Improvements

tellurium.jpg

The Earth, Sun & Moon Orbitor (ESMO) original made by Eaglemoss, is a pretty nice device that accurately moves the Earth and the Moon around the Sun. The moon rotates around the earth in a slightly tilted plane and that plane itself rotates around every 18 year. The device is precise enough to predict Lunar and Solar eclipses.

However you have to engage the relatively loud motor manually every day to advance it and rotate the earth once around its axis.

This modification not only automates that process, it adds functionality. It keeps the Earth oriented correctly by rotating it a tiny bit every minute or so. This way you could see for example the sunrise at your location.

You can still use the motor and the knob to move it forward or backward at any speed (from super slow to the max speed this motor goes). The existing switch still determines the direction of the rotation, but when set in the "off" position it moves the earth back to its correct position and starts rotating the earth every minute or so.

If you do this modification, make sure your ESMO device runs very smoothly.

Supplies

parts.jpg
  1. You'll need of course the Earth, Sun & Moon Orbiter itself,
  2. an ESP32 super mini dev board
  3. a TCM 2209 stepper motor driver board
  4. Stepper motor 28BYJ-48 (one that does exactly 64 steps not 48 like the one from adafruit)
  5. two 10k or 5k pull-up resistors
  6. some wires

you need a soldering iron and a 3d printer

Stepper Motor Conversion

convert.jpg

You'll have to modify the stepper motor so it works with a 4-wire connection (convert it from uni-polar to bi-polar). Have a look at this video that explains why and how. You could use it with the 5 wire and suitable darlington driver board (often sold together), but I didn't have that at hand. So this instructable and the code use a modified stepper motor.

3d Print

P_20231023_130940.jpg

Print the supplied objects on your 3d printer. I used a resin printer, but it should work on any 3d printer. There are two parts. The circular adapter is attached to the motor and interfaces with the axle of the ESMO. The other part holds the motor and the ESP32 in place. The ESP32 is mounted vertically directly over the existing power port. USB-C cable can be used to power the device. Note not all USB-C cables fit, you need a smaller one.

Note there are no holes to mount it. You'll have to drill those. Why? because my first, second and third design all had holes in slightly the wrong location (even after multiple measurments). So first mount the mount the motor in place, then temporarily put the esp32 in place, put it on the base plate of the orbiter and stick a usb plug through the bottom. Then mount the central column of the ESMO and use the adaptor part on the motor shaft. Now everything is more or less fixed in place and you can mark the position for the holes through the bottom of the base plate.

Electric Wiring

P_20231023_151059.jpg

Remove the existing motor, the power port and all wiring.

Connect the 5V and Gnd from the ESP32 board to the V and GND on the TMC2209. On the TMC2209 connect the V and GND to the MotorV and MotorGND (this motor runs on the same 5V) Connect the 4 wires (yellow, blue, orange and pink) from the motor to the TCM2209 2A, 2B, 1A and 1B pins. Connect pin 1 from ESP32 to the enable pin on the TMC2209. Pin 4 on ESP32 goes to DIR pin on TCM2209 and pin 5 goes to STEP pin.

Connect GND from TMC2209 (or ESP32, it doesn't matter) to one side of the potentiometer, and from there to the center pin on the switch. Connect 2 resistors to the switch using the pins directly next to the center pin. Connect 3.3V from ESP32 to the other side of the potentionmeter and from there to the free end of both resistors.

Connect pin 0 from ESP32 to the center pin of the potentiometer. ESP32 will read the analog value from this potentiometer as a value between 0 and 4096 (in my case the lowest value turned out to be 41). Connect pin 3 from ESP32 to the switch on the pin directly next to the center pin, and pin 2 from ESP32 to the pin next to that. ESP32 will use these inputs to determine the position of the switch.

Programming the ESP32

programming.jpg

Use the supplied ino-file and use the arduino-SDK to load it into the ESP32 processor board. You need to have the TMC2209 library from Polidoro intstalled in order to compile it. Test that it works. Slide the switch to the left or right to see it moving and rotate the knob to change the speed. If you put the switch in the central position, the motor rotates back to the position it started (or close to that, depending on the time).

Mount the motor, ESP32 board and TMC2209 onto the base of the ESMO. I used some double sided foamy tape to keep the TMC2209 in place.

Downloads

Calibration

calibrate.jpg

Do the usual calibration of the ESMO, but in addition rotate the earth around its axis so it matches the current time of the day. (if you do this at noon, pick your location on earth and rotate earth so it is closest to the Sun (adjust for Daylight saving time if that applies)).


Operation

Tellurium

The ESP32 doesn't have a real-time clock. So when you power it on, it assumes it is fully calibrated and set to the current time and date (time = earth's rotation, date is pointer and year counter on the device). From then on, the ESP32 just keeps rotating the earth a tiny bit every minute or so. It keeps everything running in sync with the real world. If you set the switch to the left or right, your device starts turning at your chosen speed in the chosen direction. However ESP32 keeps track of how much you moved it, and will move it back to where it belongs if you set the switch back to the central position.