An open API service indexing awesome lists of open source software.

https://github.com/hagemt/net-pet-feeder

I "fixed" my old Petnet SmartFeeder w/ a custom script in Python, foot pedal to send a "feed" event, cron jobs, and separate web front-end using Vercel's NextJS
https://github.com/hagemt/net-pet-feeder

feeder petnet portfolio

Last synced: about 2 months ago
JSON representation

I "fixed" my old Petnet SmartFeeder w/ a custom script in Python, foot pedal to send a "feed" event, cron jobs, and separate web front-end using Vercel's NextJS

Awesome Lists containing this project

README

          

# Homebrew revives defunct Petnet SmartFeeder Gen 1/2

Feed cats, but for Internet. Cloud not required. (self-hosted, just ngrok/ssh with Raspberry Pi)

image

## Install

Clone this repo to your Pi or VPS--configured so your Pi can start an SSH tunnel back to it.

* Copy the `teh` folder to `/opt/teh` on your `pi` and `sudo chown -vR pi:pi /opt/teh`
* Set up your `id_rsa.pem` in `~/.ssh/config` for easy tunnel between Pi and w/e.
* Install `env EDITOR=$(which nano) crontab -e` with auto-feed schedule, etc.

Via ssh, run: `make` to bring up the site, and add `ngrok` if needed.

## Notes for later

https://gist.github.com/ubergesundheit/7bdb6bdc818028a34a190363aed4d00a

### Wait, what is this?

> He took his defunct Petnet SmartFeeder, wired the motor to a relay board, then did basic magic with Raspberry Pi.

You can figure out most of the hardware stuff on your own, or read my bad code to understand which pin(s) to pick. Start with the `cats.py` script, which is the only thing that actually interacts with GPIO. The `mice.py` script assumes a USB mouse-like device is attached directly to the Pi. The API is HTTP GET/POST to obtain logs or activate the feed.

In all seriousness, this project is full of cheap hacks; it was fun though. No, I won't post URLs to feed my cat.

* There is a (dumb) front-end for the script.
* There are cron jobs to run on the Raspberry Pi.
* There's a USB foot pedal (mouse) to "feed" ad hoc.

The foot pedal is completely optional; I bought the relay board and "mouse" foot pedal from some guy in China.

See also: https://github.com/hagemt/footswitch

### Sorry, I still don't get it.

You're SOL, dude. I'm not saying you should use this to feed your pet. I'm just saying I did it, and it works for us.

It's a mid/moderate intensity (few days) maker project: https://www.reddit.com/r/Petnet/comments/p9tjy7/so_i_made_my_own/

Only extra hardware: Pi, and Songle 5V DC relays from Amazon (e.g. JBtek or SunFounder board) plus some various wires. You do need to spend ~$10 total, but no solder (screw terminals) if you just want to drive the feed motor for brief intervals using the unit's original power supply wired as pictured below.

![pi](https://user-images.githubusercontent.com/593274/130497191-386e5d14-2117-41c6-871f-2edf0d53c9c6.jpg)