R/C Tech Forums

R/C Tech Forums (https://www.rctech.net/forum/)
-   Radio and Electronics (https://www.rctech.net/forum/radio-electronics-137/)
-   -   Raspberry Pi (https://www.rctech.net/forum/radio-electronics/805913-raspberry-pi.html)

StHanley 04-08-2014 06:52 PM

Raspberry Pi
 
Hi All, Im trying to think of a practical application in RC for a Raspberry Pi. I was thinking of some sort of transponder/decoder combo. Im not a coder but want to give it a shot with either Python or even scratch.

I like the idea of "easy lap timer" software (google it) but don't want to use a cam. Any ideas?

mikeygar 04-09-2014 08:51 AM

the Raspi can easily be setup with an infrared receiver. If you can make some sort of infrared transmitter that emits a unique signal and get them to talk every time the 'line' is crossed then that's the solution.

Subscribing to this thread...

ffejrxx 04-09-2014 12:07 PM

the pi has a connectors for camera too
which could be used to make some awesome videos

camera $25
http://www.newark.com/raspberry-pi/r...rry/dp/08X2023

vid instructions
http://www.raspberrypi-spy.co.uk/201...camera-module/

StHanley 04-09-2014 12:37 PM

@ mikeygar - Hmmm..... I did see a project that made a Pi into a remote control too. We'll have to think about this a bit.

StHanley 04-09-2014 12:42 PM

@ffejrxx - Great idea as well. Maybe incorporate some sensor data. Speed, temps if possible on an HUD?

mikeygar 04-09-2014 08:27 PM


Originally Posted by StHanley (Post 13171393)
@ mikeygar - Hmmm..... I did see a project that made a Pi into a remote control too. We'll have to think about this a bit.

Yes, if you research how to use an apple remote with a raspi, you will find that it is easy to get an IR receiver working with it. I use raspbmc on mine with an old apple remote and it works fine.

I guess the easiest way to get it done is to run Raspbian as the OS since it's pretty user friendly and start from there.

Just a thought - if you can come up with the circuitry for an IR transmitter, you can copy the signal transmitted by your TV remote, say #'s 1 to 0 and assign those to transponders 1-10. That way, at least you can test the lap counter software using your tv remote without having to have actual transponders running.

Once that's done, then work can be done on making the IR transmitters since you've established preset codes already.

Also, some sort of pre-registration of the allowed transponders should be in the software in case someone points a TV remote at your timer and comes out as 'unknown' in the lap timing results.

ffejrxx 04-09-2014 08:55 PM


Originally Posted by StHanley (Post 13171410)
@ffejrxx - Great idea as well. Maybe incorporate some sensor data. Speed, temps if possible on an HUD?

showing a throttle/steer position would be a great add if its possible to take a pwm input

maybe a gps location/speed/altitude would be a fun add too

StHanley 04-10-2014 07:08 AM


Originally Posted by mikeygar (Post 13172601)
Yes, if you research how to use an apple remote with a raspi, you will find that it is easy to get an IR receiver working with it. I use raspbmc on mine with an old apple remote and it works fine.

I guess the easiest way to get it done is to run Raspbian as the OS since it's pretty user friendly and start from there.

Just a thought - if you can come up with the circuitry for an IR transmitter, you can copy the signal transmitted by your TV remote, say #'s 1 to 0 and assign those to transponders 1-10. That way, at least you can test the lap counter software using your tv remote without having to have actual transponders running.

Once that's done, then work can be done on making the IR transmitters since you've established preset codes already.

Also, some sort of pre-registration of the allowed transponders should be in the software in case someone points a TV remote at your timer and comes out as 'unknown' in the lap timing results.

Ill look up the tv remote and draw up a schematic. Anybody code Python? Not sure if scratch has the hardware capability needed.

Pre reg would be a requirement. Im wondering if we can trigger a checkpoint pass in another way other than IR. Im thinking a magnet or something, then retransmit the time back to RPI using WiFi or ir.

I wonder if any work has been done with RFID tags on the Pi.

StHanley 04-10-2014 07:10 AM


Originally Posted by ffejrxx (Post 13172655)
showing a throttle/steer position would be a great add if its possible to take a pwm input

maybe a gps location/speed/altitude would be a fun add too

Ive been thinking about speed and a way to calculate it. GPS may be expensive. I think one of the requirement would be to keep it relatively inexpensive.

mikeygar 04-10-2014 08:52 AM


Originally Posted by StHanley (Post 13173419)
Ill look up the tv remote and draw up a schematic. Anybody code Python? Not sure if scratch has the hardware capability needed.

Pre reg would be a requirement. Im wondering if we can trigger a checkpoint pass in another way other than IR. Im thinking a magnet or something, then retransmit the time back to RPI using WiFi or ir.

I wonder if any work has been done with RFID tags on the Pi.

Not sure about scratch but the raspi has a built in IR library and there is a debug command you can use to parse the IR codes received by the IR receiver. Though you are correct, the GPIO pins of the raspberry can be configured to receive/transmit almost any type of signal, it would require making a decoder loop would require another breakout box connected to the raspi.

Check out TimR by DCD designs, one of the more popular lap timing devices out nowadays. They run on IR and have their own proprietary IR transponders for lap timing. The receiver box can be placed anywhere on the track, which is self powered and connects to a PC or mac via bluetooth. I've seen the pro on-road drivers use it during practice and it works really well.

mikeygar 04-10-2014 08:55 AM

Another option would be motion detection using a sensor. Good if you're the only one running on the track though but another easy way of hooking up something to the GPIO ports.

https://www.modmypi.com/blog/raspber...tion-detection

StHanley 04-11-2014 05:16 AM


Originally Posted by mikeygar (Post 13173697)
Not sure about scratch but the raspi has a built in IR library and there is a debug command you can use to parse the IR codes received by the IR receiver. Though you are correct, the GPIO pins of the raspberry can be configured to receive/transmit almost any type of signal, it would require making a decoder loop would require another breakout box connected to the raspi.

Check out TimR by DCD designs, one of the more popular lap timing devices out nowadays. They run on IR and have their own proprietary IR transponders for lap timing. The receiver box can be placed anywhere on the track, which is self powered and connects to a PC or mac via bluetooth. I've seen the pro on-road drivers use it during practice and it works really well.

Ive seen that one. I guess I want to see it working to understand how it works. I think there are so many options with this. I was thinking about putting the Pi in the RC. if we need to add a bird that would be OK although the weight would add up. We could add another pi externally as stage 2 to maybe track multiple cars. I'm still trying to think of how we can register a lap pass. So far we have iR, Possibly a magnet, and maybe RFID if its possible.

One of the other thing I was thinking about is the capabilities to also control the server and speed control are definitely there. That would be another stage.

There are also all sorts of sensors you can add to these things for temp, rpm, speed, and gps, camera if cheep enough.

I need to put them in order of priority. Pi announces another mini board the other day too. From what I understand it may expand the io capabilities. Lets see what happens with that when its released. Until then, Im going to work on what I see is out there. Your thoughts?

StHanley 04-11-2014 05:24 AM

Hmmmmmmm..... Sounds like how a mouse works.

StHanley 04-11-2014 05:25 AM


Originally Posted by ffejrxx (Post 13172655)
showing a throttle/steer position would be a great add if its possible to take a pwm input

maybe a gps location/speed/altitude would be a fun add too

This may be possible if the Pi Controlled the steering and throttle. Keep the ideas coming.

mikeygar 04-11-2014 08:05 AM


Originally Posted by StHanley (Post 13175927)
Ive seen that one. I guess I want to see it working to understand how it works. I think there are so many options with this. I was thinking about putting the Pi in the RC. if we need to add a bird that would be OK although the weight would add up. We could add another pi externally as stage 2 to maybe track multiple cars. I'm still trying to think of how we can register a lap pass. So far we have iR, Possibly a magnet, and maybe RFID if its possible.

One of the other thing I was thinking about is the capabilities to also control the server and speed control are definitely there. That would be another stage.

There are also all sorts of sensors you can add to these things for temp, rpm, speed, and gps, camera if cheep enough.

I need to put them in order of priority. Pi announces another mini board the other day too. From what I understand it may expand the io capabilities. Lets see what happens with that when its released. Until then, Im going to work on what I see is out there. Your thoughts?

Definitely, the raspi can be installed in an RC and powered through the receiver, but for anything smaller than 1/8th scale, it would alter the balance of the car too much. Controlling and programming the ESC can be done for ESCs that allow on-the-fly programming such as the new Sanwa ESC, but then questions on how to send commands in a user friendly manner come into play.

Controlling the servo and ESC are achievable, since signalling is PWM which the GPIO supports but if you have a modern era 2.4 controller, why would you want to do that, unless you want to make a car that runs a pre-programmed route which is repeatable.

There are many breakout boards that can be connected to the pi, all doing different things, but doing so would require a few different boxes connected to an already large size for even an 1/8th scale car. I guess in order of priority, if telemetry is important, then the breakout boxes handle the different sensors, a micro wifi adapter on the pi handles transmission and a base computer receives and compiles the data into a readable format. The resolution of the results may be an issue since am not sure if it can handle polling 3 or 4 different sensors in half or fifth of a second intervals and transmit it almost instantly. 1 second polling might not cut it unless your track is really huge and a rough graph is acceptable.

If it can be done, do note that if running wifi, it will have to be 5ghz since most, if not all modern radios run on 2.4 ghz. That might be a bit of a problem for the pi since the wifi adapters I see almost all run on b/g/n which is 2.4ghz. So this may cause interference with the radio control.

If magnet will be used for lap timing, then you can only time 1 car at a time since multiple magnets on different cars will all read the same. RFID is possible, but you would need to create a decoder loop which will require additional hardware. If cost is a concern, IR is the way to go. I got my IR receiver for less than $2. No additional hardware needed as i plugged it into a ribbon cable I had which was connected to the pi. But IR is only 1 way and even if IR can register a 'pass' on the line, I don't think that it can handle multiple data transmission in such short a time, though it can be done but it takes more time to transmit the data than the time it takes to make a pass.

I think you have to limit the scope of your project, define your requirements and set your parameters. It's a good idea, but at least for me, aside from a creative challenge, has the potential to become too complicated by wanting it to do too many things.

If you want to control a car, check out this kit: http://pi-cars.com. Has all the stuff you need, and instructional on programming it as well :-)


All times are GMT -7. It is currently 10:00 AM.

Powered By: vBulletin v3.9.3.9 Patch Level 3
Copyright © 2026 MH Sub I, LLC dba Internet Brands. All rights reserved. Use of this site indicates your consent to the Terms of Use.