Page 1 of 1

Ignoring lookup tables?

Posted: Thu Apr 17, 2008 12:11 am
by JCD
I connected the outputs of an accelerometer to the LM1 aux inputs 1,2 and 3.
http://www.sparkfun.com/commerce/produc ... cts_id=692
Seems to work fine but I have a problem with the wideband lookup tables.
The data in the auxX.cvs files starts with a name (RPM for the aux1, SIDEFORCE for the aux2) but still I find Aux1 on top of the corresponding column in the logfile.
And what is worse, no mather how I edit the values in the auxX.cvs files I always get values of around 0.33 (for an LM1 aux1 input voltage of about 1.65V) in my log.

Also the Aux6 column is not present.

I'm using the 0.925 version of the software.
BTW sometimes after starting Nistune I can't connect to the wideband because the default value in the configuration window seems to be COM3. The previous time that the program was used, it was with COM1.
That value seems to be changing from itself.
I had this issue with previous versions too...

Posted: Fri Apr 18, 2008 12:16 am
by Matt
1. Log files are always recorded with the main label as per their original auxiliary input number

This is for good reason... I noticed this a while back when we were putting the user defined name into the log files, and then when NIStune was to play it back, if the user defined name wasn't in any of the lookup tables then it would be marked as 'invalid' and would not play back

Especially annoying if users had wide band input in log files they were posting to this forum

Usually the CSV files are only used for playback. The only work around I can think of for this is to include in the second row of the log file the user defined name, solely for the purpose of viewing the CSV files in Excel or similar. If that sounds good then I can add this as an enhancement item

2. Doesnt look right. So I tested it using the simulated inputs (which is just an input value 0-1023) and it does translate as it gets changed (see attached CSV files)

First one is the original lookup tables
Second one is using accelerator lookup table changed to 50 - 100 mapping

You can see the values follow the lookup.

Note that when you change the lookup tables you should restart NIStune to pick up the new tables. Post the log file it produces along with debug log (which captures raw inputs) and I can check it out for you

3. Aux 6 column may not be used by your innovate unit which is why there is no log output. If you post a debug log when you connect to it I can check that out for you

4. This is an issue. Mainly because the COM ports are auto detect each time you open the config window. If the COM port is used, then it is not available and can change the list of items to select from when the config window is opened again. I'll put it as a bug to investigate

Posted: Fri Apr 18, 2008 7:57 am
by JCD
OK Matt :)

1. I was wrong by thinking the names in the logfile would depend on the names in the lookup csv files. Don't put your effort in this any further.

2. It seems to work for you.
During the weekend I'll take the time to document all this with log, debug log and edited lookupfiles.

3. The logfiles that you attached don't contain a Aux6 column neither.
Err, the Innovate Logworks files neither...
Because there is no Aux6 input.
Oops, wrong planet :oops:
I apologise for this false rumour.

4. It happens randomly. When I notice it, I'll start the debug log but it might be too late for the interesting part then.

Cheers,

Jean

Posted: Fri Apr 18, 2008 9:51 am
by Matt
There is a Aux6 file in the wideband folder. Perhaps should be removed to avoid further confusion!

When you do you logging, post it through and I'll have a look.

Try to do debug logging with only Wideband connected (you will need to tick 'Wideband only logging' in File-Configuration also)

The consult data fills up the log quite quickly and make it difficult to differentiate it from wideband

Posted: Mon Apr 21, 2008 1:38 am
by JCD
2. Fixed! (because there was nothing to fix :) )
I edited the original lookup files from:
  • RPM
    0,0
    1023,10230
to
  • RPM
    0,0
    5000,5000
thinking that the 5000 value would be represented as 5000mV.
Nistune -clever as it is- knows that an Innovate has an output of max 1023 (10bit) and does not accept my 5000. Instead it keeps 1023 and scales accordingly. That's why my 1.65V ended up in the logfile as 0.33V.
With a decent lookup instead it works perfect!

3.
Matt wrote:There is a Aux6 file in the wideband folder. Perhaps should be removed to avoid further confusion!
Aha! I was wondering from where I got that idea that there were 6 inputs LOL

4. I wasn't able to reproduce the error. Attached a debug logfile anyway.
Good luck :D

Posted: Sun May 04, 2008 3:07 am
by Matt
Latest version wont rearrange com ports when they are used in the File-Configuration window. That is probably what was changing things

Should be sorted now

Posted: Sun May 04, 2008 6:14 pm
by JCD
That's fine thanks.

By the way the text in the afr1.csv
  • AFR
    0 8
    5000 32
is a bit confusing. Wouldn't it be clearer to put
  • AFR
    0 8
    1023 32

Posted: Sun May 04, 2008 7:44 pm
by Matt
Okay thanks. I've updated the lookup tables which are put in the installer pack for subsequent versions

Posted: Wed May 07, 2008 8:16 am
by JCD
I had a dark brown suspicion that something was not yet straight in this hystory and I did the following test.
I connected a 1.642V source to the aux 1,2 and 3 inputs.
Made the following lookup tables:
  • aux1
    0,0
    1023,5000
  • aux2
    0,0
    1023,500
  • aux3
    0,0
    5000,5000
Nistune displays:
aux1 1642
aux2 164.2
aux3 336.0
When I increase the voltage by a couple of mV (to be shure to have 1 bit up in the ADC) displayed values are 1647, 164.7 and 337.0 which is OK.
So don't follow the suggestion from my previous post :oops: without scaling the values 8 and 32 accordingly cos the 5000 instead of 1023 indeed makes a difference.

Posted: Wed May 07, 2008 5:03 pm
by JCD
Those lookup tables are a convenient way of making your own scalings but one should know how to use them.
Installation of a new Nistune version overwrites these files so keep a copy somewhere.
The readme.txt in the Wideband directory might need some update.
The lookup for the AFR seems to work differently. With 0,8 5000,32 the LM1 should output something like 1396 to give 14.7 which is something I don't understand but who cares - as long as it works it's OK :D
The guys with the LC-1 seem to have a problem though
http://ibconceptions.com/Nistune/viewtopic.php?t=570