SD Card Logging Issues

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

NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

SD Card Logging Issues

Post by NigeT »

I'm having some problems accessing SD Card logs which are being collected automatically because the Megasquirt is configured to start logging on card insertion. I'm using a registered copy of TunerStudio (v2.6.14) with my MS-Labs MS3 Basic (serial signature MS3 Format 0435.16, firmware version 1.3.4?).
When using the Browser / Import SD Card facility of TunerStudio to upload logs from the SD Card, the operation is extremely slow and almost always fails with an error pop-up: [attachment=-1]uploadfromtaptalk1432074360823.jpg[/attachment]
Quite often this leaves TunerStudio hung up, although it has blue screened my lap top too.

Is this a known problem? Dimitris from MS-Labs suggested I should ask.

Thanks in advance, Nigel.
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

Is there anything I can do to help diagnose the cause of the problem?
Speedy_G
Experienced MS/Extra'er
Posts: 195
Joined: Fri Aug 01, 2014 8:30 am

Re: SD Card Logging Issues

Post by Speedy_G »

how fast is the data transmission rate?
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

Hi, thanks for helping - at what point in the chain do you mean? I believe the MS3 supports USB 2, the laptop USB 3, or possibly 2 depending on which port plugged into. I'm not sure what class the SD card is, I'll have to take the trim off, pull the carpet up and get unscrew the cover to get it out of the MS3. The laptop has no problems reading it directly and it appears the MS3 writes to it without any problems, although the MS3 does seem to log bad values very occasionally, but it does over Bluetooth and directly over USB to the laptop too.
jsmcortina
Site Admin
Posts: 39619
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK
Contact:

Re: SD Card Logging Issues

Post by jsmcortina »

How were you connected to the MS3 when this happened?

Please describe in more detail the "logged bad values" ? Is this to the card or are you seeing bad data shown in TunerStudio?

James
I can repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: http://www.msextra.com/forums/viewtopic ... 04&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
New users, please read the "Forum Help Page".
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

I have only tried pulling SD logs off the MS-3 via USB connection and TunerStudio. Because this doesn't work I have mostly been logging recently by way of Bluetooth and ShadowDash, and I have only seen the odd single value bad value in a log (I haven't checked scroll all metrics at that time to see if several were affected). E.g. a single sensor01 value of 140 in a whole log where all other values were below 110.
I believe all the TunerStudio hangs have been when connected via USB, and probably when trying to download SD logs. I'm sorry bit I haven't kept track of what I was doing with TunerStudio when Windows has blue screened, but I always connect the laptop via USB as I have the Bluetooth adapter plugged into the serial port.
I have never used USB and Bluetooth connections concurrently.
Thanks, Nigel.
jsmcortina
Site Admin
Posts: 39619
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK
Contact:

Re: SD Card Logging Issues

Post by jsmcortina »

Having the Bluetooth plugged in at the same time as trying to use the USB-serial can cause data corruption.

James
I can repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: http://www.msextra.com/forums/viewtopic ... 04&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
New users, please read the "Forum Help Page".
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

Having to unplug the Bluetooth adapter from the serial port to use the separate MS3 USB port makes it pretty much worthless. I can't be pulling the car interior apart every time I want to connect over USB instead of Bluetooth, in much the same way as I can't be doing so to pull the SD card out to get logs off it.
:-(
Matt Cramer
Super MS/Extra'er
Posts: 17507
Joined: Thu Apr 16, 2009 8:08 pm

Re: SD Card Logging Issues

Post by Matt Cramer »

Can you rig a power switch for the BT adapter?
Matt Cramer -1966 Dodge Dart slant six running on MS3X
LT401Vette
Super MS/Extra'er
Posts: 12733
Joined: Sat Jul 16, 2005 8:07 am
Location: Moorseville, NC
Contact:

Re: SD Card Logging Issues

Post by LT401Vette »

I'm sorry bit I haven't kept track of what I was doing with TunerStudio when Windows has blue screened, but I always connect the laptop via USB as I have the Bluetooth adapter plugged into the serial port.
Were you plugged into the MS3 onboard USB when you Blue screened?
I have never heard of a blue screen while using an FTDI chip as on the MS3, only with older Prolific drivers.


Do you connect TS over the Bluetooth as well?
One thing to watch if downloading SD files over bluetooth.... Make sure the SD Read back baud is set to 115200, otherwise TS will try to switch bauds which the BT Adapter doesn't support.


And yes, if you have the BT Adapter plugged in while working over the USB you will get corruption/dropouts.
Is it an option to run a DB9 cable from the MS3 to a place that is easier to access for plugging/unplugging the BT Adapter?
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
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

@Matt, yes I think that might be easiest and most effective - I've never wanted to use both simultaneously but had assumed that having no BT connection would mean no significant interaction between the BT adapter and the MS3 steroidal port... Thanks.
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

@Phil, yes I've only used the MS3 on-board USB and, apart from once to see if it works, I don't think I've ever used BT to download the SD files. I'd always assumed that BT was more likely to be flaky than USB and since download over USB fails almost every time (with errors like that attached to the first post) I didn't even try with BT.
If switching the BT adapter off when using USB will cure the data errors then I think that may be my best option - I have easy access to it's 12V supply. However I do see errors in logs collected by ShadowDash over BT when nothing is plugged into the USB cable? Would an unterminated USB cause corruption/dropouts in the BT data?

Thanks again.
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

You've gotta love what Swype does when your not looking. :-)
LT401Vette
Super MS/Extra'er
Posts: 12733
Joined: Sat Jul 16, 2005 8:07 am
Location: Moorseville, NC
Contact:

Re: SD Card Logging Issues

Post by LT401Vette »

Would an unterminated USB cause corruption/dropouts in the BT data?
Nope, it should be fine if there is nothing is plugged into it..
I would need to know what kind of error to say anything more.

BTW, BT should not be flaky once connected. It is slower, but you sure should have trouble downloading SD.
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
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

Thanks Phil.
Is there anything I can do to get more information about the original USB download problem? The only information I have seen is the pop-up that I attached an image of - does TunerStudio have some debug modes I can enable I'm sure it will fail the same way if I try download one of the files on the SD Card.
If you mean the errors in the data, iirc I had a single data point of way off all the others recorded for sensor 01 which is connected to a PLX fluid temperature sensor controller in this case the sensor is monitoring the oil temperature.
Thanks, Nigel.
LT401Vette
Super MS/Extra'er
Posts: 12733
Joined: Sat Jul 16, 2005 8:07 am
Location: Moorseville, NC
Contact:

Re: SD Card Logging Issues

Post by LT401Vette »

Have you tried with the BT Adapter unplugged?
Still having the issue?

You can make a comm debug log in TS, that will show every exchanging if data. In the end, the dialog above is showing why the final stop happens, the MS reported that it did not understand an instruction. That typically happens if bytes are being dropped, which is what happens when there is a BT adapter plugged in to the DB9 while you are talking over the USB.
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
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

Oops, good point Phil, the adapter has always been plugged in. I'll unplug it tonight and retry. Sorry, thought the BT adapter bring plugged in was only a possible cause of data corruption, didn't make the connection that it was impacting the USB SD log browsing. Is there any way that the two comms mechanisms can be isolated from each other?
jsmcortina
Site Admin
Posts: 39619
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK
Contact:

Re: SD Card Logging Issues

Post by jsmcortina »

NigeT wrote:Is there any way that the two comms mechanisms can be isolated from each other?
On MS3 they are physically joined internally.

James
I can repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: http://www.msextra.com/forums/viewtopic ... 04&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
New users, please read the "Forum Help Page".
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

That'll be a no then. :-)
NigeT
Master MS/Extra'er
Posts: 419
Joined: Wed Apr 08, 2015 1:14 pm

Re: SD Card Logging Issues

Post by NigeT »

Wasted a couple of hours trying this out today. Couldn't get the laptop to connect over USB. Basically found that with the BT adapter plugged into the serial port TunerStudio won't connect over USB unless the BT adapter has power. Eventually I disconnected the adapter from the serial port itself and after several attempts got TunerStudio to connect up.

I then tried to download the latest log from the SD Card. I got exactly the same error as I reported at the start of this thread. I unplugged the USB, plugged the BT adapter back in and powered it up and attempted to connect TunerStudio to MS3 via Bluetooth. The laptop could see the MS3 on COM port 8, but TunerStudio would not connect. I got my phone out and fired up Bluetooth and ShadowDash and it immediately connected.
So the SD Card logging remains a write only operation.
In the midst of all this TunerStudio reporting reading the wrong firmware version several times.
Somewhat worrying.
Post Reply