TunerStudio in Linux - automatic logging upon launch?

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

TunerStudio in Linux - automatic logging upon launch?

Postby dieselgeek » Mon Jun 18, 2012 7:01 am

I recently built an in-car PC for datalogging to avoid having to strap a laptop into a 300+mph landracing car. Car is running MS3X, but the SD logging isn't able to capture as much data as I need (also using a fully populated IOX).

I am running Ubuntu 12.04, and the TunerStudio and MegaLogViewer installs went perfectly easily. Simpler than Windows, actually.

Here's my question. Is there any current method, after booting into Linux, TunerStudio could be set up to automatically begin a datalog? Right now, the in-car PC boots in about 20 seconds, and I have set TunerStudio to launch automatically, the icing on the cake would be a way to launch TS from the command line and tell it to start logging.

Any suggestions are welcome!

(thought I'd add, I'm using VNC to remotely control this machine over an adhoc Wifi network. With a good antenna in the race car, and another on the push vehicle, it appears as though I'll be able to monitor and tune while the car is on course. Will be testing this more in the coming weeks before Bonneville).

-Scott
Squirted: it's easier to list the ones I haven't squirted. I need to do more motorcycle engines!
dieselgeek
Master MS/Extra'er
 
Posts: 458
Joined: Wed Sep 08, 2004 12:27 pm
Location: The Midwest

Re: TunerStudio in Linux - automatic logging upon launch?

Postby LT401Vette » Mon Jun 18, 2012 1:52 pm

Hi Scott,
Unfortunately, there is not. That wouldn't bea big deal and I have a plan for this beta cycle to cover it.
But right now you would need to do CTRL+L to start logging.
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: 8322
Joined: Sat Jul 16, 2005 8:07 am
Location: Moorseville, NC

Re: TunerStudio in Linux - automatic logging upon launch?

Postby dieselgeek » Mon Jun 18, 2012 1:56 pm

LT401Vette wrote:Hi Scott,
Unfortunately, there is not. That wouldn't bea big deal and I have a plan for this beta cycle to cover it.
But right now you would need to do CTRL+L to start logging.


No problem. I'm happy to run a beta so, I will keep an eye out for it!! will gladly test it for you too.
Squirted: it's easier to list the ones I haven't squirted. I need to do more motorcycle engines!
dieselgeek
Master MS/Extra'er
 
Posts: 458
Joined: Wed Sep 08, 2004 12:27 pm
Location: The Midwest

Re: TunerStudio in Linux - automatic logging upon launch?

Postby The Deviant » Mon Jun 18, 2012 3:02 pm

It's sort of a kludge, but it will work until the feature is implemented in TS - using xdotool.

You can install it on your Ubuntu system with:

sudo apt-get install xdotool

xdotool does all sorts of neat things (can move the mouse, insert keystrokes, bring windows into focus, move 'em around, etc.).

Below is a simple script that will start TS and start logging, using xdotool to do the magic.

(Script starts TS, waits 15 seconds, sets variable "zid" to the windowid of the TS window, activates the TS window, then sends the keystrokes.)

jbass@galactica:~/TunerStudioMS$ cat AutoLog.sh
./TunerStudio.sh &
sleep 15
zid=`xdotool search --name "TunerStudio MS\(Beta\).*"`
xdotool windowactivate --sync $zid
xdotool key --clearmodifiers ctrl+l KP_Enter

jbass@galactica:~/TunerStudioMS$

Hope this helps some...
James B.
1985 Merkur XR4Ti Rally Car
MS3 3.57+MS3X+RTCC+Knock
Ford Lima 2.3 Turbo/MSD LS2 COPs/DIYAT Hall Cam Sensor/Electromotive VR Crank Sensor
Nexus 7 Instrumentation with Shadowdash MS
User avatar
The Deviant
Helpful MS/Extra'er
 
Posts: 99
Joined: Thu Apr 14, 2011 8:41 am
Location: Jefferson County, Missouri, USA

Re: TunerStudio in Linux - automatic logging upon launch?

Postby dieselgeek » Wed Jun 20, 2012 6:10 pm

James, that script worked perfectly - no debugging whatsoever, THANK YOU!!


Now I have an in-racecar PC that boots up in 15 seconds when the ignition is switched on, fires up TS and starts a timestamped datalog. So far, this system (on my kitchen table wit a 12v power supply) is 100% rock solid.

I plan on connecting to it via VNC with my laptop via ad hoc wifi, when in the pits or staging. Plus I get the benefits of fastest data logging using the serial port on the car pc.

Thanks again, this is exactly what I needed,

-Scott
Squirted: it's easier to list the ones I haven't squirted. I need to do more motorcycle engines!
dieselgeek
Master MS/Extra'er
 
Posts: 458
Joined: Wed Sep 08, 2004 12:27 pm
Location: The Midwest

Re: TunerStudio in Linux - automatic logging upon launch?

Postby Nigep » Mon Jun 25, 2012 11:45 pm

James, I shall be trying that !

I have a dedicated laptop that sits in my track car, all it does it datalog (occasionally I tweak the map, but thats is VERY infrequently), 99% of the time it is used to simply datalog. I`m running lubuntu and it automatically runs Tunerstudio, I then have to manually datalog once the car is turned on.

If your method works, that will do EXACTLY what I need !


Hopefully, a future release will have an `automatically datalog on startup` tickbox. If it loaded and started datalogging to a time-stamped file once the ECU was turned on, then stopped once the car was turned off, that would be perfect, but it sounds like your method is pretty close.

Thanks for posting. :D
Nigep
Helpful MS/Extra'er
 
Posts: 43
Joined: Wed Jan 18, 2012 12:50 am
Location: West Yorkshire, UK.

Re: TunerStudio in Linux - automatic logging upon launch?

Postby Nigep » Wed Jun 27, 2012 11:26 pm

Er, this may be blindingly obvious to others, but where do I put the script to `autorun` so it starts logging automatically ? :oops:
Nigep
Helpful MS/Extra'er
 
Posts: 43
Joined: Wed Jan 18, 2012 12:50 am
Location: West Yorkshire, UK.

Re: TunerStudio in Linux - automatic logging upon launch?

Postby piledriver » Fri Jun 29, 2012 9:39 am

Nigep wrote:Er, this may be blindingly obvious to others, but where do I put the script to `autorun` so it starts logging automatically ? :oops:


It depends on what desktop you are using:

kde,:mkdir ~/.kde/Autostart, stick the script in there, chmod it executable, and Bobs your uncle after you restart X..

If running the default Ubuntu Gnome based setup, http://www.ghacks.net/2009/04/08/add-an ... autostart/

For lxde http://wiki.lxde.org/en/Autostart (Highly recommended, low overhead Lightweight X11 Desktop Environment)
Always doing things the hard way, MS2 sequential w/ v1.01 mainboard, LS2 coils. 80 mile/day commuter status.
piledriver
Super MS/Extra'er
 
Posts: 1134
Joined: Tue Oct 27, 2009 6:24 am
Location: Van Alstyne, Texas

Re: TunerStudio in Linux - automatic logging upon launch?

Postby dieselgeek » Fri Jun 29, 2012 9:44 am

piledriver, do you recommend me running the lighter weight X environment on my Atom processor car PC? Teh default Ubuntu window manager seems fine, vmstat shows the box is 98% idle when TS is up and logging...


Any other input on my car PC is welcome! I'm not working up a wifi ad hoc network setup so I can remote control the PC from inside our push truck. Provided I can set up decent wifi antennae and probably a 1w booster on each end.
Squirted: it's easier to list the ones I haven't squirted. I need to do more motorcycle engines!
dieselgeek
Master MS/Extra'er
 
Posts: 458
Joined: Wed Sep 08, 2004 12:27 pm
Location: The Midwest

Re: TunerStudio in Linux - automatic logging upon launch?

Postby Peter Florance » Fri Jun 29, 2012 9:55 am

dieselgeek wrote:piledriver, do you recommend me running the lighter weight X environment on my Atom processor car PC? Teh default Ubuntu window manager seems fine, vmstat shows the box is 98% idle when TS is up and logging...


Any other input on my car PC is welcome! I'm not working up a wifi ad hoc network setup so I can remote control the PC from inside our push truck. Provided I can set up decent wifi antennae and probably a 1w booster on each end.

http://www.radiolabs.com/Articles/wifi-antenna.html

Directional antennas maybe?
Peter Florance
PF Tuning
81 BMW Euro 528i ESP Car
60-2 Wheel LS2 Coils, Low Z Inj
Check your grounds: http://www.msextra.com/doc/general/grounding.html
User avatar
Peter Florance
Super MS/Extra'er
 
Posts: 3377
Joined: Fri Apr 02, 2004 8:40 pm
Location: Virginia Beach, VA

Re: TunerStudio in Linux - automatic logging upon launch?

Postby piledriver » Fri Jun 29, 2012 10:47 am

dieselgeek wrote:piledriver, do you recommend me running the lighter weight X environment on my Atom processor car PC? Teh default Ubuntu window manager seems fine, vmstat shows the box is 98% idle when TS is up and logging...


Any other input on my car PC is welcome! I'm not working up a wifi ad hoc network setup so I can remote control the PC from inside our push truck. Provided I can set up decent wifi antennae and probably a 1w booster on each end.


I would give it a shot, once lxde is installed you just select it as your default desktop once from the GDM or whatever (you get it when you log out of X .. The "login" screen should have menus for stuff)

Gnome, esp the Unity desktop ... (expletives deleted)... is a resource hog not meant for weak processors/graphics.
The next version won't even have a 2D only option.

There's literally a herd of window managers out there to try, XFCE is another somewhat more integrated option for lightweight hardware.

It's going to be tough to get a mile of range out of wifi with a bulletproof signal in a possibly electrically noisy environment, but you know the drill with the resistor plugs etc.
You'll need directional antenne at least.

IIRC you may be able to stream digital (modem) data on CB bands, might check on the legality and practicality of that.
At least you won't be power limited.
.
Always doing things the hard way, MS2 sequential w/ v1.01 mainboard, LS2 coils. 80 mile/day commuter status.
piledriver
Super MS/Extra'er
 
Posts: 1134
Joined: Tue Oct 27, 2009 6:24 am
Location: Van Alstyne, Texas

Re: TunerStudio in Linux - automatic logging upon launch?

Postby dieselgeek » Fri Jun 29, 2012 11:59 am

I have a HAM license. I can stream over packet radio up to, I believe, 5 watts? I have to check into that. Was hoping that I could use decent antennae and power booster to get there. I'm a little afraid of a completely directional antenna because those need aimed properly and this is a slightly moving target. Semi-directional would work best. I notice that racing radio systems seem to put an Omni on the car, and a Yagi or other directional along the track...

let's go ahead and have that discussion if you guys are interested. I have a simple Intel mini-PCI card in the car, and two antenna leads coming off it (that I can solder to whatever antenna I end up using.

SOme at my work have suggested I should use a wireless access point meant for cars (trains, actually) as these can have higher transmit power. I'd rather do it without the A/Ps. How would you guys approach this?
Squirted: it's easier to list the ones I haven't squirted. I need to do more motorcycle engines!
dieselgeek
Master MS/Extra'er
 
Posts: 458
Joined: Wed Sep 08, 2004 12:27 pm
Location: The Midwest

Re: TunerStudio in Linux - automatic logging upon launch?

Postby old guy » Fri Jun 29, 2012 3:37 pm

Have you looked at any of the X-Bee stuff. I had some on a racing motorcycle that were good for 1/2 mile, but they make modules that have more range than the ones that I was using. They are line of sight,but i am sure this would be no problem at Bonneville. Here is a link to a sight that has a lot of X-Bee products and information, but if you look around you can find a little better price on these.
Board member Whittlebeast gave me a lot of help setting these up.
http://www.sparkfun.com/
old guy
Experienced MS/Extra'er
 
Posts: 184
Joined: Thu Jan 24, 2008 9:20 am
Location: North Carolina

Re: TunerStudio in Linux - automatic logging upon launch?

Postby piledriver » Sat Jun 30, 2012 8:52 pm

Hhhhmmm that would have been less expensive (series 1) or about the same (series2) as a BT solution...

Hows the effective datarate etc? (series 2B=1 mile range, is that with omnis? Me likes, HTF did I never notice these? :yeah!: )

BT says it can do serial data at 900K baud, but it's latency is the pits & ~no timing guarantees, it can barely give you 15FPS updates on Tuner Studio, but I suppose with a remote X session, it would be NBD as the X11 protocol itself and the remote access systems were built to work with high latency marginal connections.

I'd happily pay again for a wireless setup that could deliver a solid >50 FPS update rate in TS like std RS232.

Any suggestions as to a cheaper source than sparkfun for the Xbees?
(preferably one that actually answers technical questions unlike sparkfun)

EDIT---bad news is xbees/xbee Pros are apparently really limited in meatspace to <56K half duplex serial data, ~19.2 full duplex, so same or slower than BT. :cry:
(i.e: You can SET it to 156K, but don't expect to get actual data out the other end)

but if you have $900/end to spend, they have a 4W 900MHz ethernet bridge that can give you ~1mb, up to 15 mile range LOS with dipoles. :twisted:

What do the big dogs use for telemetry?
Always doing things the hard way, MS2 sequential w/ v1.01 mainboard, LS2 coils. 80 mile/day commuter status.
piledriver
Super MS/Extra'er
 
Posts: 1134
Joined: Tue Oct 27, 2009 6:24 am
Location: Van Alstyne, Texas

Re: TunerStudio in Linux - automatic logging upon launch?

Postby old guy » Sun Jul 01, 2012 9:21 am

A little bit over my head on all the technical stuff. I was just using them to data-log, not remotely tune the vehicle You may want to pm Whittlebeast . He is a racer and a really nice guy and was the one that helped me set these things up.
As far as the price, look around on E-Bay or just do a Google search. I think I had about $150 in my setup including antennas, enclosures and misc components.
You might also want to research some of the stuff that radio control airplanes are using. i have seen some that even have video camera capabilities.
Hope this helps.
old guy
Experienced MS/Extra'er
 
Posts: 184
Joined: Thu Jan 24, 2008 9:20 am
Location: North Carolina

Re: TunerStudio in Linux - automatic logging upon launch?

Postby Nigep » Thu Jul 05, 2012 10:55 pm

Anyway...... if Tunerstudio can automatically log on startup, that`d be great... :mrgreen:
Nigep
Helpful MS/Extra'er
 
Posts: 43
Joined: Wed Jan 18, 2012 12:50 am
Location: West Yorkshire, UK.

Re: TunerStudio in Linux - automatic logging upon launch?

Postby jibaine » Tue Feb 05, 2013 5:52 am

Hello, can somebody gives me the script he use to start Tuner Studio at login, I run it on Linaro distribution with LXDE desktop. I can execute a simple shell at login (.config/autostart method) but not launch TS.
Thank you
jibaine
MS/Extra Newbie
 
Posts: 1
Joined: Tue Feb 05, 2013 5:47 am


Return to Tuner Studio

Who is online

Users browsing this forum: No registered users and 0 guests