Posts

Latest Post

Whereabouts Clock Simplified

Image
 Whereabouts Clock (v6) When I published the last update to the Whereabouts Clock I knew that I would make another version that simplified the architecture.  Apple iOS supports the idea of location regions (home, work, etc.) and can notify an App when the user enters and exits a region.  This "presence" feature is utilized in Life360, OwnTracks, and others. Instead of looking up a user's location from a static database, we can leverage the built-in feature to tell the Arduino clock how to move and when.  There's no more polling a web page for updates or maintaining a database of locations. So how does the whole system work now? Devices with OwnTracks send location data (either standard location messages or transition events into/out of a known region) to the MQTT broker (Mosquitto).   These messages contain the region information setup on the device (more on that in a minute) The Mosquitto MQTT broker broadcasts these messages to its subscribers (other OwnTracks devic

Whereabouts Clock Update

Image
After a few months, Life360 has gone the way of Apple and locked down the API I used to get location data from the phones.  This is disappointing, but inevitable. I found on a forum for Home Assistant that the app OwnTracks might be a suitable alternative. It's a neat little app that will trigger the phone to send its location data via MQTT to a server that you specify. I had to rework the code a bit, but the new operation is as follows: OwnTracks on the phone will push location data per its configuration to the MQTT server (Docker container) The Mosquitto (MQTT Broker) container will receive the data and forward the data to its subscribers The MQTTWarn container is a subscriber and translates the received data and adds it to the MariaDB database The Apache web server hosts a Python CGI script that is checked each minute by the Arduino microcontroller.  If the data has changed, the hands are moved to the new location. The only exposed port to the Internet is TCP 1883 for MQTT

Whereabouts Clock: New Clock Mechanism

Image
 When I made the first mechanism of the Whereabouts Clock I utilized sail winch servos to get a motion that was at least 360 degrees.  Most RC servos are limited to about 180 degrees before they hit a physical limit.  I always wanted to create a clock with motors that weren't limited in the number of rotations, such as a stepper motor. However, stepper motors don't retain positional accuracy after a power loss.  The motor drivers only know "left" or "right" and a number of steps.  If the motor is moved, or power is lost, it has no idea where the motors are any longer.  In most control systems using stepper motors there are limit switches that are triggered to "home" the motors to a known position. Also, the Arduino Uno is limited in the number of IO pins.  Most stepper motor control requires at least 4 pins and additional lines for motor enable, micro switches for positioning, etc. A while back I purchased an Arduino Mega and a six-pack of 28BYJ48

Whereabouts Clock Update: New Data Source

 After years of utilizing the Find My iPhone legacy API to access phone information, Apple has shut down this service as it doesn't meet its current security standards.  I started looking for alternatives and went down the road of coding an approach where the phone would run Python code to send the location data to a cloud-based receiver built in AWS Lambda.  However, this approach did not work because there is no current way to have the iPhone run this code automatically in the background without user intervention.  So I had to continue my search. I was about to give up entirely and resolve to write my own iPhone app (not trivial for me) when I came across Life360.  Life360 is a location-tracking app for families.  I found that there were already Python libraries available for the Life360 API.  I decided to use this one:  https://github.com/harperreed/life360-python With this Python library and a Life360 account for my family, it was rather trivial to update my location-fetching c

New Shop Tool

Image
 I've been researching for CNC routers for a couple of years now.  I think the addition of one of these tools to my workshop would be very beneficial.  After much prodding, my wife conceded on the condition that I could use it to make Christmas presents for folks this year.  I had narrowed my focus to the Carbid3D Shapeoko XXL line.  Fairly quickly I found a gentleman selling the current Shapeoko 4 model in Houston.  I loaded up the van, rented a trailer and drove to Houston this past Saturday to pick it up. I have to say, this thing is impressive!  With a cutting area of 31" x 31" it should be capable of some great projects.  I loaded up Carbide Motion and created some test cuts with gcode created by Carbide Create.  My next mission is to learn how to use Fusion 360 to generate the toolpaths and to start using multiple tools.  Here's to more future projects!

V-22 Osprey Project - Design Changes for v3

Image
It's been a busy end of 2021, and as we start 2022 I'm getting closer to building version 3 of the Osprey wing.  The single biggest problem I've faced is the amount of backlash in the direct spur gear drive of the tilt mechanism.  It introduces some nasty instability that, left unchecked, would likely destroy the model in flight. I've investigated other tilt mechanisms, but the one I keep coming back to is the rack and pinion design that Tom Mast uses in his model at Rotormast.  His design uses a high-torque digital servo with a small pinion gear driving a rack attached to the rotor nacelle.  The servo has been modified with an external potentiometer that's driven by a gear on the translation tube to give positional feedback to the servo.  I like this design a lot because 1) It works, and his model is proof, and 2) it requires less torque from the servo and has less backlash. I ordered the pair of modified servos, potentiometer, and rack from Tom's site and star

Mechanical 7-segment Clock

Image
I saw this design on Thingiverse a few weeks ago.  I believe it was also featured in Make Magazine's blog.   Mechanical 7-segment Display, simple and smooth It's such a cool design that I had to make a clock out of it.  Note that the designer, Shinsaku Hiura , also has a full clock made from another of his designs.  I printed out 4 copies of the design using Hatchbox and Overture PLA.  Instead of painting just the faces of the moving arms I chose to print the entire part in white.  The movement is controlled by 4x 9-gram servos .  I had a leftover  Arduino Nano  to control the system.  The time is read from a  DS3231 real-time clock module  and a momentary pushbutton switch is used to switch between the clock and the date.  The switch triggers an interrupt in the code and makes the clock change the display to the date (MM / DD) format for 5 seconds before reverting back to the time in 24-hour format.  The clock is powered by a 5V USB charger.  Note that the servo power comes d

V-22 Osprey Project - Swashplate Repair

Image
It's been a while since my last post.  In July my father, my son, and I traveled to Malvern, OH, for the annual Flite Fest RC festival hosted by Flite Test.  I took the Osprey with me to show off with the hopes of a demonstration flight, but it was not to be. I noticed prior to leaving for Ohio that one of the ball links on the left swashplate had stripped out and was loose.  I attempted to glue it back in with CA glue as an extreme thread locker, but it came loose during the 1500 mile trip.  At the festival I tried to glue it again with some epoxy, but it came loose again in handling at the festival.  Without any additional supplies on hand this meant that any demonstration flights were cancelled. When I got home I was able to repair the swashplate and ball link by drilling out the ball link itself and threading it with a 2-56 thread.  The original threads were 2mm and 2-56 is just slightly larger at 2.18mm.  I also drilled and threaded the swashplate for 2-56.  I used a short sec

dRehmFlight VTOL F-35 Review

Image
 The gentleman who developed the dRehmFlight VTOL flight controller (Nicholas Rehm) that I'm using in the V-22 Osprey project has published plans and 3D printed parts for an F-35 VTOL airplane.  I decided that it looked like a great distraction that could be done quickly.  I already had most of the electronics on hand including motors, ESCs, power distribution board, servos, and IMU board for the dRehmFlight VTOL flight controller.  I ordered more Teensy 4.0 boards and some 4S batteries and started cutting out the foam board according to the plans. The plane went together easily and the first flights went well.  My only complaint was that with the aileron hinge on top of the wing did not allow for enough down deflection to make the airplane hover in a level attitude.  I recut the ailerons and printed new motor mounts and adjusted those on the plane where the hinge is on the bottom.  I'm now about to get 70-80 degrees of down deflection and it hovers nice and level. I took a vid

V-22 Osprey Project - Tuning and Setup

ESC SETUP I used two Castle Creations Talon 60 ESCs for the V-22 Osprey.  These ESCs are high-quality with an electronic governer designed for RC helicopters.  Other ESCs with this feature are recommended.  Using the CastleLink software and USB dongle, I set the following RPM parameters: Throttle Setting 2-blade 3-blade 20% 2600 2000 70% 2600 2200 100% 2800 2400 As with any standard airplane or heli it's important to calibrate the ESC endpoints as well. TILT SERVO SETUP The HiTec D85MG servos are digital high-torque metal-gear servos that are programmable.  Using the HiTec programmer, I set the 1000us endpoint to the forward flight (0 degree) position and the 2000us endpoint to the hover (90 degree) position, with the 1500us center point in the middle (45 degrees).  The programming of the servo is a bit challenging, as the endpoints set in the programmer coordinate roughly to 900us and 2