Using GPS To Stay Aware Of Red Light Cameras

red-light-camera-alerter

Depending on how you view them, red light cameras are a great way to get people to drive carefully, or an utter nuisance. We agree with the latter opinion, as does [Dave], so he built a handy little device that alerts him when he’s about to approach one of these intersections.

His Red Light Camera Alerter is based around an Atmega 328P sporting the Arduino bootloader. The micro obtains GPS coordinates while [Dave] is driving, comparing his current location with a table of all known red light intersections in the area. As he nears a red light camera, the status LED changes colors from blue to yellow to red as he gets closer, making it easy to keep aware of his situation. He also included an Adafruit OLED display in his device, which relays his speed, GPS coordinates, heading, and actual distance from the red light in real time.

While [Dave] admits that he doesn’t really have a need for the alerter as there are only a couple located in his immediate vicinity, he says it was a fun and easy way to get some experience with using GPS sensors in his projects. He doesn’t have any video of it in action, but you can find the code he uses to drive the alerter on his blog.

62 thoughts on “Using GPS To Stay Aware Of Red Light Cameras

  1. Will be very useful in Philadelphia, as they are being set up at intersections known for large numbers of accidents and I want to respect them in case I miss the signage.

    1. Here in Australia it’s very obvious where the cameras are, there’s no need for GPS. Wherever there is a camera there are tall poles nearby with colour-coded lights on them. When the lights are glowing red it means the camera is active, and they’re bright enough that you can spot them in plenty of time.

      1. A bunch of the red light cameras here (Australia) are speed cameras now too. So now when you go through an intersection, rather than looking out for idiots doing stupid things you are looking at the speedo to make sure you don’t get a ticket. Thats obviously safer than going 2km/h over the limit (0-15km/h over the limit here is a $300 fine).

        All lights here have a minimum of 4 seconds of yellow.

        Red light cameras a fine, driving through a red light except under extenuating circumstances is just dumb. (motorcycle not setting off the sensor, blood spurting from your chest etc)
        In 15 years of driving I’ve done it once, it was 3AM and there were 2 sets of lights 20 meters apart, I looked at the wrong set, no camera there and no other cars around at all but I still regard it as one of the dumbest things I have done.

        Making red light cameras into speed cameras is about as dumb as my mistake, sure it was late and everybody was drunk when you came up with the idea but your sober now, come to your senses.

        A camera I want to see is a merging lane camera. Fine douchebags who don’t know how to merge onto the motorway! AND mandate a sticker on their car so everbody knows they are a douchebag after repeat offenses. Government would make assloads of money, and everybody hates people who don’t merge properly! (merging is also one of the leading causes of accidents so cameras there would be handy)

  2. Here in Germany they are everywhere. Not a bad things, since some people drive wreckless. But there are regular Android apps and navigation systems which have the same functionality. No hack though…

    1. – If you use a headphone jack, then maybe someone will plug their headphones into it? (kidding) This isn’t going into mass production, so ho cares? It’s a nice project… – For one headphone jacks make the device look like it’s not from the 80’s, and two they provide more connections. Yes, a HJ may be a serial standard, but you can’t pass power also (not by the standard anyway). With USB you have enough lines for serial and power and a misc line across the connection, which is generally more useful…
      — Any way, nice job on the project!

      1. “but you can’t pass power also (not by the standard anyway)”

        Not just a standards issue, preferably you don’t pass power through a headphone jack at all, glad to see he isn’t. USB is ok because the pins are parallel to one another. With headphone plug/jacks they the tip and middle ring(s) can make contact with parts they shouldn’t during insertion and removal. Don’t do that with power!

        ” For one headphone jacks make the device look like it’s not from the 80′s”
        I think you meant USB. If so this statement makes me a little sad. I think that line of thinking in the commercial world leads to unnecessary incompatibilities and extra headaches for us geeks that think ‘wouldn’t it be cool if my X connected to my Y…’

        “This isn’t going into mass production, so (w?)ho cares? It’s a nice project…” Yes. That was the best response. So why am I even bothering to write this one?

      2. @ Leif,
        – I agree with your reasons beyond ‘standards’ to not use headphone jacks, and have not used them because of this myself before.
        – With my statement that ‘made you sad’, I think I did not convey that idea very well. I don’t believe in ‘making new standards just to make them’ or for progress, and generally would avoid proprietary connections. USB tends to be a more current standard and is widely available in items, that was why I’d prefer it. Especially if it ‘mostly’ follows the standard pinouts for +/-, dIn, and dOut. Kind of like I’d rather see a usb over a old school DIN5 keyboard connector on something, because even if it isn’t completely standard communication through it, I probably have a usb cable around the house I can hack off and splice into something with, and if it follows closely to standards it’s pretty quick to reverse engineer and get something talking to it. More older/nonstandard connections are harder to come by… The more we can cross connect and easily make interconnects the better…

    2. Don’t recall seeing any regular 1/8 headphone jacks having 4 conductors (which is required in this case). Note my reference to ‘regular’. The newer remote enabled headphones have 4, but have you tried working with the wiring within these? Go ahead, tear one apart and try soldering the stuff they use in there…

    1. The problem is most municipalities adjust the light timing to catch people going through yellow lights in a red, in order to boost revenue. That happened in my town, but after an outcry at a couple of town meetings town officials voted to take them down to keep the whole debacle from costing them the upcoming elections (my town doesn’t run on a council; it’s hard to explain, but it comes out of the Victorian era.)

      In Texas, it’s been revealed that quite a few cities installed red light cameras without even the thought of ‘preventing accidents,’ but instead ‘we need money and this seems like an easy way to make it.’ Most municipalities contract the cameras out to massive corporations which are hardly well-intentioned either.

      :)

      1. There have actually been studies done that show red light cameras increase accidents even without the timing changes, though even more so with the timing changes that typically accompany the cameras, as people start to panic stop when the light turns yellow, so as not to recieve a ticket from the red light camera.

      2. Yes – in California, the business is farmed out to a private enterprise. You do not even get to go to regular traffic court. There is a special, separate traffic court set up JUST for red-light camera violations. It is actually quite surreal.

        They DO cut-back the yellow-light time.
        Shorter yellow-light time increases the probability that someone’s going to accidentally stop a few inches over the white-line, get snapped, and nicked for a $300 ticket, which increases revenues. This is by far, the overwhelming majority of people who get busted by these systems. NOT people who blow through red-lights. (because people don’t actually DO that at busy intersections, because, it’s actually stupid, you’ll die doing that – and that’s a pretty big punishment. If you’re not deterred by that possibility, then you’re not deterred by the possibility of getting snapped for $300).

        Apologists say that the shorter yellow-light “improves overall traffic-flow”; while studies have proven that it INCREASES rear-end accidents at intersections, due to sudden stops.

        If there were a law that put a HARD LIMIT on the minimum time they could set for yellow lights (and keep it a reasonable minimum, same as for non-camera-protected intersections), and also, SEVERE PUNISHMENT (like jail time) for traffic engineers and officials who engage in abuse of the system (like shortening yellow-lights to increase revenue), then I wouldn’t be so hostile to this idea.

        To me, the genius application of the technology of THIS hack, would be to activate an IR LED located next to the license plate, to obscure the number as you approach a traffic light camera. No, I have no ethical problem with that, at all.

      3. Accidentally hit report instead of reply on FrankTheCat…

        Anyway, in response to g2-efdca34af7cf17db4cb180afae714b0: While the shorter yellows increase the total number of reportable incidents, they effectively convert deadly T-bone collisions into relatively minor rear-end bumper taps. And before you start in about supposed “whiplash” in rear-enders, why don’t you actually look at injury statistics? Fewer people getting injured = good.

        Niru, you don’t have any ethical problem with injuring people? Shame on you!

      4. Not only is the light timing set to disadvantage the driver, but here you are still ticketed if you stop for the light, but stop forward of the painted line. This is not about safety, it is about stealing from the public. Driving on the streets is like playing lotto where the state wins.

        Why bother with the project when there are so many GPS available where you just load in these waypoints? Seems like a lot of work compared with buying a Garmin.

    1. Agreed! That’s the best reason there could be to chose a connector! Did you know that here in the US our current power outlets were basically designed in the 1920s? Sure, the design has been modernized a bit with the ground plug and polarization and all but it’s actually still backwards compatible.

      I mean come on, it’s almost 100 years already! It’s time we all change the plugs on each and every of our devices to something more slick and modern. I mean come on, compatibility and standardization are so unstylish.

      Here’s my suggestion… how about magnetic connectors, a bigger, higher wattage version of what an Apple laptop uses. What can be more hip than Apple right? I’m sure nothing could go wrong with that idea. And changing all our outlets and plugs would be fun!

      Seriously though, nothing against the original project, the maker or his choice of connectors, for personal projects use what you have!

    1. It’s not actually showing the light state, it’s simply warning you, saying “that the traffic light has a camera attached to catch people running a red light, so make sure you keep an eye on it”

  3. I might be misunderstanding what a “red light camera” is but isn’t that a camera that snaps a pic of you if you run through a red light, as in traffic light? Isn’t the actual red light a warning? I don’t get it, is it common for people to drive through intersections when the light is red? Seems… suicidal.

    Again, I might be missing something in the translation here but I kind of doubt it.

    1. I don’t mean to be insulting, but your viewpoint is a bit naive. Reasonable people look at a red light and think, “I should stop. I don’t want to cause an accident.” All too many people think, “If if run this red light, I will arrive at my destination sooner.” And still others think, “This red light is stupid, I am not going to abide by it. I am a rebel.” Another group of people just drive way too fast and can’t stop in time so they blow through lights as they transition from green to yellow to red.

      My Mom and stepfather moved to Fayetteville, NC a few years back and my stepfather tells me that when the lights turn green, no one moves for a good five seconds because red light running is so rampant there.

      1. There’s one traffic light I’ve lost count the number of times I’ve gone through on red on my bike. During the day I don’t run it because it’s a busy junction, but at night there are no cars around and the sensor doesn’t see me, so I put my light on full beam (10 watt ‘floodlight’) and go over.

      2. Yeah I can see how you got that from my post, it was worded with a bit of feigned stupidity to get the point across.

        What I’m wondering is why in the hell would someone who is bright enough to create this thing NEED it in the first place? I’m fully aware that there are morons around that care little about their own or other peoples safety. But, when I see someone going out of their way to create a fairly sophisticated device to allow them to more safely (as in monetary safe) run red lights it just boggles my mind.

      3. Red light cameras don’t just catch people who blatantly run the read; they get folks who enter the intersection while the light is yellow and have a bumper over the line when it changes.

        The real problem is that longer yellows demonstrably make for safer intersections both for cars and for pedestrians. There’s tons of data to support this. However, areas that install red light cameras pretty much invariably try to shorten the yellow to catch more people, so they get more revenue. Red light cameras may seem like a good idea, but the policy changes that follows them all too often make the intersection less safe.

  4. I take it that people think that this is to help people run through red lights. It’s supposed to help people know if they are coming upon one so they know to prepare to stop.

    1. The title says “Using GPS to stay aware of red light cameras”. CAMERAS implies it’s a device to alert you of a red light camera, NOT any generic red light. Again, people should be equally cautious at EVERY red light regardless of camera.
      Now I’m thinking, an alerter for EVERY red light would be cool… adjusting the timing by current speed and heading.

  5. I agree with sneakypoo completely, this is a problem we face in India a lot, except there are no cameras. So unless there’s a cop, you get lucky, and a lot of people risk it at night, it’s an epidemic. The light itself is the warning to, you know, slow down or stop. I can’t count the number of times I’ve been rear-ended at an intersection just for following the rules.

    On the other hand, from a purely technical perspective, I like the project. Nice implementation.

  6. For the better part of two years my walk path to work took me past red light cameras arrayed on the on ramps and off ramps of I-95.

    There would be multiple instances where I’d see the camera units flashing away. So I don’t trust flakey hardware.

    1. I too have seen the flash going off without reason, particularly when it was raining quite hard, but no one was near the intersection.

      I haven’t been caught by one of these cameras yet, but there are several monitored intersections near my home. I’m generally overcautious, but with all the crying about the cameras, I anticipate that eventually they’ll get me, guilty or not. Hopefully they require a picture containing both the red-light AND the car allegedly running the light.

      What has always got me was drivers who ignore the “STOP HERE ON RED” sign before the train tracks. They’ll drive right up on the tracks and sit, waiting for the light. I saw one that had to spaz out and throw it in reverse to get out when the crossing guards came down.

      I couldn’t believe it a few months ago when some id-10-t stopped at the red light, then proceeded to drive through it. o.O It’s not a stop sign! lol

    1. The red light cameras in our area are not obvious and don’t ‘announce’ via flashing lights etc. There may be a sign posted conspicuously along the side of the road en-route.

    1. I am all for obeying street/driving laws. I am all for being ticketed and paying the penalty if a cop observes an infraction.

      However, obeying signs and driving safely will not insulate you from being screwed by a traffic camera.

      If you think that these systems are set up for public safety, you are either naive, or you receive a paycheck from the companies that build and administer them.

      Do some research into the number of class-action lawsuits that have been won (San Diego is a nice place to start) because systems were purposefully set up with reduced yellow-light times to extort money out of as many people as possible. Pity those lawsuits didn’t allow the victims to recover all of their expenses due to increased insurance premiums.

      One final thought: No bank robber, no serial killer, no child abductor, no hit-and-run driver, no drunk or drug-impaired driver, nor any other criminal for that matter, has ever been captured by a robot camera. On the other hand, there is no end to the list of criminals apprehended because a motorcycle cop or patrol officer noticed suspicious behavior, a distressed passenger, or a burned out tail lamp.

      Public safety requires boots on the ground. If you care about public safety, you hire human beings to patrol. If you don’t care about public safety, just revenue, then you install cameras.

    1. Quote: “This is more of a proof of concept project to me than it is useful…” Translation – it’s not going to be used. Why can I say that? Because I built it. Yes, sometimes people just build things because they can… :-)

  7. First: this is a very cool build, and its approach was extremely well thought-out and executed. Kudos, [Dave]. I really dig this project.

    Second: There is another (unexplored) hiccup with the Red-Light camera fiasco: how does the system prove that *you* were driving the vehicle at the time of infraction? When the use of red-light cams is primarily a revenue-earner, I begin to think such a device might come in very handy.

    Third: Why does everybody always assume that everything that gets built/hacked is always done so for nefarious intent? Not everybody is an evil genius; sometimes they’re just a genius.

    Excellent work, [Dave]. This is a truly rockin’ idea, and I can see how it might bridge to other, more “practical” experiments later on…

    1. “…(unexplored) hiccup with the Red-Light camera fiasco: how does the system prove that *you* were driving the vehicle at the time of infraction?”
      There’s a picture of the driver, actually. They send that to the registered owner and he either owns up or tells the court who it was/is and you don’t want to take on ‘contempt of court’ or anything. It’s a Big Bust and rarely would anyone take the hit (some indulgent parent maybe) for another.

      And there are other pictures of the infraction [Yes, “8×10 color glossy pictures with circles and arrows and a paragraph on the back of each one explaining what each one was, to be used as evidence against us..”] showing the vehicle’s position, signal status and time (emph. split-second).

  8. I’m torn over red light cameras. Stopping at a red light is so easy to do and it’s law. I just don’t understand I see so many people flat out ignore. Have some people become that impatient (/ignorant/stupid/whatever) that they can’t wait 20 to 60 more seconds? Wouldn’t if everyone simply stopped at stop signs and lights take most of the wind out of red light cameras movement?

    I’m all for red ligh cameras, however after reading some posts, it appears some municipalities are abusing them. Perhaps some oversight is needed (woo hoo to more bureacracy) to ensure the cameras + light timings are being operated honestly. It is sort of sad that some people in society feel it’s OK to break the law and some others feel that it’s OK to treat the cameras as nothing more than another revenue stream.

  9. It’s a nice idea, but commercial off-the-shelf sat-nav units have supported this since they first became popular. You can add a list of spots for them to warn you at. Obviously it’s not ADVERTISED for dodging speed-cameras, but locations of speed-cameras, collected by motorists and regularly updated, are available on the Internet. Presumably where our maker got his.

  10. I just have a satnav with this feature, also (until I switched it off) the damn thing would chime up all the time saying “you are over the speed limit”.

    However, like in some other countries we also have not only coloured lights on poles but a system of driving where we actually pay attention to the lights telling us to stop.

  11. A lot of people are missing the point of this build. This contraption does not make you invisible to the red light cameras. It doesn’t block any view, or turn them off or anything else. It lets you know when you are coming up to an intersection that has a camera, and how far you are from it. All of the people assuming that he built this so that he could run red lights are obviously not paying attention. It’s an indicator, nothing more.

    I think this is a good idea for a build. In some cities in TX, a red light camera will snap your photo and get you a ticket for making a right turn at a red light. Any time you pass that stop line, the camera takes a photo. It doesn’t care what the circumstances are. The camera intersections are also not marked in many cases, so you could be in mid turn and get blinded by a flash as the camera takes your photo. It’s quite dangerous.

    If this were built to evade speed cameras, those internet evalgelists would have a point. As it is, this is a novel and well executed build. Those with other GPS hacks can benefit from your information. Thank you.

    1. They do that in EVERY city that uses them (take a picture when making a right at a red light) and they don’t give out tickets because they know WHY you passed through. They are radar guns, they know the speed you were moving at the point the picture was taken. So, if someone got a ticket for making a right on red, then they probably didn’t stop before making a right on red. I have had my picture taken by these many times while turning right on red, and never once received a ticket. Because I, umm, stopped and looked before making a right. Don’t be deceptive and act like people don’t just turn right without stopping when they THINK they know the intersection was clear. We wouldn’t have so many “accidents” (I call them accidents loosely) of this nature if they didn’t.

  12. Odd, all these people complaining about short yellow light times, etc. etc… the yellow light is meant to tell you to STOP safely. What the problem REALLY is is that most people view the yellow light as a reason to speed up in an attempt to get through the intersection before it turns red. If the light is yellow, it is about to turn red, so stop as long as you don’t have to slam on the breaks to do it.

    This is why in EVERY major city, people sit at green lights for 5 seconds before they go. Because they know, invariably, some asshole is going to push that yellow light and end up in the intersection on a red light. Unfortunately, general stupidity doesn’t allow them to realize that all they manage to do is shift that extra “waiting” time to the people sitting at the green light instead, which will be THEM the next time THEY stop at an intersection.

    The excuses are irrelevant. If there is a crosswalk light at the intersection, there is a flashing “Don’t walk” signal that tells you that the light is about to turn yellow. You have PLENTY of time to slow down and stop at a red light. If you weren’t so worried about trying to get through that intersection before the light clicks red. Honestly, you aren’t getting anywhere any faster when everyone is doing it.

    It’s so bad in my city that 2 cars make it through a green light, 5 cars through the yellow light, and usually at least one through the red light.

    So, if you claim to be smart (which I would expect on a website like Hack-a-day), I don’t want to hear the excuses. You know better. If people drove responsibly, there wouldn’t have been a need for these cameras in the first place (even if the goal is to make money — there would be no money to be made.)

    1. And if people drove more reponsibly in general and more curteous to other drivers, we would ALL get to where we are going quicker without the need to find tricks to cheat the systems.

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.