Introduction

 
 
 

The open-source movement isn't limited to software although that's where it seems to have started. There is also an open-source hardware movement where people provide designs for a variety of devices that can be assembled with some patience, some soldering, and a little hand-eye coordination. My initial work in this area started out with software, because the bar to entry was fairly low since computers were already required for the research in which I was involved. Electronics was something I picked up in graduate school, but my abilities there are generally limited to assembling circuits that are designed mostly or entirely by someone else. Luckily, the Internet has given me access to a lot of such designs for free! I was able to combine these two areas through the use of programmable microcontrollers, so I can take my programming and extend it to allow me to develop devices that I would not be able to design from scratch. Below are some of the electronic projects I have developed for use in classroom and research settings. Like the software I have written, I am constantly looking for new ways to use these devices and for improvements to what I'm already doing, so if you have an interest in electronics or programming of almost any sort, there is probably a way to work that into a research project!

 
 
 

Arduino - Electronics for Beginners

 
 
 

One area of open-source hardware that has really caught my attention is the use of low-cost microcontrollers that could be used for a variety of activities. The one that I have been using extensively is called the Arduino, which was developed by a group of researchers in Italy. It was originally intended as a device for people without a lot of background in electronics, which made it a good fit for me. While I have done some tinkering off and on, I really don't have the skills to design circuits from the ground up. The Arduino works as a programmable interface to the electronics, so the circuits can be very simple, with the hard work being done through software. I was much more comfortable with the software side, and this gave me a good way to get into electronics. The programming language used by Arduino is based on Wiring, and using a programming interface based on Processing. Wiring is a more general-purpose program for controlling microcontrollers, so I haven't really used it, but Processing is a programming language that can be used for programming software on a computer as well as for allowing that computer to communication with an Arduino, so it makes an excellent bridge between a laptop and a microcontroller. By playing around with different combinations of hardware and software, I have developed a number of different devices that I have been able to use in both classroom and research environments.

 
 
 
 
 

Bat Simulators

 
 
 
One of the first things I did with an Arduino is hook it up to a sonar range finder (made by MaxBotix) and use it to build a bat simulator. These sonar sensors make sounds at frequencies that we cannot hear, pick up the echoes and use them to send a signal to the Arduino to indicate how close objects in the environment are. The Arduino is programmed to play a series of beeps that occur closer together and get higher in frequency as you get closer and closer to an object. This is useful when I give presentations on bats since it is an excellent way to get a feel for the echolocation systems used by bats. Since the sonar range finder is built for use in robotics, it does a lot of the work and so the programming and circuitry are quite simple. On this version of the SimBat, I added a headphone jack and a volume knob (which goes to 11 of course) and added a button to adjust the sensitivity. I've also made a simpler version without all the bells and whistles using a piece of tupperware from a dollar store, so that people can see the "guts" of the device.

 

 
 
 

"Beep Beep" Boxes

 
 
 

A common teaching tool in science is the "black box" experiment, where students are given a sealed box with an unknown object inside and they have to devise a set of tests to figure out what it is. In a chemistry class, students running analyses on an unknown chemical serve a similar purpose. In either case, the students are developing their ability to think critically and solve problems, which is important for all college students, not just scientists. In my case, I was teaching a class on experimental design in 2011, and I wanted to make a similar sort of test, but I wanted a chance to play around with some electronics. I built four boxes out of dollar-store tupperware and some basic electronic components. Each box has four LEDs (red, blue, white, and amber), a button, a light sensor, and a small speaker. All of these were hooked to an Arduino inside the box, which was in control of the experiment. In general, the LEDs would flash in various ways and sounds that could vary in frequency and duration would be played by the speakers. Students were initially given the chance to examine the boxes when they were all programmed identically and then they could interact as groups to try and explain the behavior of these objects. Later in the semester, I reprogrammed the Arduinos in the boxes so that each group had a box that behaved differently (for example, when one box was put in bright light, the sounds coming out of the speaker were louder, while another one played softer sounds in bright light). Over the course of the semester the students were given lots of opportunities to observe these boxes and devise ways to determine what rules guided their behavior. Towards the end, students from different groups compared notes and tried to apply the methods that they hadn't thought of to describing their box's behavior. Overall, it seemed to be a good way to teach this process and because it is so easy to reprogram the boxes I was able to adjust their behavior whenever I wanted.

 
 
 
 

Echologger system

 
 
 

A major area of research that has interested me since graduate school is developing a better understanding of the real-world behavior of animals. In the case of bats, I had some success analyzing recordings that included multiple bats to estimate how many bats were actually recorded. This suggested it might be possible to get an estimate of bat population sizes by recording the bats at foraging locations and just analyzing the recordings. This would be better for the bats because it wouldn't require capturing them in nets and stressing them out, and it would be better for the researchers because catching large numbers of bats is really difficult!

The initial work I did with this project involved the Mark I recording system, which is very expensive, thus limiting the number of sites where I could get recordings, since I only had one system. There is also the problem that the recordings took a significant amount of time to analyze, which meant I had no information on what was going on in a timely fashion. I thought there was a lot of promise in developing ways to examine bat behavior without disturbing the animals (which occupied a couple of chapters in my PhD dissertation). When I came to CSU, I wanted to expand on these ideas, but I needed a way to do so that could fit within my time and budgetary constraints.

In 2010, I was reading an article in Make magazine called "Kitty Twitty". In this project the author developed a cat toy using an Arduino that was hooked up to the internet so that that it would send a tweet every time the cat played with it. I started with the same basic premise, but attached a motion sensor to the device. The initial goal was to develop a system that would detect bats entering or leaving a roost and would give a count in that fashion. The initial "Batty Twitty" system worked pretty well, but it only detected motion, which wouldn't be useful for examining bat behavior beyond entering or leaving a roost. I needed something that detected echolocation, which would allow me to examine bat behavior in the field. So I took the output from a bat detector and used it to build Batty Twitty v 2.0:

Batty Twitty 2.0 - Connection to the bat detector is through the yellow wire.

This system waited until an ultrasonic signal was detected by the bat detector, then it would try to count the number of separate pulses (corresponding to how many echolocation sounds were received) in a 30-second time period. By getting an estimate of the number of echolocation calls, you have at least some idea of how much bat activity occurred in a given location. This estimate would be sent out as part of the tweet:

 

Based on my preliminary results, the system seemed to show a lot of promise, but it was limited by two factors. The bat detector I was using (a Petersson D100) was still fairly expensive (although much cheaper than using the full recording system) and the need to have a hardwired internet connection for sending tweets meant that the system wasn't really suitable for the field.  However, based on these results, I was able to get a grant from the Clayton State College of Arts & Sciences, which I used to purchase equipment to update the system including several more Arduinos and materials I would need to overcome these two limitations. 

The first problem was getting away from the wired connection and using a wireless system. I was able to get XBEE wireless radios, which can connect to the Arduino and send messages over a distance of several hundred meters. This allowed me set up each Arduino as a monitoring station and have them transmit their information to a base station connected to a computer. The computer could then display real-time updates on bat activity. There are times where the wireless signals do not successfully arrive at the base station, meaning that I could potentially lose data, so I outfitted each Arduino with an SD card so that they can record the data locally in addition to transmitting it to the base station. The image below the Arduino MEGA which is used by the base station with the SD card and XBEE radio.

The second problem was the cost of the bat detector, which I solved by finding a cheaper alternative. A retired engineer by the name of Tony Messina developed something he calls the Simple Bat Detector (SBD). His design has been available since 1997 and he offers kits and circuit boards for it very cheaply. I tested the output of this detector and it worked very well, even compared to the much more expensive D100. At this point I felt like I had something that was going to allow me to get a lot of data in a very short while. Once I knew patterns of bat activity, I could use that to focus my efforts with the more expensive recording system so that I could get the maximum results from my time in the field. In the course of working on this system, I realized that I could take advantage of it for determining real-time bat activity patterns if I could find a way to get the information from the different monitoring stations as it was received. For this, I hooked the based station up to a computer and wrote a program in Processing that can take the data from all monitoring stations and display the data as it is received:

The output includes a time-stamp to indicate when the data was received from the monitoring station, the number of calls that were detected with the size of the colored circle corresponding to the number of calls as well, so that you have a graphical representation that is easy to interpret as it is happening. From this, I would be able to see not just that bats were active, but where they were active, and when, so that I could determine patterns of behavior much more quickly than would be possible if I had to wait for another program to do the analysis. Based on these results I'm currently working on refining the system to produce a set of bat monitoring stations that can be deployed and record data all night while giving real-time updates on bat activity over a fairly large area. With the addition of more monitoring stations, the area for monitoring could be expanded further.

 
 
 

Arduino-based Light Meter

 
 
 

Because much of my research deals with nocturnal animals, I am interested in the effects of light on their behavior as light conditions might affect the risk of predation, activity of food sources, etc. However, it is very difficult to study the effects of light on an animal's behavior unless you have a reliable way to determine the level of light at a given time. I had tried some light meters that were part of devices to measure weather conditions, but they were intended for daytime use and were giving readings of zero even before the sun had set. I had tried building a circuit to give a visual reading by lighting up a series of LEDs but due to my lack of circuit-designing skills I didn't have any luck. Once I added an Arduino to the mix, it was quite easy. At the top of the box is a photoresistor, which changes how much current can flow through it depending on how much light is hitting it. The current runs through the photoresistor and into the Arduino. The program on the Arduino lights up a series of 10 LEDs (four red, three yellow, three green) based on the amount of current it receives. As light levels drop, the number of LEDs that are activated drops. Now I can just record the highest LED that was activated (in the picture shown here it would be recorded as "2 green") and I have a much more reliable measurement of light level than I was getting when I tried to estimate it by eye.

 
 
 

Motion-sensitive IR Lights

 
 
 

Another problem with nocturnal animals is the fact that it's very difficult to see what they are doing, since they rarely wander into bright lights when I am trying to observe them. I was working with a student on a project involving armadillos, and we really needed to be able to see them moving around instead of just listening for rustling in the bushes. i have a video camera with infrared (IR) capabilities, giving an option for working with these animals with a light source that they cannot see (or avoid). One of the biggest problems I found with these cameras is that the affordable ones have a very small amount of IR light they provide, meaning you can only see a few feet. This is a problem because you must have the camera in exactly the right place or you'll miss what you're trying to see. I considered using IR LEDs as an additional light source, because you can get them really cheap online. I was going to build a box with  multiple LEDs on it and set that out in an area where I hoped the armadillos would visit, but this would require running the camera constantly and then going back to watch the video to see if anything had happened. I did some research online and found that you can purchase a motion sensor really cheaply, and that this could send a signal to the Arduino when something moved, and then the Arduino could turn on the LEDs until the motion stopped. This is the same sort of technology used in security lights that are installed outside many homes and it seemed like a good idea. I built a three different boxes with 10 LEDs on each. I used five-mm LEDs for the first box, and found they didn't really provide enough light so for the other two, I used 10-mm LEDs to get more illumination.

By looking through the viewfinder on the video camera it is possible to see when the light has gone on, and start the recording. Or you could just record constantly but when you're reviewing the tape, you could fast forward until you reached a point where the lights were on. The second method seemed like it would be less likely to miss out on anything. The boxes themselves work pretty well as you can see by comparing this picture where the video camera was zoomed in on an object of interest but there was no illumination from either box - it's clear something is there, but not much detail is available. The camera was approximately 8-10 m from the object being recorded:

Here's a picture where the camera was zoomed out and one LED box was activated:

And lastly, here is a picture where camera was zoomed in on the same object with one box activated so you can see the details:

In this case you identify the snarl on the Ninja Turtle's face in addition to his first initial on his belt. Obviously I didn't get any good pictures of armadillos, so I had to stage something of my own. The system worked fairly well, but it did have some problems with false triggers that I didn't manage to eliminate and the light from the LEDs was very directional, meaning that only a small area would be illuminated. There are a number of ways that these problems could be solved, but for a variety of reasons I haven't had time to pursue them.

 
 
 

Other Areas of Research

 
 
 
 
 
 
 
 
 
 
 
 
This website requires Internet Explorer 8 and higher.
Please update to the newest version.