SAMCO Arduino Powered IR Light Gun
-
@grant2258 The gun itself is an old PS1 Namco Gun. You'll have to find one second hand and prices vary alot. If you search Playstation Gun on eBay you should get an idea of what they're going for in your area.
-
Well I got a few Arduinos and parts lying about might be able to rustle something up unless i need the guns electronics for something. Will check it out for sure when more details are available.
-
Hi Guys, just a quick update. Build Guide is now available...
-
@samco The costs are little imho
20$ the gun
25$ the IR camera
10$ the itsybitsy
2.5$ for some hardware -
@samco congratulations on your project!
This is indeed very well executed, spot-on and seems to give a very professional result. I think everyone will appreciate the simplicity and openness of your design.Kudos!
-
@samco Thanks! That's certainly professional and straigtforward.
I have several questions, if you don't mind.
I assume any small arduino, like the nano or the micro, would work, don't they?
Also, do you think it would be possible to use a Namco Guncon 2 instead of 1? It already uses a usb cable and has extra buttons and a directional pad at the back. This would avoid the need for building the calibration button. I assume that the arduino code can be extended to add support for additional buttons (since the arduino has several input pins available) but I'm unsure whether a Guncon2 (which is smaller as has more internals for the extra hardware) would fit the arduino and the camera.
The IR camera you use can detect up to 4 IR lights. Do you think tracking could be improved by using additional leds around the screen? Or even avoiding the need for recalibration?
And, finally, I understant that the arduino is detected in Retropie as a standard mouse, so that it can work as is in all emulations that use mouse input as lightgun, is this the case? -
@janderclander14 said in SAMCO Arduino Powered IR Light Gun:
I assume any small arduino, like the nano or the micro, would work, don't they?
The micro yes ... then nano no.
You need a HID compatible device.
If I'm wrong then please correct me.And, finally, I understant that the arduino is detected in Retropie as a standard mouse, so that it can work as is in all emulations that use mouse input as lightgun, is this the case?
yes
If you consider the costs ... you are equal to a DolphinBar (and if you already have a wiimote you are cheaper)
10-15$ the Dolphin bar
25$ the Wiimote
20$ a gun "case"About the namco guns.... they are very cheap in Japan nowadays.
Take a look here -
@janderclander14 said in SAMCO Arduino Powered IR Light Gun:
@samco Thanks! That's certainly professional and straigtforward.
Thanks!
I assume any small arduino, like the nano or the micro, would work, don't they?
Yeah Like @cyperghost said any HID compatable board will work.
Also, do you think it would be possible to use a Namco Guncon 2 instead of 1? It already uses a usb cable and has extra buttons and a directional pad at the back. This would avoid the need for building the calibration button. I assume that the arduino code can be extended to add support for additional buttons (since the arduino has several input pins available) but I'm unsure whether a Guncon2 (which is smaller as has more internals for the extra hardware) would fit the arduino and the camera.
Yeah, I've already looked into this (most likely going to be my next project). You could have the mouse and keyboard libraries loaded on, so some buttons could be keyboard strokes and some some mouse buttons. A little more tricky due to how the buttons are configured but I'm hoping to work away around this. And yes the camera fits.
The IR camera you use can detect up to 4 IR lights. Do you think tracking could be improved by using additional leds around the screen? Or even avoiding the need for recalibration?
I have seen other projects that use 4 leds, but haven't looked into it to much yet. Also something I'm considering.
And, finally, I understant that the arduino is detected in Retropie as a standard mouse, so that it can work as is in all emulations that use mouse input as lightgun, is this the case?
Yes, but only a few do at this stage. No PSX yet. But I keep hearing rumours that this isn't too far off.
Cheers Sam
-
@samco Do you think you can rewrite this to circuit-python?
Then you will make full use of the M0 board. You know it has a python interpreter on board ;) -
@cyperghost I don't actually know python yet :) but from the little research I've done C++ actually runs faster than circuit-python (can anyone confirm this?). I am interested in circuit-python thou, definitely on my "to learn" list.
-
c++ will be faster depending on what your doing speed might no matter that much in the big picture.
-
@samco @grant2258 I think you're both on the wrong track. The Adafruit M0 controller has a file system enabled. So you just plug it in to any computer and it will show as a storage device. This device holds a file
main.py
where you immedialty can alter program code. So in fact you don't need an IDE ... just copy and paste code to that storage device and you are fine.
Speed does not matter in this case (imho) the camera does most of the work and the calculations done by C code or python is not really difficult.
Maybe I'm wrong .... but with the M0 you can even play wave-files ;) I think it is a feature that isn't usefull on a light-gun system (ironic!) -
@samco I was told from another site that the author of this related project:
https://retropie.org.uk/forum/topic/22531/xwiigun-a-line-of-sight-accurate-wii-remote-lightgun-hack
may be willing to offer his automatic calibration code to be integrated into your project. I've personaly tested it and self-calibration and tracking is excellent, but support for mouse emulation in Retroarch emulators is quite limited. He should have posted into your git's issues.
-
@janderclander14 Yeah, he messaged me in GitHub. Thanks for linking us up!
-
Hey Guys, not exactly RetroPie related (unless PSX Beetle & Beetle Saturn works with the new RPI 4 fingers crossed) but if your interested I have a setup guide for the SAMCO working on PSX Beetle & Beetle Saturn on RetroArch in Windows.
By the way, if any does know if PSX/Saturn Beetle works on the new RPI 4, I'd love to know?
-
Hi Guys,
Just another quick vid showing the SAMCO Light Gun in action...
-
@samco I've everything in place so I might rebuild your project ;)
But don't expect something in the next few weeks.
Thank you for sharing -
@cyperghost Nice! let me know how ya go :)
-
Hi Guys, this is just a quick update to let you know I've added a new sketch to the GitHub for anyone who wants to add a foot pedal to their Samco. It's really simple just grab any momentary foot switch (I used one that was for a tattoo gun there's heap of these on eBay) and solder it to the broken out Alt pins on the PCB (I knew I broken out an extra pin for a reason :) ). Basically all it does is gives you an extra right mouse button but it's great for dual gun mode in Time Crisis II on PCSX2 and it's just cool to have a foot switch. Attached an image so you can see how it all fits.
Also updated the old code slightly so it releases the mouse in pause mode so you can use your normal mouse again when your Samco's paused.
Cheers.
-
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.