Datalog target afr

Forum for discussing Tuner StudioMS tuning & datalogging software.
Forum rules
Read the manual to see if your question is answered there before posting. If you have questions about MS1/Extra or MS2/Extra or other non-B&G code configuration or tuning, please post them at http://www.msextra.com The full forum rules are here: Forum Rules, be sure to read them all regularly.
Post Reply
edgedj
MegaSquirt Newbie
Posts: 4
Joined: Sat Jul 03, 2004 2:52 pm
Location: UK, Jersey

Datalog target afr

Post by edgedj »

Hi,

Does anyone know if there is an easy way of datalogging target afr. I'd really like to see it in MegaLogViewer just below the real afr...

Cheers
Dave
Bernard Fife
Super Squirter
Posts: 1009
Joined: Mon Feb 16, 2004 3:15 pm

Post by Bernard Fife »

Dave,

Add the line:

Code: Select all

   entry = afrtgt1,         "AFRtrgt1",    float,  "%.2f"
to the [datalog] section at the end of the INI file (megasquirt-II.ini, for example). You'll see quite a few others there, add the line above anywhere you like (where you put it determines where it is shown in the datalog and viewer listing).

This may give you values that are 100 times to large (ex, 1370 instead of 13.7) - if so, find a line in the same file like:

Code: Select all

   afr1             = scalar, S16,   28, "AFR", 10.00, 0.0
and change it to:

Code: Select all

   afr1             = scalar, S16,   28, "AFR", 0.100, 0.0
There are corresponding entries for afr2 and afrtgt2 if you are running dual wide-band sensors, and you can add that too.

Lance.
edgedj
MegaSquirt Newbie
Posts: 4
Joined: Sat Jul 03, 2004 2:52 pm
Location: UK, Jersey

Post by edgedj »

brilliant, thanks Lance. It worked perfectly. I then set the field min & max for both afr & afrtrgt1 in Megalogviewer to 9 & 25 and they overlay perfectly.

I think this really could have been solved by me :RTFM: though, sorry!

Cheers
Dave
Bernard Fife
Super Squirter
Posts: 1009
Joined: Mon Feb 16, 2004 3:15 pm

Post by Bernard Fife »

I think this really could have been solved by me though, sorry!
Dave,

No problem, I'm glad you brought it up, it reminds me to add it to the default INI files for V2.6 and V2.8 MS-II code!

Lance.
Holger
MegaSquirt Newbie
Posts: 3
Joined: Tue Nov 08, 2005 6:51 am
Contact:

Post by Holger »

hmmm by me, it didnt work :|
i put it in the megasquirt.ini but it will not be shown in the logviewer (V2.0)
Bernard Fife
Super Squirter
Posts: 1009
Joined: Mon Feb 16, 2004 3:15 pm

Post by Bernard Fife »

Holger,

You probably didn't modify the ini file that Megasquirt is using. If oyu look for the audit.log file (makes sure it is dated the same as the last time you openend MegaTune) you'l see all the files and directories MegaTune used to open. Look for lines like:

Code: Select all

r MegaSquirt-II.ini
   + C:/Program Files/MegaSquirt/MS2_v2.8/mtCfg/MegaSquirt-II.ini
   MegaSquirt-II.ini:0102    #if LAMBDA, including=false
   ...
The first line tells you which ini file was used (it will be something like megasquirt.ini, megasquirt-II.ini, or MSnS.ini). The second of these lines tells you which directory it is in. That will be the file you want to modify.

Lance.
Post Reply