-
New hopper STLs to improve dispensing
07/21/2019 at 14:50 • 0 commentsI recently updated the hopper and pellet disk for FED3 to improve dispensing. Because the hoppers use the same threading these new parts will also fit on FED2!
There’s a minor consideration with using the new parts - for FED3, the little “feet” click into the housing and ensure that the pellet foot is oriented towards the front of the device. Photo of FED3:
The FED2 housing doesn’t have anything for the feet to click into, so make sure it’s oriented with the pellet foot directly forward. If it’s off center it might result in multiple pellets coming down the pellet shoot. I could also see it loosening up over time, so keep an eye on that.
The motor also has to be more carefully “centered” than with the prior parts, to ensure the disk doesn’t rub on the walls. It is larger in diameter now so this is more of a concern than with the old disk:
Use a screw driver through the holes in the bottom to loosen the motor, make sure it's centered and can spin freely all the way around, and then tighten it up!
Please leave comments if you try this!
-
FED Python analysis package!
02/06/2019 at 18:10 • 0 commentsWe have recently finished an analysis package for analyzing FED data files in Python. (Note: by "we", I mean programmer extraordinaire, Ilona Szczot!) The goals of this analysis package are to provide visualizations and quantification of feeding rates and patterns of mice using FED.
Background: FED spits out CSV files that update whenever a pellet is taken, resulting in a file of time-stamps:
Often, we'd rather look at data in a "binned" format, to answer questions like "How many pellets did they eat in the last 2 hours?" This requires some processing.
(Note: we didn't set up FED to bin the data as it is collected because we'd have to pre-specify the bin width to do this, and this may differ between different experiments.)
Use: We wrote a GUI-based Python analysis package (also available in the Files area) that allows for a user to chose a folder where the FED output files are stored, set the circadian cycle times, choose which dates to analyse, and set the bin size in minutes. To run:
1) First dump all of your FED files into a directory. These can include multiple files from the same FED.
2) Open the script in Python 3.6 or greater. I use Spyder to run it. When you first run the script this window pops up:
3) Set these variables and click OK. A second window will pop up which allows you to filter based on mice. It will default to choosing all of the mice that have data in the folder, but you can limit the analysis to specific mice.
4) Click "OK" and the script will run, generating a new folder in your data directory, named with the unique name/time-stamp "ResultsMMDD_HHMM_SSs". This new folder will contain several visualizations, as well as Excel files containing the data underlying these visualizations.
Output: The visualizations include individual histograms for each mouse:
An average histogram of all mice:
Individual figures for each mouse showing cumulative intake, motor turns, and an "inter-pellet-intervals" histogram. This histogram tells you about meal patterning. For instance, here we can see that the mouse consumed ~250 total pellets. The "motor turns" variable reports how many times FED moved the motor to dispense a pellet - this shows you where jams happen. <10 turns in OK, if it jams you might see a number >500 turns! The right plot is the inter-pellet-interval, in minutes. Here, the peak is at ~30seconds, meaning that this was the most common interval between pellets. If a manipulation changed the eating rate within means, this peak may shift to the left or right.
A zip file has been deposited in the files area that contains the Analysis Python script, a readme, and sample data that you can run to generate the above plots. Feedback is always welcome!
-
Improved dispensing!
01/21/2019 at 17:09 • 0 commentsThe Achilles heel of any pellet dispenser is pellet jamming. There are several reasons for a jam, but one of them is that the pellets inside the hopper align in a way that impedes the movement of the dispensing disc. To combat this issue, I've modified the stepper code to make the stepper "vibrate" while dispensing. This can help shake up the pellets in the hopper and reduce jams.
Please leave feedback in comments if you try this update!
-
Around the world FEDs!
07/02/2018 at 19:46 • 0 commentsWe have heard from people building FEDs in several countries, which is great! These include Canada, France, Switzerland, Germany, S Korea, and several sites in the US! This log is recognizing where FEDs are going. Please get in touch to put your photos up here!
James Ousey sent his from Caltech in the USA:
Lydia Hanna sent this photo from Exeter University in the UK!
This is actually the FED1.0 design, from Zhenwei Su, Post-Doctoral fellow in Nick Betley's lab at University of Pennsylvania
And a FED2 from Kristina Wirkowski in the same lab!
From Sung-Yon Kim's lab at Seoul National University in S. Korea.
From Stephanie Borgland's lab at the University of Calgary in Canada:
From Diego Bohorquez's lab at Duke University in North Carolina, USA (this is one of the earliest versions of the original FED):
-
3D printing tips
06/09/2018 at 13:59 • 0 commentsThis log will include a few tips on 3D printing FEDs. Please feel free to add your own tips in the comments!
1. A note on suppports: The printer we use is cheap and does the job, the Sindoh 3DWox (This is not an endorsement of this printer over other printers BTW, just stating what we use). Because our printer doesn't print "support material", we have designed all of the parts to be printed with as few supports as possible. When you slice your models to print, it is possible that your software will want to add support. This may be OK for some parts, but you should remove any supports from inside the pellet "funnel". Stray plastic in here can cause pellet jams.
2. Inspect the pellet path for plastic strands. While it doesn't matter if they are on the housing, the FED is a mechanical device and imperfections in the pellet dispensing area or the pellet funnel can cause jams. Take care to look this over and make sure there aren't any stray pieces of plastic. For instance, in yellow I've circled a little piece that can interfere with the movement of the pellet disc in this print:
3. Different printers can produce parts with different tolerances and slightly different sizes. In particular, this can be a problem with tight-fitting parts, such as the sliding back door to FED. If your parts don't slide together nicely you may need to tweak the design a bit to get it dialed in for your printer. STL files are available in the files area.
-
FED variant #2 - "Triggered on input"
06/05/2018 at 01:06 • 0 commentsA colleague asked for a small modification to FED, such that in addition to the output pulse on the BNC connector, it would have a 2nd BNC which it would use as an input. This input would trigger FED to dispense, but we would still monitor the pellet well and only dispense if it was empty. This allows FED to act like a "smart" pellet dispenser in operant tasks, such that it not only dispenses a pellet, but detects when it is removed.
Feeling a bit lazy, I just drilled a hole in a regular FED instead of reprinting a new base with 2 holes for BNC connectors. I connected the new BNC to digital pin 5 on the Feather (remember when we put extra 90 degree headers there?), and wrote an updated code to allow for this behavior. Updated code is available in the files area, to use simply connect the input BNC to pin 5 and ground, and flash the updated code.
-
How to change the timeout between pellets
05/26/2018 at 14:00 • 0 commentsWe included a timeout between pellets to stop the mice from taking one pellet, dropping it, and immediately grabbing the next one. We set this to 15 seconds by default but it can be easily changed. In the "a_header" tab in the Arduino IDE, change the number "15" in this line to update it:
int timeout = 15; //timeout between pellets in seconds
-
Motor considerations for FED
05/26/2018 at 13:43 • 1 commentWe have experimented with several stepper and servo motors to control FED, and we found one that works well for dispensing pellets. This log will describe a bit of our experience and what to look for if you want to choose a different motor for a pellet dispenser.
We needed to find a balance between having a motor that is strong enough to move the pellet disk, but also weak enough to not grind up pellets if it encounters resistance. Grain pellets disintegrate very easily, and create dust that can gum up the works. While stepper motors are a bit more complicated to control than servos (they require a driver board), we found that they are a better choice as all of the servos we tried would grind up pellets and result in pellet jams. They would typically work for a couple of hours, but after 1-2 days they would look like this
Obviously this FED can no longer dispense until it is unclogged. So if you want to experiment with different motors, or designing a different pellet dispenser altogether, we recommend choosing a geared stepper motor that will stall when it encounters resistance, rather than powering through and pulverizing the pellet. While this can take a bit longer to dispense a pellet, we coded the motor to try dispensing 10 times, and then perform a big movement to dislodge any jammed pellets.
As one final point, if you use sucrose pellets they are much harder than the grain pellets and are therefore more resistant to crushing and jamming.
-
(sorta) Mass production!
04/27/2018 at 18:20 • 0 commentsWe're currently building a group of 12 FEDs - I'll post how they turn out when we have them all but here are some production pics!
Update 06-04-18: Here we go, 14 FEDs!
-
Troubleshooting
03/20/2018 at 22:38 • 0 commentsThis will be a log dedicated to troubleshooting. I'll edit this post as more issues are identified and (hopefully!) resolved.
- FED code won't compile in the Arduino IDE - errors about RTCZero come up. There is an incompatibility between the code for Pail Stoffregen's Timelib library that is used by FED and an older Time library in the Arduino IDE. The issue is documented in comments here: https://www.hackster.io/jkoger/simple-watch-using-rtc-59e635. Long story short, to fix this, go to wherever your "Time-master" library is installed (mine was in User\Documents\Arduino\libraries\Time-master), and rename the file "Time.h" to "Time_h.h". Restart the Arduino IDE and this should fix the issue.
- Motor won't turn after building hardware - Check that battery is plugged in and charged. The motor requires the most current of anything in FED. When it is low, or if FED is powered by USB without a battery connected, everything else can appear to work but the motor won't receive enough current to turn.
- FED keeps spitting out pellets and wont' stop! There are two main reasons why FED may not detect that a pellet has been dispensed: 1) If the photo-interrupter is not correctly in place the pellet may not be detected. Make sure the pellet lands in between the "arms" of the photo-interrupter. 2) The photo-interrupter works by detecting the IR LED in one arm with an IR detector in the other. If there is a lot of ambient IR light (for instance, if FED is in direct sunlight! the photo-interrupter may not detect the pellet. We've experienced this issue even indoors, when FED is placed in direct sunlight from a window.
- FED takes a while to dispense each pellet. FED will attempt to dispense a pellet and continue trying until it is successful. If something is impeding the pellet disk from turning, this can take many attempts. We have found that sometimes a small bit of plastic from the printing will get in the way (see yellow circle below for example). Watch FED try to dispense with no pellets - if it seems to be getting caught make sure there is nothing impeding the turning of the disk
- FED dispenses 2 pellets. In our hands, this happens <1% of the time. We have found it very hard to reduce this further. If it is occuring at a higher frequency than this, make sure the photo-interrupter is positioned correctly as it may not be detecting the first pellet.
Please message me more issues and I'll log solutions here!
- FED code won't compile in the Arduino IDE - errors about RTCZero come up. There is an incompatibility between the code for Pail Stoffregen's Timelib library that is used by FED and an older Time library in the Arduino IDE. The issue is documented in comments here: https://www.hackster.io/jkoger/simple-watch-using-rtc-59e635. Long story short, to fix this, go to wherever your "Time-master" library is installed (mine was in User\Documents\Arduino\libraries\Time-master), and rename the file "Time.h" to "Time_h.h". Restart the Arduino IDE and this should fix the issue.