Automatic Fish Feeder With Light




As a student I wanted something to flourish up my room. A small fish tank seemed perfect. But since I'm always away for the weekend or even longer periods during summer holidays, I wouldn't be able to feed the fish, and they probably won't like that so much. So I had to come up with a solution. When I had some spare time, I started brainstorming about some way to automate the feeding and keep it as compact as possible.

On the Internet, there are many ways to make an automatic feeder, but all I found were messy solutions with mostly servo motors. These feeders are big and it's hard to set the right quantity of food.

I designed a screw that's 3d-printable in Inventor. With this screw (driven by a stepper) I "extrude" the food through a tube from the reservoir to the drop zone. I can set the feed duration in seconds, which gives me an exact same food quantity every single time.

IMPORTANT NOTE: I tried it with several types of food. Flakes tend to jam the screw. The fish granulate works best.

An RTC module keeps track of time and a stepper driver gets his commands from an on-board Arduino Nano. I also added two small led panels (white and blue), brightness can be set with two separate potentiometers. Here is how I made it.

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: What Do You Need?

Arduino nano: Easy to upload code with a simple usb cable. Arduino pro mini would do just fine.

DC female plug: Required to plug in the 12v wall adapter.

Wall adapter: I use a 12V 2A which is more than enough.

DS1307: Keeps the time once set. Also has a 3V backup battery on board, so it's able to keep time even when power is not connected or there is a short power failure.

Potentiometer: Used as analog input on the arduino to set the brightness of the led panel.

Led panel: Works on 12V. Brightness is set through PWM from Arduino.

TIP122: NPN power transistor, needed to regulate the 12V for led brightness. (any power transistor would work, as long as specs are respected)

Stepper and stepper driver: Used to control the stepper. Stepper rotates the screw. The screw pushes food further down the tube.

Small piece of perfboard: Makes it easier to connect the components to arduino.

Step 2: Tools

Laser cutter: used to make the enclosure that fits above my fish tank. The wood I used is 2,5mm thick MDF.

Tube: outside diameter 16mm, inner diameter 13mm. I found these tubes very cheap at a local hardware shop.

3D printer access: Needed to print the screw.

Step 3: The MDF Enclosure

As mentioned above, I used 2.5 mm thick MDF. At school I had the opportunity to use a laser cutter, which was nice, quick and very precise.

It's probably not very useful to upload my files here, because it fits my fish tank. If you make this small automatic feeder, you will have to design the MDF enclosure according to your own fish tank dimensions.
(If you want them anyway, contact me)

Step 4: The Tube Construction

The tube where the screw comes in has to be 120mm long. This way it will fit the wooden enclosure correctly. As you can see on the previous pictures, the front and middle MDF plates are double. They hold the tube in place.

The small tube on the right holds is the food reservoir. This can be made longer, for it to hold more food. The tube on the left will hang above the water and will guide the food (pushed by the screw) to the hungry fish.

Step 5: The Screw

The screw is also designed in Inventor and 3D-printed later at the school's fablab. The screw fits right on the stepper motor axis. There is no reduction needed, and the printed plastic is strong enough to withstand the torque needed to push the food.

While the screw rotates, it will exert a force on the food. But the food will exert an equal and opposite force on the screw. So the screw will be pushed back direction stepper motor. This means the screw doesn't has to be glued or pressed on the axis. The food does this job for us and holds the screw on the stepper axis.

The STL file is added for those who want to print it. Be sure to adjust the scale x10.

Step 6: RTC Module: DS1307

Keeps time once set. Mine has to be reset every few months because the clock isn't that precise. I would recommend the DS3231 which is much more accurate.

The module communicates with Arduino via SDA (A4) and SCL (A5) lines. It also needs a 5V and GND line from the arduino.

The library to set up this module can be found here:

Step 7: The Code

I've had some help from a friend to get this small Chinese stepper going. I have added the code in the step. The comments are in dutch, but shouldn't be to hard to understand :-) or else, use Google Translate ;) .

Step 8: The Future

- Design a PCB;

- Led that indicates if the reservoir is nearly empty;

- Larger reservoir (mine is empty in about one week);

- Automate LEDs;

- Add 2-channel relay to switch between air pump and filter pump;

- Design a lid for the enclosure and add two turn knobs (potentiometers) to adjust LED brightness in the lid;

- Add bluetooth (HC-05) and display water temperature, water level, outside temperature and reservoir fill percentage on computer;

- Switch to turn the feeder off;

- Possibilities are endless!

Step 9: PCB Has Been Designed!!

I have designed a PCB for my fish feeder. It fits an arduino nano and some other components like resistors, a transistor and push button. All connections can be made much neater now!


- D0: TX

- D1: RX

- D2: not connected

- D3: via resistor 1K to base of transistor

- D4: relay1

- D5: LED for food monitoring

- D6: relay2

- D7: not connected

- D8: IN1

- D9: IN2

- D10: IN3

- D11: IN4

- D12: motor button_push to feed

- D13: not connected

- A0: Input potpin1

- A1: Input potpin2

- A2: not connected

- A3: status LED

- A4: SDA

- A5: SCL

- A6: status LED

- A7: not connected

If you want a PCB for your project, please contact me on or via Instructable message. Price is 5 euro + shipping cost (guess about 2 euro).

3D Printing Contest

Participated in the
3D Printing Contest

Home Automation

Participated in the
Home Automation

Be the First to Share


    • Made with Math Contest

      Made with Math Contest
    • Multi-Discipline Contest

      Multi-Discipline Contest
    • Robotics Contest

      Robotics Contest

    28 Discussions


    3 years ago

    this was a great little idea. I had to make a few adjustments to it but essentially the same. I had to upgrade to a nema17 motor and a pololu A4988 stepper driver because the original motor would get jammed on pellets sometimes and fishes would go hungry. I also used a metal auger bit rather than a plastic one. I found it at a yards sale but you could buy one. it has a larger coarse drilling channel and is only for wood. I also just push the food straight out the end rather than having the down channel. Lastly, I found a sheet of acrylic and cut that up for the case. I had an arduino uno not in use and had an acrylic case for that. the hooper is an old coffee can I cut a hole in and used a uniseal and a little hot glue to keep the little pellets from coming out. I had to make different code because I got the same error other readers had; the included code would not load. Anyway, those are my mods. Thanks for the inspiration.

    1 reply

    Well done Instructible1! I also had to rewrite the code, because there was a problem with my library. Now I'm using a better library. This project is growing every day, now looking to automate lights, pumps, airpumps, co2, and so on... . A lot of fun!

    I am seeing the same problem.

    Fish_Feeder:8: error: 'TStepperMotor' does not name a type

    Fish_Feeder.ino: In function 'void setup()':

    Fish_Feeder:33: error: expected unqualified-id before '=' token The code is: "Stepper = new TStepperMotor(400, Pin_12, Pin_11, Pin_10, Pin_9);" All of the errors refer to the use of Stepper

    Fish_Feeder:36: error: expected unqualified-id before '->' token

    Fish_Feeder:37: error: expected unqualified-id before '->' token

    Fish_Feeder.ino: In function 'void loop()':

    Fish_Feeder:49: error: expected unqualified-id before '->' token

    Fish_Feeder:50: error: expected unqualified-id before '->' token

    Fish_Feeder:63: error: expected unqualified-id before '->' token

    Fish_Feeder:64: error: expected unqualified-id before '->' token

    'TStepperMotor' does not name a type

    I had to load new libraries for this project.


    4 years ago

    Really good. It is possible to share the screw file to print? I will appreciate. Thank you

    3 replies

    For those who still wonder how all the pins are connected. Here is the list of the connections to the Arduino Nano. I made some adjustments, because I am designing a PCB, still need to find some time to prototype the thing. Maybe someone who can help me in Antwerp, Belgium? :-). You'll also see some additions like: lightsensor (for reservoir monitoring), bi-color led (or RGB) to indicate the reservoir status and also relay pin to control the airpump. Thats about it, probably gonna be version 2.0 ;-) have fun!


    4 years ago on Introduction

    Very nice project. Can you share me electronic circuit schematic. Thanks. (

    1 reply

    4 years ago on Introduction

    Hi Marijn,

    Is there way to increase the time os "FeedDuration"?

    //int FeedDuration2 = 10; //voedertijd in seconden (max 60)

    1 reply

    Reply 4 years ago

    Yes, the 10 you see is the duration in seconds, you can increase that number. Max is 59 seconds.


    4 years ago on Step 8

    Thank you for a great Instructable. You did a very good job explaining the steps as well as excellent photos.

    1 reply

    4 years ago

    Thanx very much marijn. i'll get you a beer somehow soon! You drink beer I hope, otherwise state your wish...

    1 reply