The idea for my final project is design and build a hive for the bees, and controlled it by diferent sensors, to know more about the bees.
With the sensors I want to know:
It would be also interesting:
The final presentation of my project is on the 16th of June
I completed the the electronic parts, but separatly, now I have to mdoify the program to networking wire the different boards. I also build the beehive, it remain to put some sensors and the connections with the boards.
With patience, without getting nervous and dedicating hours.
In general, everithing works correctly, I obtain the correct values, I can print with the LCD.
It is very complicated do programs without using libraries (some of the sensors that I want to use in the future, the library for Arduino is not compatible for Attiny, and there is not the library for Attiny, in this way I need to program without using libraries).
I learned a lot in differents fields, specially about electronics. Before starting FABACADEMY, I thought it might be very interesting, but after I did it, I can say that it has exceeded my expectations. I also learned a lot about time management, researching and documenting.
I desgined a parametric beehive with solidworks. In all the archives I imported the lenght of the differents parameters. I put also the tolerance depending on the machine used to do the different pieces.
First of all, I chose the size of the beeswax, 360x300 mm (height x width), which will determinate the rest of the lenght. For each honeycomb I need to do four pieces with wood: the bottom, the lateral(2), and the top.
In this part, I considered the size of the honeycombs and also the number of honeycombs I want to put in the brood box, 10. Also I had to considerer the space for the sensors, where the bees can not be access. On the bottom there will be a resistence to warm up the beehive, to separate the resistence from the bees I will put a glass. On the front and the back, there will be the two load cell, and a temperature and humidity sensor and sound sensor. I put also gaps to ventilate it.
In this part, there will be the electronics to control the different sensors. Also in the top there will be more sensors: humidity and temperature sensor, a light sensor, a sensor to detect the rain, and maybe a solar panel to supply the electronics. Also, there will be a gaps for the ventilation of the beehive.
My first idea, was to do the pieces that I only need to cut with the laser machine (because spent less time), and the pieces, which I need pockets, with the CNC. But unfortunately, the laser machine in our FabLab had to be repaired; it is for this reason that I had to modify the pieces that I had designed for the laser machine. In this table, I show the different pieces, the thickness to do them and the machine that I would use to do them.
Piece | Nº pieces | Thickness | Machine | |||
16 | 18 | 25 | LASER | CNC | ||
HONEYCOMB | ||||||
beeswax |
||||||
bottom_hc |
10 | X | X | |||
lateral_hc |
20 | X | X | |||
top_hc |
10 | X | X | |||
BROOD BOX | ||||||
base |
1 | X | X | |||
drawer_bb |
1 | X | X | |||
guide_bb |
2 | X | X | |||
front_bb |
1 | X | X | |||
back_bb |
1 | X | X | |||
honeycomb_beam_front_bb |
1 | X | X | |||
honeycomb_beam_back_bb |
1 | X | X | |||
lateral_right_bb |
1 | X | X | |||
lateral_left_bb |
1 | X | X | |||
stick |
2 | X | X | |||
support_cell_front_bb |
1 | X | X | |||
support_cell_back_bb |
1 | X | X | |||
SENSOR BOX | ||||||
base_sb |
1 | X | X | |||
base_ventilation_sb |
1 | X | X | |||
drawer_sb |
1 | X | X | |||
guide_sb |
2 | X | X | |||
lateral_left_sb |
1 | X | X | |||
lateral_right_sb |
1 | X | X | |||
front_sb |
1 | X | X | |||
back_sb |
1 | X | X | |||
door_sb |
1 | X | X | |||
block_door_sb |
1 | X | X | |||
top_sb |
1 | X | X | |||
inclinated_top_sb |
1 | X | X |
The laser machine of the FabLab does not work, it is for that reason that I adapted all the pieces to be done with the CNC. Also I modify some aspects of my prototype.
Piece | Nº pieces | Thickness | CNC | |||
16 | 18 | 25 | 1 SIDE | 2 SIDES | ||
HONEYCOMB | ||||||
beeswax |
||||||
bottom_hc |
10 | X | X | |||
lateral_hc |
20 | X | X | |||
top_hc |
10 | X | X | |||
BROOD BOX | ||||||
base |
1 | X | X | |||
drawer_bb |
1 | X | X | |||
guide_bb |
2 | X | X | |||
front_bb |
1 | X | X | |||
back_bb |
1 | X | X | |||
honeycomb_beam_front_bb |
1 | X | X | |||
honeycomb_beam_back_bb |
1 | X | X | |||
lateral_right_bb |
1 | X | X | |||
lateral_left_bb |
1 | X | X | |||
stick |
2 | X | X | |||
support_cell_front_bb |
1 | X | X | |||
support_cell_back_bb |
1 | X | X | |||
SENSOR BOX | ||||||
base_sb |
1 | X | X | |||
drawer_sb |
1 | X | X | |||
guide_sb |
2 | X | X | |||
lateral_left_sb |
1 | X | X | |||
lateral_right_sb |
1 | X | X | |||
front_sb |
1 | X | X | |||
back_sb |
1 | X | X | |||
door_sb |
1 | X | X | |||
top_sb |
1 | X | X | |||
inclinated_top_sb |
1 | X | X | |||
cam_sb |
4 | X | X |
After the design I distributed the pieces in 5 wood tables (2 units of 2000x500x25 mm, 2 units of 1800x450x16 mm, and 1 unit of 2000x500x25 mm). I prepared the different Gcode with rhinoCAM for the ShotBot_MTC, in this case I use two tools, the flat6 and the ball6; the first one to do the engravings and cuts, the sedond one I used to do the inlinated areas. In all the folders the order is (if there is the two sides to mill): 1 A_SCREWS; 2 A_6 FLAT, 3 A_6 BALL, turn the wood and 4 B_6 BALL (to do not change the tool); 5 B_6 FLAT. I mill two sides in 3 wood tables and one side in 2 wood table, but in one of these (25 brood box) I saw that I need to mill the other side, it is for this reason that you will find extra documents on the files if you download. To do the doble milling, in this ocasion, we fix some guides in the 4 sides of the table wood to do not lose the zero; I did the same for the pieces that I mentioned before (I did only one milling side but they did both milling side).
When I had all the pieces I sand them and later assembled. I puta glass betwwen the resistence and the brood box. In the brood box there is a door to manipulate the boards, in this door I put a piano hinge. There are also some holes in the wood, these are to ventilate the beehive, I put mosquito net in all of them with a stapler.
On the top of the beehive I will put a meteo station, this will have the tmeperature and humidity sensors and pressure sensor. I measured the size fo the both components and I designed the meteo station cosidering them. The meteo station it will built with 7 pieces: base, sensor stick, ring (4) and top ring.
In the sensor stick I left the gaps to hold the sensors, on the left the temperature and humidity sensor, and on the left the pressure sensor. On the bottom I also put a gap for the wires. The base, the rings (4) and the top ring have 3 holes to put a M4 bar, all the holes are the 4 mm, except the top ring, where the hole is the 3.5 mm, in this case I will do the thread to fix later the bar.
I printed the different pieces with the 3D printer. When it finished, I trhow of some material (with a screwdriver) that the 3D printer put to built the different pieces.
Description | Refernce | Quantity |
20 kg load cell | 20 kg load cell + HX711 | 2 |
Temperature and humidity | AM2302-DHT22 | 2 |
Light | GY-302 | 1 |
Pressure | GY-BMP280 | 1 |
Sound | LM393 | 1 |
Rain detector | FC-37 | 1 |
Wind speed | 1 |
Load cell | HX711 Inputs |
Red wire | Pin E+ |
Black wire | Pin E- |
Green wire | Pin A- |
White wire | Pin A+ |
HX711 Outputs | Kind of signal |
Pin GND | GND |
Pin DT | Analog |
Pin SCK | Analog |
Pin VCC | 5 V |
LM393 Outputs | Kind of signal |
VCC | 5 V |
OUTPUT | Digital |
GND | GND |
AM2302-DHT22 Outputs | Kind of signal |
DAT | Digital |
VCC | 5 V |
GND | GND |
GY-BMP280 Outputs | Kind of signal |
VCC | 3 V |
GND | GND |
SCL | Analog |
SDA | Analog |
CSB | |
SDO |
I attached the temperature-humidity and pressure sensors on one of the pices of the meteo station and I connected their wires.
Connections:Signal | Color | |
Temperature and humidity | GND | GY/GN |
VCC | PK/GY | |
DAT | WH/GN | |
Pressure | VCC | RD/BU |
GND | BK | |
SCL | GN/BU | |
SDA | YE/BU | |
CSB | BN/BU | |
SDO | GY/PK |
I would to control a lot of sensors, and it requires a lot of analog inputs, it is for that reason that I thought to do more than one board and networking and communication them. The majority of the sensors that I had, use a library, in this way I belived that the best idea was to use the ATtiny 85, which has 8K of memory, and it will control one or two sensors. All the boards will be the same.
I put also a regulator of 3,3 V because I on sensor works at this voltage, this one I will put only in one board, but I leave the pads to intagrate it in all the boards, because if in the future I need another sensor which works at this voltage, I will only need to welding it. In all of them I put the connector to supply and communicate the boards each other. There is also two connectors on all of them for the two sensors, these connectors share some pins, this is because firtst I will program the ATtiny microcontroller, and after that I will connect the sensors (these has only 4 pins as maximum). Also I put the FTDI header, this one I need only in one of the boards, but I put in all of them.
First of all, I tried to program the sensors with Arduino. When I finished this step, I begin to program every sensor alone in one board (microcontroller Attiny).
First I porgrammed the tmeperature and humidity sensor, I have 2, one inside the brood box, and the other outside, in the meteo station. To program it, I did the program with Arduino. To upload the program I used the FabISP that I made on week 04: electronics production, I connected it with the inputs board, and with Arduino, where I chosen, the Board: Attiny, Processor: Attiny85, Clock: 8 MHz and Programmer: USBtinyISP.
I did the same as the sensor before but now, I adapted the program to this sensor. The output should go momentarily high when the sound is louder than the threshold setting and viceversa. To know if the sensor works I regulate the threshold with a screwdriver as we can see on the results.
The next step was trying to do a program for the LCD which has to read the values for the port Serial and showed in the LCD, and a program for the temperature and humidity sensor, which has to write the values of the temperature and humidity for the Serial when it receives for the port Serial its id.
When I finished these two programs I 'joined' them to do the final program. First I tried with two boards, the LCD board (output) and the temperature-humidity board (inputs); and later I did with three boards, one output and two inputs networking them.
In this last program (one output and two inputs) I had some problems because I did not obtain the values correctly, I had to modify a little bit the program but it was not enough, has we can see at the end of the video there was a little bit of noise, this I suppose that was because the wire for the networking was too big, but I decided not to cut it because in the future I want to put more boards, I decided to put a resistence of 10k between the TX(of inputs; or RX of outputs ) and GND to remove this noise.
To end, I placed the sensors in the beehive and I connecting them with their respectively boards.
1.1. Attiny84 (1 unit).
1.2. Attiny85 (4 units).
1.3. Other electronics components as resistence, capacitors, etcetera.
Description | Quantity | Price/unit | Total price |
20 kg load cell | 2 | 5.99 € | 11.98 € |
Sound (LM393) | 1 | 1.87 € | 1.87 € |
Temperature and humidity (AM2302-DHT22) | 2 | 4.50 € | 9 € |
Pressure (GY-BMP280) | 1 | 1.98 € | 1.98 € |
Description | Quantity | Price/unit | Total price |
Pine board 2000x500x25 mm | 2 | 26.95 € | 53.90 € |
Pine board 2000x500x18 mm | 1 | 14.95 € | 14.95 € |
Pine board 1800x450x16 mm | 2 | 13.95 € | 27.90 € |
This final project is licensed under the Creative Commons Reconocimiento 4.0 Internacional License.