Training myself to run farther with Strava's API and an IoT dog feeder of M&Ms
167 points
24 days ago
| 19 comments
| mayer.cool
| HN
vunderba
21 days ago
[-]
Good job hijacking your own pavlovian responses to run more. Personally, the low-tech solution of a plunger stuck to my forehead with a klondike bar dangling from the end has always worked for me.

Related but if you're wanting to get into running (and have the environment for it) - I HIGHLY recommend favoring trail running over running streets/sidewalks. It's far better for your joints, it'll make you work harder since it'll absorb some of your energy, and it'll improve your proprioception.

reply
imzadi
21 days ago
[-]
A few years ago I did Couch to 5k. I did all my running at a local park with hiking trails. I actually really enjoyed "running" at the park. After I finished the program, I signed up for a 5k that was run on a flat, paved trail. I finished it, but it beat me up so badly that I could barely walk for the next week.
reply
sandworm101
21 days ago
[-]
Running in a flat/straight line is an artificial construct. Our bodies evolved for running on rough terrain. A slower trail run will do less injury yet burn more calories than any hard sidewalk.
reply
hidden80
21 days ago
[-]
Race pace is tougher than training pace, too, though. I can run a comfortable few miles, but racing those same miles will cause me soreness the next few days.
reply
browningstreet
21 days ago
[-]
But what did you do next?
reply
imzadi
21 days ago
[-]
Tore my rotator cuff doing crossfit and had surgery and never really got back into fitness.
reply
the_sleaze_
21 days ago
[-]
This is obviously the real one true definition of "adult"
reply
com2kid
20 days ago
[-]
It is also why a lot of people in the fitness industry don't like CrossFit. The rate of injuries is absurdly high. For the longest time (maybe still) CrossFit had very minimal certification requirements for their coaches, so while some coaches had a long history and knew how to train safely, a lot didn't.

CrossFit did the community part really well, and then messed up the entire "train safely" part.

reply
vrc
20 days ago
[-]
Also, they program stuff like high rep clean and jerks and snatches along with high intensity cardio and gymnastic movements. Never a great idea to train high power, highly technical movements with fatiguing exercises and time pressure, let alone with poor form. I did a few classes in SF coming from a background in Olympic lifting and strength sports and I really found maintaining form and safety was quite hard.
reply
imzadi
20 days ago
[-]
I also just found out that I have hypermobility syndrome and both running and crossfit are the worst things I could be doing because of the resultant joint instability.
reply
browningstreet
20 days ago
[-]
Yeah, I personally wouldn't crossfit. It's complicated doing reps for time, exacerbating form with fatigue, etc.
reply
RankingMember
20 days ago
[-]
Time to get into cycling!
reply
Taylor_OD
20 days ago
[-]
A tale as old as time...
reply
JAlexoid
21 days ago
[-]
> Personally, the low-tech solution of a plunger stuck to my forehead with a klondike bar dangling from the end has always worked for me.

Or you could borrow someone's labrador retriever and have the dog pull you. They like to go real far and real fast... and you get to practice hard turns.

> I HIGHLY recommend favoring trail running over running streets/sidewalks

As a triathlete - I would add something: for me it's more a case of running on soil, over a hard surface. Trail running may take you to a stony path, which is as bad as pavement/concrete.

But in the end it's training your running form to be the best it can be for running, that matters. Running uphill helps to naturally train a good form, even if it's significantly harder.

reply
LeifCarrotson
21 days ago
[-]
> Or you could borrow someone's labrador retriever and have the dog pull you. They like to go real far and real fast... and you get to practice hard turns.

You only need to be concerned about hard turns if the dog is untrained, afterwards, they're the best running partners you could ask for. Come visit us at https://www.reddit.com/r/RunningWithDogs/. Lots of suggestions for harnesses for the dog (mandatory, IMO) and waist leashes for the human (highly recommended).

If you own the dog, they can be a great source of encouragement, too. They'll bounce with excitement any time there's a possibility of going for a run, and look at you with big, sad eyes when you instead sit on your phone.

My old girl and I put in 20+ miles a week, 50 weeks a year, for a little over 8 years, or a little over 8,000 miles. That's a lot of M&Ms!

reply
vunderba
21 days ago
[-]
I completely agree. I used to live about 10 minutes from the beach, and I would do sprints up and down on the sand. There's not much that's more humbling than getting completely gassed after a whooping 60 seconds of running.
reply
danielwmayer
21 days ago
[-]
Thanks for the tips! I live in the middle of the concrete jungle that is LA so I instead have the kushiest moon-shoes I could find. As for the klondike bar I’ll have to train up my neck :)
reply
fifilura
19 days ago
[-]
I am the opposite :) I run every day. I prefer long stretches of asphalt without any bends

Job.

But also, running in forests messes with my pace and focus somehow.

reply
inanutshellus
21 days ago
[-]
> My adulthood litmus test has always been the following: > > If you know what date it is every day, you are an adult.

Tangent - My definition of "adult" that I came up with as an early teen:

"When I realize I'm looking in the _driver's seat_ of passing cars hoping to see pretty girls, that will mean I'm `an adult`.".

Years later I had a palpable shock moment in which I glanced in a car and remembered coming up with the definition. "OH CRAP I'm an adult!"

Felt like a "hoist by my own petard" moment.

reply
xandrius
21 days ago
[-]
I generally unbundle age and adulthood.

For me the definition has always been "an adult owns up to their own mistakes".

Which is the shorter version of "A child doesn't care about their mistakes, a teenager expects others to fix them and an adults own up to them".

This allows me to categorise older people who I feel like don't act like adults.

reply
aradox66
21 days ago
[-]
This is an adult's definition of an adult
reply
itishappy
21 days ago
[-]
Maybe defining "adult" is the definition for adult?
reply
aradox66
20 days ago
[-]
Nah no way, as some of the above definitions show, children - or at least teenagers/"young adults" -clearly conjure definitions of the adult.

There is definitely a difference though between defining an adult from the inside vs outside

reply
firecraker
20 days ago
[-]
Only when trying to assert that you are not one
reply
inanutshellus
20 days ago
[-]
I think it's the definition of a moral person, not an adult, but I do like it.
reply
inanutshellus
20 days ago
[-]
Yes, shockingly my tween-made definition of adult wasn't very adult. ;)
reply
senkora
20 days ago
[-]
My definition that I came up with college was that adults had full spice racks in their kitchens. I had recently gotten into cooking and was annoyed that it didn't really make sense to buy spices that I would have to throw away at the end of the school year. (I lived out of my suitcase, so space was at a premium).

I am now very happy with my full spice rack.

reply
throwup238
20 days ago
[-]
> I am now very happy with my full spice rack.

There are so many ways to interpret that.

Being an adult is all about ambiguity!

reply
woleium
20 days ago
[-]
i used to say i would become an adult the Saturday i go to buy myself a couch.

Younger folk get their couches on any day and usually from facebook/craigslist/local classifieds

reply
elliottkember
21 days ago
[-]
I recently saw a tweet about someone who put on a nicotine patch every time he went running and tricked himself into thinking he loved it. He was on his third marathon! https://x.com/WillManidis/status/1728860291457524073
reply
pinkmuffinere
20 days ago
[-]
Wow this is fascinating! I wonder whether the net health impact is positive or negative, I’m tempted to do this myself
reply
pinkmuffinere
20 days ago
[-]
It didn’t take long to think of some healthier options, which I’ll share here in case others think the same:

- copy the m&m design (though I don’t like m&m’s)

- do the same thing with beef jerky/trail mix/hummus/steak/treats like that

- do the same thing, but use a good restaurant/coffee shop/board game/friend/TV show/hot tub/other experience

reply
vhcr
20 days ago
[-]
Nicotine is probably healthier than beef jerky or steak.
reply
pinkmuffinere
20 days ago
[-]
That seems to me like a remarkable claim — can you share a link that discusses this more?
reply
eadmund
20 days ago
[-]
Nicotine’s fine. The issue with smoking and chewing tobacco is the delivery system, particularly smoking. It’s a shame, because pipe tobacco tastes and smells absolutely divine. I think it’s still worth it, but understand how others disagree.
reply
dmurray
17 days ago
[-]
Actually, yes.

Here's [0] 5000 words by Gwern. I don't know whether I agree with his conclusions, but they're likely to be well researched and objectively thought out.

[0] https://gwern.net/nicotine

reply
kuschkufan
20 days ago
[-]
"low key" tobacco industry sponsored content right there.
reply
thehappypm
19 days ago
[-]
As I understand it, nicotine in and of itself is not particularly harmful. It’s the delivery mechanisms that do all of the harm.
reply
johnfn
21 days ago
[-]
Just got back from a run!

By far the most effective thing to motivate me to exercise, and run in particular, is the "VO2 Max" section of the Apple health app. It's a rough indication of your cardiovascular endurance, and the higher, the better. The real key is that, though, is that it basically works like an XP bar in a game: if you "grind" running, it goes up. If you don't, it doesn't. It's incredibly addicting to check the number every time you finish a run and see if it's ticked up slightly. It's also great because in some sense it is "real". If it goes up, I have an easier time on hikes, runs (obviously), playing sports, etc.

The second thing that really got me into running is that I found that the most effective way to get VO2 Max to go up is to run in heart rate zone 4, also tracked on the Apple watch. Zone 4 is 80 - 90% of your maximum heart rate. It's not an all out sprint, but you'll be moving pretty fast.

The reason it's so effective is best illustrated by contrast. In the past, I've tried tracking a number of metrics on my run: total miles, average speed, calories burned, whatever. But I found it psychologically draining to continuously try to top my fastest speed, and I inevitably had off days (or weeks or months) when the score I was measuring wouldn't go up. Obviously as you get faster, this happens more and more, and it gets easy to start wondering if you're even progressing. Heart rate is a much better measure, because in some sense this is compensated for. You don't have to continue to beat yourself every day (or fret that you're not) to get to 80% of your max heart rate, and on days when you're more exhausted, you'll hit a higher heart rate faster, so the effort is roughly the same.

Also, Zone 4 is a great place to be. You're pushing yourself, but it's a sustainable sort of push. I often found that when I ran sprints I wanted to die. They were so psychologically demotivating that I would do anything to avoid them. Zone 4 is not like this. It's very manageable, and I wake up excited to do it!

At this point, I want to run every day - I'm at the point where I have to force myself to stop sometimes because it's healthy to take rest days!

Usual disclaimers apply, BTW. Don't do all your running in Zone 4, don't immediately go from no running to an hour of zone 4 every day, do a reasonable ramp up over a long period of time, etc etc.

reply
ctchocula
21 days ago
[-]
I like how you describe vo2 max as similar to an xp bar, because I've felt something similar. Zone 2 is what got me into running, because it made running not hurt and almost pleasurable.

It's much more sustainable than Zone 4 (supposedly anyone can maintain Zone 2 for hours) and brings with it a bunch of metabolic and health benefits. I found the book "80/20 Running" to have excellent running schedules for how to mix in a small but appropriate amount of fast Zone 4 running into a schedule that's predominantly Zone 2. It has a good mix of intervals, tempo runs and hill runs that build you up to run 5k, 10s, halfs and full marathons in beginner, intermediate and advanced pace goals.

The intent of the slow Zone 2 is to build the cardiovascular base that gives you better aerobic endurance without stressing your body out too much. Zone 4 is what makes you faster.

reply
johnfn
7 days ago
[-]
This is an old response, but thanks for the comment. I feel like you articulated zone 2 a lot better than almost anywhere else I've seen.
reply
bagels
21 days ago
[-]
What is it measuring? VO2 max is usually measured with a mask that can measure the flow of gasses while running on a treadmil/stationary bike.
reply
alephxyz
21 days ago
[-]
Garmin estimates it using heart rate, body weight and power output. It also adjusts for temperature and altitude if possible. In my experience it still varies a lot depending on which conditions I exercise in but it's a decent tool to see your progress if you're able to test it under similar conditions every time.
reply
maeil
20 days ago
[-]
Which watch do you use?

The user you replied to has convinced me to get a smart watch as 1. I've had awful stamina since age 10 or birth 2. Stupid "number going up" gimmick generally works well at motivating me. But I'm not about to switch to iPhone, so getting an Apple watch isn't going to work.

reply
542354234235
20 days ago
[-]
Not OP but I’ve used Garmin’s for about 15 years and over 10k running miles. I don’t like or use non-fitness related smart watch features, so I can’t speak to those or recommend a good "smart watch that also does fitness". If you want top of the line with more data than you’ll know what to do with and a ton of fitness activity tracking beyond running, the Epix2, Fenix 7, or Forerunner 965 (I have the Epix2).

A step down but still great is the Forerunner 265. The feature they all have and I think has been the most useful is the Training Readiness. It looks at a bunch of different metrics, both current (your HRV, last workout performance, sleep, stress) and chronic (your weekly and monthly total exercise amount, types of running, etc) and advises you on how hard you should train and suggests a running activity for the day. It is basically a digital running coach/personal trainer that makes sure you are getting a good mix between tempo runs, long runs, easy runs, etc. and makes sure you aren’t overtraining or if a bad day means to switch to a light workout. I normally use it loosely to inform my choices but I’ve tried using its daily training plans exclusively and it was very good at keeping me progressing.

Hopefully this helps.

reply
maeil
20 days ago
[-]
Super helpful, going to look into those! I too only care about the fitness part, in an even narrower scope - literally only the usecase mentioned here, giving some VO2max-ish or other "stamina level" number (even if of questionable accuracy) that I can slowly see improve over time to help with motivation.

In some sense less data might be better to make it clearer which number to focus on, so sounds like the Forerunner may be the right fit. The Training Readiness does sound a bit intidimating for someone who's starting from zero (or really, minus), but I can always strategically ignore that ;)

Thank you.

reply
542354234235
20 days ago
[-]
>The Training Readiness does sound a bit intidimating for someone who's starting from zero

I totally understand, however, I would say that is exactly where it is most useful. You don't need to actually know or understand any data, since Garmin crunches all those things in the background for you and distills it down to concrete advice on where you are and what to do next. You can really do well with just two metrics (the daily suggested workout and Training Status). You could just follow the workout of the day "Easy run, heart rate range x-y, 31 mins" or "Tempo run, warm up 10 mins, run 15 mins heart rate range x-y, cool down 10 mins" etc. And look at what your Training status is currently, which is things like “Productive”, “Overreaching”, “Maintaining”, etc.

You don’t need to understand about lactic threshold and what types of runs improve it or how high aerobic, low aerobic, and anaerobic runs affect different aspects of improving your fitness or how many rest days are enough. You don’t need to have the experience to know how to balance recovery and training and which factors to even look at. Was your status “Productive” most of the week? Awesome, you know you are improving. What is the next workout? Done.

I hope it works out for you and you enjoy running as a healthy hobby.

reply
maeil
19 days ago
[-]
> Was your status “Productive” most of the week? Awesome, you know you are improving. What is the next workout? Done.

Right, but to us monkey-brained seeing a boolean "productive" isn't a great motivator, we need to see a number that can go up, making it much more addictive. That's why I was so convinced by the Apple Watch user giving that one number that they look at - that will definitely work for me as it's super effective on the reward-related parts of my brain. A boolean, or having a hundred numbers - not as much. If you're someone who doesn't need that, I'm sure the training readiness is much more actually useful for improving, but we're not necessarily looking for that - our hope is to one day get to a point where we may start looking for that :)

I've noticed it myself even when doing projects. So much easier to stay motivated when you have this one number, e.g. page views or active users that updates every day (not "enterprise contracts" which may change once every month), to focus on, purely for monkey-brain reasons.

reply
creaghpatr
21 days ago
[-]
It can be approximated using your age, HR, efficiency, etc. The treadmill/mask test is more accurate though.
reply
Amorymeltzer
21 days ago
[-]
>I knew I had to get a food dispenser that I could control with Python, so I sought out to find the shittiest, most cheaply made looking IOT dog food dispenser on Amazon. My rationale was that it would have the worst security around whatever protocol it used to trigger the feeding, so I could easily capture and replay the feed command.

Turns out it was unnecessary but I like the idea of actively looking for the worst of something.

Also, having just recently set a repeating reminder to rotate the mattress, yes:

>I now know that what being an adult really means is that most of your time is taken up by an ever-growing list of compulsory maintenance tasks that constitute the meager amount of control you exert over your own life.

reply
triceratops
21 days ago
[-]
> what being an adult really means is that most of your time is taken up by an ever-growing list of compulsory maintenance tasks that constitute the meager amount of contol you exert over your own life

Truer words have never been said. It's absurd how much bureaucracy adults have to engage with just to exist.

reply
seizethecheese
21 days ago
[-]
This is pretty cynical. It might ring true, but I don’t think truer words have never been spoken.
reply
triceratops
20 days ago
[-]
You understand hyperbole, yes? It's a throwaway comment on a silly article about Pavlovian self-conditioning using an Internet-connected dog feeder.
reply
srveale
20 days ago
[-]
What do you think are the truest words ever spoken? Maybe just something out of the top ten.
reply
readthenotes1
21 days ago
[-]
Something like that seems like it would require extensive in-house testing before I actually used it for real.
reply
jeff_vader
21 days ago
[-]
I've done something similar but it was only a 7 segment display showing how much I ran. It sat on a shelf and it was pretty fun to watch number go up every time I came back to my apartment after a run.

To make everything really simple I scraped my public profile directly from esp8266 controller (so there's no need for extra steps of setting up Strava app to gain access to the API). Worked relatively well.

reply
larsrc
21 days ago
[-]
I recently found that store-brand peanut M&M's (my favourite) were just as good, half the price, and fair-trade! Win-win!

When I joined my current job, I used M&M's as reward when learning the names and faces of the people there using memory cards. Also worked!

Fortunately I've found that Belegarth fighting is so much fun that I need no extra carrot.

reply
pglevy
21 days ago
[-]
I go to the gym regularly but I probably should put something like this contraption between me and my family size bag of peanut M&Ms.
reply
NBJack
21 days ago
[-]
This article is a work of art. Thank you for writing and sharing it.

I too have struggled to find something that worked for me for consistent exercise (surprisingly, prepaying for training helped more than I expected), and now I don't want to lose momentum. Make no mistake though; I had a LOT of help from friends and family as well.

Bonus points for Mord Fustang.

reply
julianeon
21 days ago
[-]
This is the kind of content I love.

It does make me think: what else can you use Tuya devices & Python libraries to do? I've got exercise and food portions under control, but I'm interested in other applications.

reply
petee
21 days ago
[-]
Great idea! I was picturing a device you wear that feeds you as you run :)
reply
bsimpson
21 days ago
[-]
Reminds me of this video:

https://youtu.be/HWceX64ZC8w?si=a-mm-DP4EKMmGhXy

Similar idea with origami ninja stars.

reply
guyzero
21 days ago
[-]
A much improved successor to Tomatan: https://www.youtube.com/watch?v=cOJaDDO38kk
reply
iandanforth
21 days ago
[-]
If you go this route consider this extra hack. Caffeine acts as a direct reinforcer. You can buy caffeinated chocolates and dispense those. This will augment the power of the treat.
reply
nightowl_games
20 days ago
[-]
I started intermittent fasting where I would only eat breakfast after running on an elliptical for an hour.

I got my butt to the gym pretty quick in the day because I was hungry

reply
eadmund
20 days ago
[-]
Does anyone here have decent suggestions for a local-only IoT dog feeder? No server, no Internet access at all, just LAN.
reply
wolfgang42
18 days ago
[-]
From the fine article itself:

> If you wanted to have this thing completely isolated though, you could have a no-outbound-internet subnet with this device on it so long as the device you are going to run the script on has line-of-sight.

> You can do this because Tuya devices have a local-only protocol that tinytuya supports, so you can send commands just within your LAN.

reply
eadmund
17 days ago
[-]
I read the article. The bit you quote talks about putting the device in a firewalled subnet, because it is not a local-only device: it will try to dial out to a third party server, so it must be placed in a subnet which will block those attempts.

I want a device which I can put on my network and which will not try to dial out to the world. This device is not that.

reply
focusedone
21 days ago
[-]
That's awesome! Do their recent API changes impact things like this?
reply
guzik
21 days ago
[-]
It only affects 3rd party analytics, so it should not.
reply
nextworddev
20 days ago
[-]
Techies will do everything to get better at running, except putting in the miles
reply