rasberry pi integration

For discussion of Phil Tobin's Tuner Studio software (Only about the tuning software itself, not about how to tune or firmware features)

Moderator: LT401Vette

Re: rasberry pi integration

Postby UnaClocker » Tue May 29, 2012 9:41 pm

http://youtu.be/KcLYkFeIlyc Video of MTx and TS running on my Pi.. Kind of a boring video, but if you wanted to see it in action..
Brian
'84 Dodge Rampage
User avatar
UnaClocker
Super MS/Extra'er
 
Posts: 1933
Joined: Fri May 07, 2004 12:59 pm
Location: Tacoma, WA

Re: rasberry pi integration

Postby retired » Wed May 30, 2012 11:53 am

OK, we have one up and running on a real MS2 (driven by a JimStim) and connected by a fairly simple serial chip and a 12V PSU (based on the MS2 design).

Loads in just under a minute on standard debian with no overclocking.

Guages are a little jerky compared to the XP install but I'm sure we can fix that.

Big thanks to Graham (Graham T) for the 100 plus emails between us to fix this and the emails between Graham and Phil for the final solution

EDIT - video tommorow, it's getting late UK time...
retired
Helpful MS/Extra'er
 
Posts: 80
Joined: Fri Feb 22, 2008 11:49 am
Location: Rural Suffolk, UK

Re: rasberry pi integration

Postby LT401Vette » Wed May 30, 2012 1:08 pm

Cool, congrats!

Attached is an ini file for the 3.1.1 Extra that is stripped down to gauge mode, there are no settings.

It does better than cut load time in half on my PC.

Normal 3.1.1 project load:
ini parsing takes 50-74ms, time to fully loaded and dash displaying is 550 - 850ms

with the stripped down ini: ini parsing takes 21-25ms, time to fully loaded and displaying dash is 168-290ms

Those times are with TS already started, just opening the projects.

So it does seem to cut it in half and the some. If you turn on lite mode it will skip loading some UI parts you don't need
Phil Tobin
EFI Analytics, helping to simplify EFI
Next Generation tuning software.
Supporting all MegaSquirt versions and firmwares.
http://www.TunerStudio.com
http://www.efiAnalytics.com/MegaLogViewer/
Support the firmware running your engine:
http://www.msextra.com/doc/donations.html
User avatar
LT401Vette
Super MS/Extra'er
 
Posts: 8274
Joined: Sat Jul 16, 2005 8:07 am
Location: Moorseville, NC

Re: rasberry pi integration

Postby racingmini_mtl » Wed May 30, 2012 2:05 pm

That's great!

I'm curious to see what frame rate you can get with this setup. So it would be good if you can have a look at what TS reports.

Jean
jbperf.com Main site . . . . . . . . . . . . . . . . . . . . . . jbperf.com Forum
Image
racingmini_mtl
Super MS/Extra'er
 
Posts: 6463
Joined: Sun May 02, 2004 6:51 am
Location: Quebec, Canada

Re: rasberry pi integration

Postby Graham T » Wed May 30, 2012 6:09 pm

I'm getting about 47 seconds now to load TunerStudio using the stripped down ini file. Thats from double click the TunerStudio.sh file to Project-ready.

from startup to project load takes about 19 seconds
Project loads in 11 seconds
Gauge cluster loads in 17 seconds

add -noSplash and time reduces to approximately 43 seconds.

load times do seem to vary on each TunerStudio start up, some times by up to 5 seconds either way.

Thats on the emulated Rpi, using the beta version of TunerStudio in lite mode, so the defalut dash is being displayed.
My emulation was only about 3 seconds different to Rods physical device (slower) using the full ini on the last stable release of TunerStudio.

lite mode seems to make about 7 seconds difference to load times.

Again, this is all on the emulator, so I'm not sure how that will differ on the physical device.

Next up is testing raspbian...
Graham T
MS/Extra Newbie
 
Posts: 14
Joined: Tue Feb 01, 2011 12:41 pm

Re: rasberry pi integration

Postby Graham T » Mon Jun 04, 2012 1:15 am

Here is a video of the Rpi loading TunerStudio.

http://youtu.be/82dTYbngWQU

Times are a little slower than my previous post.
The OS loads in approx 30 second, which I am sure can be shortened.

There is 15 seconds of me trying to start the TunerStudio script.

Once sync, the guages are fairly smooth at a frame rate of 15 frames per second. 20 was ok.
This is on the debian distro, TunerStudio v1.51

I made the dash layout as minimalistic as possible. No overlap on guages.

I tried it with less gauges, but over all you do not see much difference once the gauge cluster has loaded, though any more gauges than I have on the layout and it starts to struggle - The gauge movements become very jittery.

Using lite mode restricts me to the default dash and with all the gauges on there it really was not smooth - and took longer to load.
Also, once you have the profile set to load in full screen mode, you are pretty much stuck. try to double click to go back to normal view and TS is locking up. - I've not yet been able to recover from that with out rebuilding the OS. Even deleting the TS folder and project folder and starting from scratch with TunerStudio, it still opens in full screen...
Is there a way - key stroke? - to get out of full screen to be able to get the menus back? Or is there a file outside of the TunerStudio folders that would be setting to full screen even with a "clean" TunerStudio install?

I bought one of the "proven" class 10 SD cards off of the Rpi wiki proven peripherals list, but that will not let me run. Rpi does not even see the card, let alone getting fail on boot, so for now I am stuck with Class 6.

I'm also stuck with loading TunerStudio at startup.
You can see a failure during boot in the video, which is TunerStudio trying to start before X.
I have no idea how to load X, then run a script. Anyone?
Graham T
MS/Extra Newbie
 
Posts: 14
Joined: Tue Feb 01, 2011 12:41 pm

Re: rasberry pi integration

Postby xrattiracer » Tue Jun 05, 2012 8:33 am

if all you are going to be running is tuner studio, then you likely dont even need a window manager. just have the system launch tunerstudio by itself when X starts. various distros do this differently so I couldnt say exactly how to accomplish that, but it could save significant amounts of memory and cpu power.
I have been kinda watching this thread with interest, although I do not have a Pi yet. I have been involved with qt/qml, and have half a mind to make some kind of virtual dash application with that, if only I knew c++ better... I think performance could be improved dramatically, especially since it is easy to leverage opengl for ui acceleration.
xrattiracer
Experienced MS/Extra'er
 
Posts: 195
Joined: Fri Aug 01, 2008 2:25 pm

Re: rasberry pi integration

Postby LT401Vette » Tue Jun 05, 2012 9:19 am

especially since it is easy to leverage opengl for ui acceleration.

OpenGL is used, that is why video drivers that support it in hardware is so critical to performance.
Phil Tobin
EFI Analytics, helping to simplify EFI
Next Generation tuning software.
Supporting all MegaSquirt versions and firmwares.
http://www.TunerStudio.com
http://www.efiAnalytics.com/MegaLogViewer/
Support the firmware running your engine:
http://www.msextra.com/doc/donations.html
User avatar
LT401Vette
Super MS/Extra'er
 
Posts: 8274
Joined: Sat Jul 16, 2005 8:07 am
Location: Moorseville, NC

Re: rasberry pi integration

Postby weeblebiker » Mon Jun 18, 2012 8:46 am

my release date has moved up to July 5.
looks like they are really making headway catching up with demand.
v2.2 box, ms2, duel wheel, sequential ignition, staged injection, boost control, maf
'87 VW scirocco, 2L 16V, TD0-14T, itbs E85
weeblebiker
Experienced MS/Extra'er
 
Posts: 334
Joined: Sun May 11, 2008 4:03 pm

Re: rasberry pi integration

Postby weeblebiker » Tue Jun 19, 2012 2:34 pm

and now comes the $50 via apc raspberry pi competitor has a few more i/o's and a regular video port.

http://www.pcmag.com/article2/0,2817,2404770,00.asp
Last edited by weeblebiker on Tue Jun 19, 2012 2:50 pm, edited 1 time in total.
v2.2 box, ms2, duel wheel, sequential ignition, staged injection, boost control, maf
'87 VW scirocco, 2L 16V, TD0-14T, itbs E85
weeblebiker
Experienced MS/Extra'er
 
Posts: 334
Joined: Sun May 11, 2008 4:03 pm

Re: rasberry pi integration

Postby UnaClocker » Tue Jun 19, 2012 2:39 pm

Just like the OLPC started the Netbook fad, I suspect the Pi will do likewise for really cheap really tiny embedded style computers.
Brian
'84 Dodge Rampage
User avatar
UnaClocker
Super MS/Extra'er
 
Posts: 1933
Joined: Fri May 07, 2004 12:59 pm
Location: Tacoma, WA

Re: rasberry pi integration

Postby jsmcortina » Tue Jun 19, 2012 3:02 pm

I bet they don't have a "Model B" though. That's cool to kids of the 70s who remember the original BBC model B.

James
I can supply, repair or upgrade Megasquirts in UK.

My Success story: viewtopic.php?f=104&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
jsmcortina
Site Admin
 
Posts: 27910
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK

Re: rasberry pi integration

Postby weeblebiker » Wed Jun 20, 2012 6:21 am

jsmcortina wrote:I bet they don't have a "Model B" though. That's cool to kids of the 70s who remember the original BBC model B.

James

true dat
v2.2 box, ms2, duel wheel, sequential ignition, staged injection, boost control, maf
'87 VW scirocco, 2L 16V, TD0-14T, itbs E85
weeblebiker
Experienced MS/Extra'er
 
Posts: 334
Joined: Sun May 11, 2008 4:03 pm

Re: rasberry pi integration

Postby ashford » Wed Jun 20, 2012 7:02 am

makes me want to whip out my old ti99-4a and see if it still works
ashford
Super MS/Extra'er
 
Posts: 867
Joined: Sun Apr 27, 2008 4:29 pm

Re: rasberry pi integration

Postby meeki007 » Thu Jun 21, 2012 11:28 am

you can run openbox without desktop environment
http://openbox.org/wiki/Help:Getting_started

it will free up a ton of resorces
Puppytune - 220mb linux os packaged with tunnerstudio. yes it auto runs :)
http://forums.turbobricks.com/showthread.php?t=259983
meeki007
MS/Extra Newbie
 
Posts: 11
Joined: Thu Mar 15, 2012 4:05 pm

Re: rasberry pi integration

Postby mariob » Thu Jul 05, 2012 12:39 pm

Here is one more running Debian (soft-FPU) install. But so far i have to admit that it is not really usable as every click or dialog needs several seconds until a reaction can be noticed. I will give it another try on raspbian (with hard-FPU) in the next days.

Mario
Peugeot 106 Sergio_Tacchini, 1124cm³, MS2/Extra pre3.3alpah15, E85
Citroen AX, 954cm³, MS2/Extra pre3.3alpha15, E85
Peugeot 106 Rallye, 1298cm³ ... waiting for ITBs and full sequential injection
User avatar
mariob
Experienced MS/Extra'er
 
Posts: 189
Joined: Wed Nov 11, 2009 11:35 am
Location: Berlin, Germany

Re: rasberry pi integration

Postby retired » Fri Jul 06, 2012 4:02 am

Over here we now have two running fairly well on raspbian - Graham and I now actually have an RPi each, despite the delays in delivery and us being UK.

Both running in-car with running engines (MS2 with Jean's siamese code as we both run A series turbos so the msq's etc may not be as common as some) but everything looks good.

A few problems with the PSU and interfaces when in car (affects Graham in-car and not me, but allways OK on the JimStim) but we'll resolve that shortly.

We also have added comms load as we both use Jean's IOx (or IOx-OEM) but the gauge refresh seem as good as a cheap laptop at the moment.

Lots of work still to be done to perfect it, but a question for Phil....


We thought it would be nice to have the RPi connected all the time as a display only but still be able to plug in a laptop for tuning. I tried hooking the RPi to the Rx line only (ie, just to recieve data from the MS2) but, as I kind of expected, it won't work without the Tx line.

Presumably TS sends responses back to the MS2 data even if we are not burning new settings ??? So fails to recieve data without the two way comms ???

Any easy solution ???


Rod.
retired
Helpful MS/Extra'er
 
Posts: 80
Joined: Fri Feb 22, 2008 11:49 am
Location: Rural Suffolk, UK

Re: rasberry pi integration

Postby LT401Vette » Fri Jul 06, 2012 5:08 am

Yes the TX is needed. The firmware send the runtime data after TS sends a request for it. Also TS runs an interrogation on connect.

I don't think the IOExtender supports CAN Passthrough, or you could connect and read through that for the Pi then plug into the main controller with the tuning laptop.


Alternatively, perhaps a switch to change what has access to the serial.
Phil Tobin
EFI Analytics, helping to simplify EFI
Next Generation tuning software.
Supporting all MegaSquirt versions and firmwares.
http://www.TunerStudio.com
http://www.efiAnalytics.com/MegaLogViewer/
Support the firmware running your engine:
http://www.msextra.com/doc/donations.html
User avatar
LT401Vette
Super MS/Extra'er
 
Posts: 8274
Joined: Sat Jul 16, 2005 8:07 am
Location: Moorseville, NC

Re: rasberry pi integration

Postby retired » Fri Jul 06, 2012 5:27 am

LT401Vette wrote:Alternatively, perhaps a switch to change what has access to the serial.


Yes, that was our first thought :D

We were just trying to make the wiring easier.

But it's still looking good overall.
retired
Helpful MS/Extra'er
 
Posts: 80
Joined: Fri Feb 22, 2008 11:49 am
Location: Rural Suffolk, UK

Re: rasberry pi integration

Postby xrattiracer » Mon Jul 09, 2012 10:48 am

has anyone considered using CAN bus instead? would it be possible for tuner studio to do its thing over that?
I am working on building my own mechanical gauge dash setup, and it is very important to me to leave the serial port open for a laptop or whatever so any permanently installed electronics need to use something else.
or failing that, maybe it would be possible to do some kind of serial pass through.
xrattiracer
Experienced MS/Extra'er
 
Posts: 195
Joined: Fri Aug 01, 2008 2:25 pm

PreviousNext

Return to Tuner Studio

Who is online

Users browsing this forum: No registered users and 3 guests