registerValueCallback (distanceChangeCallback ) # each time the distance changes significantlyĭistSensor. # distanceChangeCallback is called automatically exit ( "no camera" )ĭistSensor = YGenericSensor. # if the distance is between 2 and 4 meters, trigger A breeze.ĭef distanceChangeCallback (fct ,value ): If the range in between 2 and 4m, then the camera is triggered. The Raspberry PI is controlled with a simple Python script: We installed a callback on the range measured by the sensor. We put the system in a box fixed on a tripod ![]() How the camera trap parts are connected together We placed the whole system in a box to make sure it can be moved easily, and powered it with a big USB battery. That Raspberry PI also controls a camera through a Yocto-Relay as we did here. This is almost trivial: we just connected a SRF06 to a Yocto-4-20mA-Rx, that Yocto-4-20mA-Rx is also connected to a Raspberry PI. In order to test the SRF06, we built a camera trap. How to configure a Yocto-4-20mA-RX to work with a SRF06 The unit is cm, 4mA is mapped to 0cm, 20mA is mapped to 510cm, that's it. This is dead easy to achieve with the VirtualHub. ![]() When the SRF06 is connected, the Yocto-4-20mA-Rx needs to be configured to make sure it reports correct values. How to connect a SRF06 to a Yocto-4-20mA-RX. You have to read the user manual to know the right polarity: there is no marking on the board. Unlike the Sharp sensor that we tested some time ago, it provides a calibrated 4-20mA output, not an approximate voltage output.Īs the SRF06 is powered directly from the current loop, we only need 2 wires to connect it to a Yocto-4-20mA-Rx, the only pitfall is the polarity. On the other side you find the electronic part. It's a tiny 43x20mm board with on one side both the ultrasonic transmitter and the receiver. The SRF06, an ultra-sonic range finder with a 4-20mA output. So we looked for a cheaper alternative, and we found the SRF06 from Devantech. We did some research, but it seems that all industrial range finders are very expensive. However, with a 250€ price tag, it tends to frighten the most enthusiastic customers. It's an industrial sensor, precise and waterproof. ![]() We usually suggest the FADK 14 from Baumer. That's why, when we are asked for a Yocto-RangeFinder, we suggest to use a range finder with a 4-20mA output and to connect it to a Yocto-4-20mA-Rx. Making a range finder would require some know-how we don't have (yet). However, we do have some reasonable alternatives. Well, the answer is " no, not a this time". We are often asked if we have any plan for a range finder.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |