ninja master of coffee Posted January 11, 2018 Author Report Share Posted January 11, 2018 And I have now apparently written a program that tells the output LED to blink KABOOM in morse code. I shall check it again tomorrow when I'm less tired. Link to post Share on other sites
ninja master of coffee Posted January 12, 2018 Author Report Share Posted January 12, 2018 A couple of extra thoughts. The problem with IR lasers is that they're dangerous to people's eyes (you don't blink if they're shone in your eye, but they can burn retinas). So, I could either use a visible laser, or use an IR LED, though that could limit the range quite a bit. Link to post Share on other sites
ninja master of coffee Posted January 12, 2018 Author Report Share Posted January 12, 2018 Having had a bit of an internet wander, the best solution seems to be to use an IR LED and a focusing lense, very similar to one of those fancy modern LED torches that can throw a beam a couple of hundred feet or more, depending on the lumens of the LED. Apparently ranges of to 400 feet can be achieved like this, so I'm not too worried about range. There's a build guide for a laser tag gun using Arduino on instructables which includes coding, this won't be a straight up copy as it doesn't need a lot of the functions the laser tag system does, additionally transmitter and receiver functions will be split between two arduinos. Something else I have figured out is that putting either a time delay, or a given time the receiver has to be painted for, is pretty easy to code, so that's handy. All in all this is looking very doable. Luckily I also have a cousin who is a computer programmer so I can check any of my idiot noob programmer questions with him, as well as anyone here who has more experience with this stuff. Link to post Share on other sites
Tw1tch Posted January 12, 2018 Report Share Posted January 12, 2018 Definitely have it coded to only respond after a lock is achieved for 5 seconds or so. Link to post Share on other sites
Mike 8-{> Posted January 13, 2018 Report Share Posted January 13, 2018 Ardunio are the ideal tool for this.Found this project which does a lot of what you are looking for and could easily be adapted :- http://www.instructables.com/id/Duino-Tagger/ It would be very simple I think to have the laser designator just use a red (or other colour) laser and modulate the light beam with a signal in such a way that, as far as the operator is concerned, the laser appears to be "always on" (using fast enough pulses you wont see/ perceive them). So no need for nasty IR or puny IR leds. The receiver unit then just sits there waiting for the specific modulated signal to hit it. It can be coded to only be triggered when it has received the correct signal for a specific number of cycles or period of time. For example: the designator unit sends "make target go boom now" in morse repeatedly (you would use some kind of binary / ascii in reality), The receiver waits until it gets hit with a laser and then listens for "make target go boom now" and either then starts a countdown timer or counts the times it receives the message. If the signal / transmission is interrupted and not restarted within a specified duration then the receiver could reset back to zero. If the number of repetitions is achieved or the timer counts down without interruption the alarm/game event/signal is triggered. The code in the example above effectively does both the send and receive in the one bit of code as the laser tag pistol is both shooter and hit detector.. You could easily split out the code so that you use the transmit section for the laser designator and the receive code for the target.The other things to look at would be the code for RF data links. There is code to run RF 433Mhz data links for things like garage openers and remote controls. The same code could easily be adapted to use a modulated laser as the sender and a suitable detector as a receiver. Essentially you are trying to make a laser point to point data link. Check out your local area and see if there is a hackspace or makespace anywhere near you. If there is they will be able to help with the code and electronics. I'll have a word with the guys at my local hackspace on Monday and see if we can come up with any ideas/suggestions I think it is eminently doable. Almost certainly using Arduino Nanos which you can pick up for less than £2 from china. Link to post Share on other sites
ninja master of coffee Posted January 13, 2018 Author Report Share Posted January 13, 2018 Yeah, that's the same project I found. Using parts of the code is definitely the plan as it does what I want it do anyway. As you say, just separate the transmitter and receiver parts of the code between two arduinos for the two parts. I'm going to read up on lasers and LEDs, bright IR LEDs with a focusing lens apparently have a pretty good range, part of the reason I want to use IR is that it's invisible to the human eye, but another reason is because it's pretty straightforward to filter out other wavelengths and reduce noise with a bit of IR transparent filter plastic (easily obtainable online). Good idea on makers spaces, I'll ask around, could be a bit tricky as I live in Spain and my Spanish is... Not amazing. Link to post Share on other sites
ninja master of coffee Posted January 13, 2018 Author Report Share Posted January 13, 2018 Additional info and why I'm erring on the side of an IR LED with a lens to focus. http://www.lasertagparts.com/mtoptics.htm Link to post Share on other sites
ninja master of coffee Posted January 21, 2018 Author Report Share Posted January 21, 2018 Sorry for going quiet for a bit, been ill and busy. I've ordered an arduino UNO clone and starter kit (breadboard and whatnot) so I should be able to actually start testing stuff out in a couple of weeks time when it arrives. I will have to order a second UNO when I've worked stuff out for the sensor unit but that can wait for now. Link to post Share on other sites
ninja master of coffee Posted February 3, 2018 Author Report Share Posted February 3, 2018 The Arduino and breadboard have turned up. I will start actually working out and testing stuff next weekend. I have also discovered that there's an electrical components shop close to where I live. Link to post Share on other sites
Cannonfodder80 Posted February 4, 2018 Report Share Posted February 4, 2018 Definitely have it coded to only respond after a lock is achieved for 5 seconds or so. This. Having to keep the target "painted" would simulate the delay of the time it's it would take ordnance to arrive Link to post Share on other sites
ninja master of coffee Posted February 5, 2018 Author Report Share Posted February 5, 2018 For sure. I will start work on programming it this coming weekend, too busy in the week to do anything meaningful. Link to post Share on other sites
ninja master of coffee Posted February 10, 2018 Author Report Share Posted February 10, 2018 Progress report... sort of. My computer doesn't seem to want to recognise the arduino uno in devices, I'm running windows 10. Most frustrating. Link to post Share on other sites
ninja master of coffee Posted February 10, 2018 Author Report Share Posted February 10, 2018 That seems to be sorted out, I suspect being a cheap chinese clone UNO resulted in the device name not appearing as arduino UNO or anything particularly useful. Arduino has now been updated and I've been playing with a few test programs, including the KABOOM program using the onboard LED. Next week I will see about making some external stuff and adding in a switch on/off section to the KABOOM program as currently it just runs constantly when plugged in. Link to post Share on other sites
sandstorm Posted February 10, 2018 Report Share Posted February 10, 2018 Arduino programs will always run in constant loop as logn as there's pwoer. But listening to a switch and 'arming' it, then having different signal to 'boom' it is trivial as long as you don't think too comlicated. Link to post Share on other sites
ninja master of coffee Posted February 10, 2018 Author Report Share Posted February 10, 2018 Yeah, I watched a guide on how to write in switch functionality, it didn't seem particularly difficult. Link to post Share on other sites
ninja master of coffee Posted February 11, 2018 Author Report Share Posted February 11, 2018 Things to do in the coming week. Check out local electronics shop. See if they do high power IR LEDs. A focusing lens would also be great though that might have to be an AliExpress job. Also see what enclosures/project boxes they do. I've worked out the approximate size, the tricky thing will be getting one that's also durable and weatherproof since it's going to be used outside. Link to post Share on other sites
ninja master of coffee Posted March 4, 2018 Author Report Share Posted March 4, 2018 First up, sorry about the delay in actually doing anything, a combination of business and laziness has slowed things down, plus, dyslexia and coding don't exactly mix well. I finally got around to hooking up some components to the arduino to test a few functions. I've figured out how to get an LED to turn on and off with a push switch (sounds really basic and it is, but it's also very necessary.) What I need to do is figure out how to integrate the debounced switch sketch with the LED pulse sketch. Being a novice at this means it's not immeadiately obvious how that would actually work so I need to do a bit more reading. In layman's terms, I can get an LED to turn on and off with the press of a switch, and I can get an LED to blink a particular pattern, but I can't get a switch to control the LED blinking a pattern. Oh, I also have an IR LED, IR photodiode, and various resistors and a couple of switches. Yet to play with the IR LED or photodiode as I need to figure out some other stuff first before that's useful. I do now know how to set up a voltage divider, which will be necessary for running the photodiode as a sensor so that it can trigger an LED/alarm/MP3/Pyrotechnic maroon... Link to post Share on other sites
Recommended Posts
Archived
This topic is now archived and is closed to further replies.