Traffic Counter Setup


Things I used:
  1. A loop under the road, 50 cm apart
  2. A detector, a Sarasota 215B with an external transformer from 240VAC to 120VAC.
  3. A Raspberry Pi B+
  4. 16GB USB memory connected to the Pi
Function:
Overview:
Overview:

Details:
I have two detector loops using the same UTP CAT5 feed.
Since the loop cable have multipel leaders I can chose how sensitive I want
the loop to be by connecting each turn in serial, E.G. below the blue and brown
is connected in serial.
A multipel leader gives you a choice of turns.

I replaced the old connector.
For the second loop, I'm using only the blue cable.
Bild av kopplingsdosa med sockerbitslist.
(If these two loops were on the same road and separated by a known distance,
the Pi could theoretically calculate the speed of a passing vehicle.)

Three LEDS and the white cables from the relay.
Raspberry Pi B+

To protect the Raspberry's GPIO ports and to prevent bouncing,
I added two 2.4k resistors in series and a capacitor and a resistor in parallell.

Resistors and capacitor


This is the Python program running on the Pi.