1Download Arduino IDE
Before starting with building anything you should make sure your computer can communicate with the Adalogger M0 board and that you can flash the operant FED sketch. Start by installing the Arduino IDE.
2Install relevant Arduino boards to run the Adalogger M0
The Adafruit M0 Adalogger board is not natively supported by the Arduino IDE. To enable the Arduino IDE to flash sketches to this board, follow instructions here. After completing these steps make sure you can flash the example sketch "Blink" to the Adalogger board before continuing. Open Blink in File>Examples>Basic>Blink. "Double-click" the button on the Adalogger to put it in bootloader mode and make sure Board is set to "Adafruit Feather M0" and port is set to the same before clicking upload (the right arrow at the top of the Arduino IDE).
You should see "Upload complete" in the bottom feedback window and the red LED on the board should blink once per second.
Congratulations, you have configured your Arduino IDE and uploaded a sketch to the Adalogger!
3Install relevant libraries
FED3 requires the following libraries:
You can install them in multiple ways, but the simplest will be to download the prepared zip file (oFED libraries.zip, also in the files area) including these libraries and extracting it to your Arduino libraries directory (for most it is: /Documents/Arduino/libraries
When you're done they should all be in your libraries directory, see example:
If this doesn't work, or you'd prefer a different way go through instructions here for how to manually add libraries.
4Print all six 3D parts
STL files are in the files area.
(Optional) You can spray them with clear acrylic to increase their durability when used in home cages.
5Order the PCB
FED uses a custom printed circuit board (PCB) to minimize wiring and increase reliability of the electronics. The BRD file (what you use to order the PCB) is in the files area. Here's what 50 look like!
Order here (or download BRD file and order from wherever you like):
6Populate the PCB
Start by soldering on all SIX headers. These include two short female headers for the Adalogger (one 12 pin, one 16 pin), a short female header for the RTC module (5 pin), and two short female headers for the TB6612 motor driver (one 10 pin, one 6 pin). Finally, solder one male header for the motor (5 pin).
IMPORTANT! Solder all of these onto the BACK of the PCB, the side that says Operant FED V5.1 and BNC.
Next solder the three PhotoInterrupters so they poke out of the FRONT of the board:
Solder buzzer into place and trim PhotoInterrupter and resistor wires:
Solder 90 degree headers onto the Sharp Memory screen breakout and solder onto the board
Solder the Neopixel strip onto the front of the board. This step is actually pretty difficult to get right, in future boards we may update to a new method but what I've been doing is putting solder on all 8 pads of the PCB and the Neopixel, placing them together, and then using a fine tipped soldering iron to melt each pair together:
Final step for the PCB! Solder the large BNC connector to the board:
7Solder headers onto Adafruit breakout boards
Solder male headers onto all 3 Adafruit breakout boards. Put the coin cell battery into the RTC breakout at this point.
Plug these boards and the stepper motor into the PCB and you're done with the electronics!
8Download FED3 sketch and flash FED3
Before assembling the device into the 3D housing, you should confirm that it works. Extract the latest FED3 Arduino Sketch (in the files area) and the sketch "oFED_SetClock082418stable.ino" to where ever you like to keep Arduino sketches (for me it's: /Documents/Arduino).
Open the oFED_Set Clock sketch in the Arduino IDE and flash this code to the M0. You should see a message on the screen that the RTC was set correctly.
Unless you remove the coin cell from the RTC module (or if the coin cell dies after a couple years) you will never have to set the time and date again.
Next, flash the FED3 code. You should now be able to use FED3 (photos and video coming soon).
9Assemble the housing
Coming soon with photos