Page 1 of 3

Raspberry Pi and MegaTunix

Posted: Tue May 15, 2012 7:07 pm
by UnaClocker
It works. I compiled MegaTunix last night on the standard Debian install (not the Raspbian that's still in development). For those that have been living in a box, the Raspberry Pi is a $35 Linux computer, has a 700MHz ARMv6 CPU with 256mb ram. Probably the slowest Linux experience I've ever had, but for $35, what do you expect? Anyways.. MegaTunix compiles fine, both my Prolific and the MS3's FTDI USB-serial adapters work perfectly. I only have an MS3, so I wasn't able to actually use MegaTunix beyond the offline mode, but it works.
Image
And no, you cannot run TunerStudio on this thing, TS needs Java, Oracle hasn't released a JVM for this CPU, and being an out of date CPU, I don't see why they ever will.

This combo should make for an awesome embedded dashboard. Get a small 7 or 8" LCD hooked to the Raspberry Pi, strip down MegaTunix so it's just a dashboard, and add MS3 support, and I could totally see replacing the dash in my car with this thing, probably for under $100.

Re: Raspberry Pi and MegaTunix

Posted: Tue May 15, 2012 8:08 pm
by racingmini_mtl
Interesting but have you seen this: http://www.msextra.com/forums/viewtopic ... 22&t=44746 ? It seems to contradict your opinion about TS running on it.

By the way, your picture link doesn't work. Edit: It works now.

Jean

Re: Raspberry Pi and MegaTunix

Posted: Tue May 15, 2012 8:30 pm
by UnaClocker
No idea why the image isn't working, very odd. Anyways, I thought TS required the official Java. I'll have to give that a whirl, since this stuff is useless without ini parsing and MS3 support.

Re: Raspberry Pi and MegaTunix

Posted: Wed May 16, 2012 2:57 am
by Peter Florance
racingmini_mtl wrote:Interesting but have you seen this: http://www.msextra.com/forums/viewtopic ... 22&t=44746 ? It seems to contradict your opinion about TS running on it.

By the way, your picture link doesn't work.

Jean
pic works for me

Re: Raspberry Pi and MegaTunix

Posted: Wed May 16, 2012 4:36 am
by djandruczyk
Excellent work! Can you post a howto or blog post detailing a step by step for someone new to raspberry pi to be able to get from a bare unit to that state?

Re: Raspberry Pi and MegaTunix

Posted: Wed May 16, 2012 11:41 am
by UnaClocker
Sure will. I'm going to have to setup a fresh debian install so I can keep track of all the packages I installed along the way. It runs rather well, the lack of proper video drivers for X on the Pi makes the gauge refresh a bit laggy, but that'll eventually get sorted out. Really just need a stripped down gauges only install for people who want to use this as an instrument cluster, I'd think.

Re: Raspberry Pi and MegaTunix

Posted: Wed May 16, 2012 12:07 pm
by djandruczyk
UnaClocker wrote:Sure will. I'm going to have to setup a fresh debian install so I can keep track of all the packages I installed along the way. It runs rather well, the lack of proper video drivers for X on the Pi makes the gauge refresh a bit laggy, but that'll eventually get sorted out. Really just need a stripped down gauges only install for people who want to use this as an instrument cluster, I'd think.
use the command line args.
i.e. run it pick the gauge cluster you want, and leave the cluster up when closing megatunix
then run megatunix -rsmq
-r hides runtime text
-s hides runtime status
-m hides main window
-q quiet, no popups

Re: Raspberry Pi and MegaTunix

Posted: Wed May 16, 2012 12:13 pm
by UnaClocker
Does it JUST hide them, or does it skip loading/populating them entirely?

Re: Raspberry Pi and MegaTunix

Posted: Wed May 16, 2012 12:16 pm
by djandruczyk
UnaClocker wrote:Does it JUST hide them, or does it skip loading/populating them entirely?
just hides..

you can remove all the tabs by editing the interrogation profiles and removing the corresponding entries for LoadTabs and TabConfs/

NOTE the mtx release in git is MUCH MUCH faster at loading tabs and only loads the content IF the tab is clicked.

Re: Raspberry Pi and MegaTunix

Posted: Wed May 16, 2012 3:13 pm
by jsmcortina
djandruczyk wrote:NOTE the mtx release in git is MUCH MUCH faster at loading tabs and only loads the content IF the tab is clicked.
I think you'd get more user uptake if you were supplying pre-built binaries (and sources) as zips/packages instead of requiring users to go to git (such a silly name for UK readers.)

James

Re: Raspberry Pi and MegaTunix

Posted: Thu May 17, 2012 6:53 am
by retired
Brian,

That is brilliant - I was thinking of asking Andrew myself as the RPi is a linux environment, and I tend to prefer MTx.

Will watch with interest until mine arrives (10 days away at the moment).

Obviously I'm on the TS thread too (along with Graham from over here in the UK) but an MTx solution would be my preference.

Rod.

Re: Raspberry Pi and MegaTunix

Posted: Thu May 17, 2012 4:04 pm
by UnaClocker
jsmcortina wrote:
djandruczyk wrote:NOTE the mtx release in git is MUCH MUCH faster at loading tabs and only loads the content IF the tab is clicked.
I think you'd get more user uptake if you were supplying pre-built binaries (and sources) as zips/packages instead of requiring users to go to git (such a silly name for UK readers.)

James
I would suspect, and this is definitely the case for me, that the primary problem is the lack of INI parsing. I can't run beta firmware, I can't even run MS3 with this program. There's no steps to follow to overcome that problem.
Seems to me MTx has the ability to be the preferred app for the Pi, given the fact that it's a native compiled app. It doesn't have to have an interpreter running or be compiled at run time. And that's been my experience between the two tuning softwares on the Pi so far. MTx pops up in 1/10th the time of TS. Granted, from there, TS locks up due to RxTx issues ( I haven't sat down and sorted them out yet (hurts my neck staring up at the TV from the floor)) and MTx takes 10 minutes to populate the tabs.. (I have video, but it was too boring to post on YouTube.. heh)..
Ya know, the Pi has a SPI port available to the end user. MicroChip makes some very cheap SPI-CAN adapters. Little app running in the background on the Pi, and your Pi could be on the CAN bus with the MS. Why? So that when the Pi is JUST an embedded instrument cluster (and maybe your stereo too.. heh), you can still plug a laptop into the MS's serial port and do normal tuning from time to time, the serial port wouldn't be hogged by the display device, which has always been a big killer for the MegaView and similar devices.

Re: Raspberry Pi and MegaTunix

Posted: Thu May 17, 2012 5:05 pm
by djandruczyk
UnaClocker wrote:
jsmcortina wrote:
djandruczyk wrote:NOTE the mtx release in git is MUCH MUCH faster at loading tabs and only loads the content IF the tab is clicked.
I think you'd get more user uptake if you were supplying pre-built binaries (and sources) as zips/packages instead of requiring users to go to git (such a silly name for UK readers.)

James
I would suspect, and this is definitely the case for me, that the primary problem is the lack of INI parsing. I can't run beta firmware, I can't even run MS3 with this program. There's no steps to follow to overcome that problem.
Seems to me MTx has the ability to be the preferred app for the Pi, given the fact that it's a native compiled app. It doesn't have to have an interpreter running or be compiled at run time. And that's been my experience between the two tuning softwares on the Pi so far. MTx pops up in 1/10th the time of TS. Granted, from there, TS locks up due to RxTx issues ( I haven't sat down and sorted them out yet (hurts my neck staring up at the TV from the floor)) and MTx takes 10 minutes to populate the tabs.. (I have video, but it was too boring to post on YouTube.. heh)..
Ya know, the Pi has a SPI port available to the end user. MicroChip makes some very cheap SPI-CAN adapters. Little app running in the background on the Pi, and your Pi could be on the CAN bus with the MS. Why? So that when the Pi is JUST an embedded instrument cluster (and maybe your stereo too.. heh), you can still plug a laptop into the MS's serial port and do normal tuning from time to time, the serial port wouldn't be hogged by the display device, which has always been a big killer for the MegaView and similar devices.

Were you testing mtx from sourceforge (tarball) or megatunix compiled from the git repository?

INI parsing is something I'm considering, thought its a gigantic undertaking and takes away a lot of things from MegaTunix that made it unique, primarily the custom and (hopefully) more intuitive UI, as I found the MT/TS's gui layout tedious with things feeling very scattered and very difficult to locate (no offense to james and oother firmware authors, it was due to the original MT design which was rather limiting, and only allowed lists of controls per popup window, TS has improved that a fair bit, but I think it could be far better for the end user). There are several things MISSING from the ts.ini's that are hardcoded within tunerstudio (and also were within megatune), that refer to some legacy hard-coded locations of firmware variables, those are tricky to handle esp since tunerstudio is closed source and megatune is no longer supported or developed.

Re: Raspberry Pi and MegaTunix

Posted: Thu May 17, 2012 6:32 pm
by racingmini_mtl
djandruczyk wrote:There are several things MISSING from the ts.ini's that are hardcoded within tunerstudio (and also were within megatune), that refer to some legacy hard-coded locations of firmware variables, those are tricky to handle esp since tunerstudio is closed source and megatune is no longer supported or developed.
That's true that some things are missing from the ini because they are hardcoded but I think it's only the req fuel computing with associated parameters (engine constants) and the spare ports, at least for the things that originated from MegaTune. And you must already have something for those in MTx. Also the MegaTune source code is still available if you want to have a look: http://www.not2fast.com/megasquirt/mt/. And it's also open source so it should be ok to use it.

Jean

Re: Raspberry Pi and MegaTunix

Posted: Thu May 17, 2012 6:38 pm
by 93white3400z
MegaTunix with ini parsing (and MS3 support) and a raspberry pi.. hummmm I like :D

Re: Raspberry Pi and MegaTunix

Posted: Thu May 17, 2012 6:52 pm
by UnaClocker
93white3400z wrote:MegaTunix with ini parsing (and MS3 support) and a raspberry pi.. hummmm I like :D
Me too. I certainly know enough programming to get in there and toss out any extra parts I don't want/need for my own personal setup, to help streamline it.
And I downloaded from Sourceforge, it was what came up when I googled it. Actually had to do quite a bit of digging, it seemed like, just to download it. Had no way of knowing if it was a recent version or not, but figured it wasn't, since the date on it was 2010..
I'm waiting for the Raspbian distro to mature a little bit before I redo the install on my good SD card. Raspbian should improve performance quite a bit too, everything is recompiled to use the hardware FPU, the default Debian distro is doing software floating point. (something about it being compiled for a different brand of ARM that doesn't normally have an FPU, if I remember right)

Re: Raspberry Pi and MegaTunix

Posted: Thu May 17, 2012 8:21 pm
by racingmini_mtl
If you look at the announcements, you'll see that Dave posted about the new version having moved to Git: http://www.msextra.com/forums/viewtopic ... 06&t=35786.

Jean

Re: Raspberry Pi and MegaTunix

Posted: Thu May 17, 2012 8:24 pm
by UnaClocker
Ahh yeah, I read that yesterday.

Re: Raspberry Pi and MegaTunix

Posted: Thu May 17, 2012 8:56 pm
by UnaClocker
Ok, downloaded Raspbian and wiped my old install and installed Raspbian. So from a fresh install, seems all I needed was the suggested prereq's from the Ubuntu thread:

Code: Select all

sudo apt-get install pkg-config libtool intltool libgtkglext1-dev g++ gcc flex bison glade libglade2-dev make git-core gdb automake1.9
Then I followed the git cloning and building instructions. It's compiling right now, made it through the configure scripts without complaint on the first try.
So between having the latest version, and native FPU support, I expect it'll run much better now. In the meantime, it's past my bedtime. I'll report back tomorrow.

Re: Raspberry Pi and MegaTunix

Posted: Fri May 18, 2012 9:04 am
by UnaClocker
Tried out MegaTunix for a couple minutes before leaving for work. I've definitely got to get some video of this now. It loads instantly! Click the icon and it's UP. Definitely a winner with performance like that. Unfortunately, it seems a bit unstable? I chose MS3 and it crashed. Maybe that mode isn't ready yet? I reloaded with the MS2-Extra setting, and it crashed again when I tried to fire up a dashboard. (the Honda one, fwiw).
Also, your GIT instructions don't mention the "sudo ldconfig" command which is required, but it is mentioned in the Ubuntu instructions.