dennisfisch
Posts: 5
Joined: Thu Sep 15, 2011 11:23 am

Re: Car / Motorcycle - Monitoring and Statistics

Sun Sep 18, 2011 11:47 am

Hey there,
I'm really excited about this and just cannot wait for the device to arrive. I plan to install this into my car as well as my motorcycle as a monitoring gadget.

I do have a mobile mount in the car and will get a (waterproof) one for the cycle as well and will be using my android phone as a vnc client to control the r-pi. I am not entirely certain of this yet, a terminal might actually work, too and would be much leaner on the PIs limited hardware.

I am also thinking of disassembling a very cheap mouse to strip it down to the PCB and use the left/right buttons as switches. The advantage of this over custom switches is that there's no extra driver nessecary to connect it to the pi, jut hook it up to the USB port and things should work and make for very easy to use user-interface. Should also help avoid police tickets because here it is illegal to handle a mobile in any way while on the road (except for voice commands, which i really dislike and which wouldn't work in a noisy environment anyway).

As for the PI itself, it would be connected to a flow meter, put into the fuel line (for the motorcycle) or to a fuel injector, which kinda raises a few questions.

1) Is there an ADC or will i need to use an external controller (AVR Atmega32, 8 bit Microcontroller, got some experience here)
2) Can any of the GPIOs trigger an interrupt and will there be a kernel interface for this?
3) I believe the current sitation is that the r-pi should be available from Nov/Dec, is this still up to date?
4) Will the R-PI support suspend/resume (for power-saving as it would be connteced to the vehicles battery), going to sleep while ignition is off and resume quickly when it is turned on. Otherwise, leaving it running and entering some kind of sleep mode would be nice if it were possible.

I have until now only played with a few AVR Atmel 8 Bit microcontrollers, but i have 2 recent degrees in computer science and just thinking of the possibilities this device opens up is mouth watering... The R-PI could be hooked up to the radio in the car as an external source and would enable me to have access to a much larger music library than otherwise possible. The device would also be able to access the internet through the USB tethering, i might even be able to track the GPS location using the phone (custom app which makes it available over a tcp connection).

Just writing about it makes me come up with so many additional ideas, can't wait to start tinkering :) Love the community here, btw, and i second the call for a library of cheap and compatible add-ons, such as gps/wifi/bluetooth/screens and touch-panels. Tutorials and how-to's will be very important once devices become available.

Any chance to have java on the PI? In more recent times, this has been the language of choice in many computer science courses and having it would enable more people to work with the device.

Anyway, I'll have to start making some plans as for what features I'm aiming for :) I'm looking forward to any news on the project and am following your progress very closely!

Happy tinkering,
Dennis

Ben_P
Posts: 16
Joined: Sat Sep 10, 2011 5:10 pm

Re: Car / Motorcycle - Monitoring and Statistics

Sun Sep 18, 2011 12:42 pm

Hi

This sounds like a really cool project. It may be worth having a read round some other threads. The breakout board and PLC threads may be particularly relevant.

Quote from dennisfisch on September 18, 2011, 12:47

I am also thinking of disassembling a very cheap mouse to strip it down to the PCB and use the left/right buttons as switches. The advantage of this over custom switches is that there's no extra driver nessecary to connect it to the pi, jut hook it up to the USB port and things should work and make for very easy to use user-interface.


I like this idea but worth thinking that even the cheapest mice have 5 buttons nowadays. You have the standard lerft/right click buttons. The middle button is usually mounted under the mouse scroll wheel. the scroll wheel itself is actually just 2 jog switches so you could have a very useful up/down/left/right and middle.


As for the PI itself, it would be connected to a flow meter, put into the fuel line (for the motorcycle) or to a fuel injector, which kinda raises a few questions.

1) Is there an ADC or will i need to use an external controller (AVR Atmega32, 8 bit Microcontroller, got some experience here)


The R-Pi does not have any ADC capabilities. Not even for sampling sound. however the ATMega32 might be a bit fat for your purposes maybe have a look for some i2c/SPI ADC. If you want a MCU then it is also worth considering a PIC as they generally draw less power (also less processing grunt)


2) Can any of the GPIOs trigger an interrupt and will there be a kernel interface for this?


I beleive that all 16 GPIOs can give a edge triggerd interupt. Can someone who knos confirm

3) I believe the current sitation is that the r-pi should be available from Nov/Dec, is this still up to date?
Latest date is end of November.

4) Will the R-PI support suspend/resume (for power-saving as it would be connected to the vehicles battery), going to sleep while ignition is off and resume quickly when it is turned on. Otherwise, leaving it running and entering some kind of sleep mode would be nice if it were possible.

While the engine is running the 1W (max) power drain should be pretty insignificant. Rather than suspend/resume or sleep (which I have not heard of the R-Pi being able to do), you might be better off having the device shut down or suspend to thhe SD card, then you will have no power draw. bot times are pretty low, and the device will take time to come out of sleep.

Any chance to have java on the PI? In more recent times, this has been the language of choice in many computer science courses and having it would enable more people to work with the device.

There are some licensing issues with Java (the Oracle JRE for ARM is miles ahead of th OSS implementations). Why would you want to use Java anyway? If you want fast development then python is really good and I think this will become the scripting language of the R-Pi. If you want fast efficient code then C or (C++ if OOP is needed). As you can tell I am not a Java fan but there are other languages that can do pretty much anything Java can do and will be there out the box on the R-Pi.

dennisfisch
Posts: 5
Joined: Thu Sep 15, 2011 11:23 am

Re: Car / Motorcycle - Monitoring and Statistics

Sun Sep 18, 2011 12:54 pm

Thanks for this very informative response! I was thinking of the ATMega32 because i have a few lying around doing nothing atm. They don't really cost me anything, about 2-3 euros at most, and i have soldered my own dev boards so they seemed to be the best choice, although I'm certain there are cheaper pin-compatible alternatives ;) The thing about the interrupt really interests me, would make things simpler. As for power consumption, that really only matters when the vehicle is not running obviosly ;)

I like Java because it has come a long way, makes for very clean code (just my opinion). Though, it seems C++ will be the way to go, no problem at all, i just never really liked the syntax of it, personally, though it may be I just never had a good IDE (of which there is no shortage for Java :D).

I have no experience with other embedded systems other than the AVR ATMega series and I'm not usually all that keen to get down to the bare metal development. The ATMegas let me develop in C without a whole lot of architecture specific clutter. It seemed that when i looked at Microchip devices the code was very difficult to follow because you had to know all these acronyms for registers or nothing would make any sense. It seems easier with ATMegas for me for some reason.

This is just personal preference, though, to each his own and all that ;) I'm really looking forward to this, can't wait!

jacklang
Posts: 166
Joined: Thu Aug 04, 2011 10:59 am

Re: Car / Motorcycle - Monitoring and Statistics

Sun Sep 18, 2011 1:00 pm

Each GPIO can interrupt, high/low/rise/fall/change

dennisfisch
Posts: 5
Joined: Thu Sep 15, 2011 11:23 am

Re: Car / Motorcycle - Monitoring and Statistics

Sun Sep 18, 2011 1:22 pm

Thank you very much for this information! I have been looking for displays and i believe the fact that the PI will have a composite out is a blessing... There are several 3.5/4.3 inch displays on ebay sold as rearview monitors, which should work just fine with a composite signal. At around 20 euros including shipping, it seems like a good match for the PI.

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 23918
Joined: Sat Jul 30, 2011 7:41 pm

Re: Car / Motorcycle - Monitoring and Statistics

Sun Sep 18, 2011 7:18 pm

Quote from dennisfisch on September 18, 2011, 14:22
Thank you very much for this information! I have been looking for displays and i believe the fact that the PI will have a composite out is a blessing... There are several 3.5/4.3 inch displays on ebay sold as rearview monitors, which should work just fine with a composite signal. At around 20 euros including shipping, it seems like a good match for the PI.

That's interesting - I have a rear camera in my motorhome (RV for those on the other side of the pond) - Raspi might well plug in to that.....
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
“I think it’s wrong that only one company makes the game Monopoly.” – Steven Wright

Blars
Posts: 88
Joined: Sun Aug 28, 2011 3:22 am
Contact: Website

Re: Car / Motorcycle - Monitoring and Statistics

Mon Sep 19, 2011 8:49 am

The rear veiw camera monitors tend to have low resolution, don't expect to get much information on the screen at a time with them.

dennisfisch
Posts: 5
Joined: Thu Sep 15, 2011 11:23 am

Re: Car / Motorcycle - Monitoring and Statistics

Mon Sep 19, 2011 9:20 am

I dont need much more than a table of metrics, might possibly draw a chart, but nothing more. Not about to watch TV while driving :)

If i can't fit it all on one screen I'll just use buttons to switch between different views.

User avatar
glenn66
Posts: 55
Joined: Fri Nov 25, 2011 4:06 pm
Location: Belfast
Contact: Website

Re: Car / Motorcycle - Monitoring and Statistics

Mon Nov 28, 2011 10:39 pm

I've been looking at something similar for a 1988 Toyota sports car. This is way before OBD II came along so I'm going to use a PIC (probably a 16F690) running at 20MHz to monitor 8 engine parameters directly from the sensors and then relay this to an RPI via RS232 (probably over USB) mounted in the dash with a 7" monitor in place of the radio. I also have a 7" touch panel I got cheap and I'm excited about the RPI having a video out so that I don't need to convert VGA to video.

Some of my preliminary tinkerings are here (and there)

http://rgwni.blogspot.com

User avatar
glenn66
Posts: 55
Joined: Fri Nov 25, 2011 4:06 pm
Location: Belfast
Contact: Website

Re: Car / Motorcycle - Monitoring and Statistics

Tue Nov 29, 2011 11:32 pm

Quote from dennisfisch on September 19, 2011, 10:20
I dont need much more than a table of metrics, might possibly draw a chart, but nothing more. Not about to watch TV while driving :)

If i can't fit it all on one screen I'll just use buttons to switch between different views.

Something along these lines? Maybe we could help each other out once the RPi is available?

http://rgwni.blogspot.com/2010.....puter.html

http://rgwni.blogspot.com/2010.....stics.html

Maxim
Posts: 3
Joined: Wed Nov 30, 2011 8:41 am

Re: Car / Motorcycle - Monitoring and Statistics

Wed Nov 30, 2011 8:54 am

I'm planing to use Pi for media storage on my Suzuki V-Strom 650, I'm filming alot during my trips. Using laptop for that purpose consume alot of space, that not alot on bike to begin with :(

My plan is:
- Use one of "rearview" TV for info displaing, such as this: http://www.dealextreme.com/p/3.....-15v-49796
- Use foldable kayboard for working with Pi
- Use SSD to store media content
- Add separate battery and solar pannel to power up all this
- Use PI as power controller (charging PI batter only if solar is not active and bike generator is runing)
- Use PI for basic monitoring and as "blackbox" device (Speed, GPS, Navigation)
- Use of Pi batter as charger to my cell phone and video/photo cameras
- Use of Pi batter as a backup for bike battery (I'm don't have a kickstarter, so if my battery will drain in the middle of nowhere, I'm screw :( )

cmduarte
Posts: 10
Joined: Sat Sep 10, 2011 6:36 pm

Re: Car / Motorcycle - Monitoring and Statistics

Fri Jan 13, 2012 8:12 pm

Although designed for Android, The IOIO (pronounced yoyo) should be adaptable, is very low power, has a/d, pwm, SPI, Ic2, and more.  It's spendy at $50 US, but Oh what it can do for real-word access!

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 23918
Joined: Sat Jul 30, 2011 7:41 pm

Re: Car / Motorcycle - Monitoring and Statistics

Fri Jan 13, 2012 8:52 pm

cmduarte said:


Although designed for Android, The IOIO (pronounced yoyo) should be adaptable, is very low power, has a/d, pwm, SPI, Ic2, and more.  It's spendy at $50 US, but Oh what it can do for real-word access!


Well,  you already have SPI and i2c on the Raspi, and the addition of a Gertboard would also help with some of the other requirements.
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
“I think it’s wrong that only one company makes the game Monopoly.” – Steven Wright

User avatar
scep
Posts: 1062
Joined: Sun Nov 20, 2011 8:53 am

Re: Car / Motorcycle - Monitoring and Statistics

Fri Jan 13, 2012 10:19 pm

Max.L said:


I"m planing to use Pi for media storage on my Suzuki V-Strom 650


Hi Max - I've got a 650 Strom too - nice to meet you .

User avatar
n3tw0rk5
Posts: 216
Joined: Fri Jan 06, 2012 6:04 pm

Re: Car / Motorcycle - Monitoring and Statistics

Fri Jan 13, 2012 11:28 pm

Nice to see there's fellow bikers on here, cant really think of a use to have one on me bike apart from maybe a temperature logger.

Then one of these days i might remember to get round to sorting out a car licence instead of freezing each winter.

bulldog
Posts: 2
Joined: Wed Jan 11, 2012 1:01 pm

Re: Car / Motorcycle - Monitoring and Statistics

Sat Jan 14, 2012 10:08 pm

I am planning on putting one into my RX8. The car has a flip up sat nav that I can fit a 7" screen into. I am thinking about getting a touch screen and building this into the oem satnav hood. I can connect a wireless bluetooth dongle to the obdII port to get information from the car. I would also like to add some other gauges to the engine to monitor oil/water temps.

I plan on using a DC-DC power supply wired into the ignition circuit.

Wooloomooloo
Posts: 92
Joined: Fri Nov 25, 2011 10:52 am

Re: Car / Motorcycle - Monitoring and Statistics

Sat Jan 14, 2012 10:35 pm

n3tw0rk5 said:


Nice to see there's fellow bikers on here, cant really think of a use to have one on me bike apart from maybe a temperature logger.

Then one of these days i might remember to get round to sorting out a car licence instead of freezing each winter.


bikers++

Also, careful: cars are treacherous! Since I got mine... well... I use it so much I have remorse facing the bike.

sbf
Posts: 1
Joined: Thu Feb 02, 2012 6:37 pm

Re: Car / Motorcycle - Monitoring and Statistics

Thu Feb 02, 2012 8:00 pm

I am also planning to build something for my car and, coincidentally, I have an RX-8.

For several months I have been reverse engineering the ecu rom image in IDA Pro. Beyond the standard OBDII mode 1 PIDs, of which the RX-8 supports 37, there are 71 additional PIDs supported on mode 22.

Also added on to the ten OBDII modes are twenty-two diagnostic modes which, while generally conforming to ISO15765, are mostly totally undocumented. This article has a list: Service(s) Please

I feel that manufacturers ought to publish documentation on this stuff because in some cases this information is required to properly service a vehicle. I believe that they keep it quiet so that owners are required to support their dealerships service department on occasion.

In effect, it is unsavory rent-seeking behavior.

I'm hoping that Raspberry Pi will be a good platform to make tools that will allow owners and independent mechanics to combat this practice.

Return to “Other projects”