Megalogger issue with Kit#3

Inquiry and support for Freematics products
tux4pres
Posts: 10
Joined: Wed Nov 11, 2015 1:53 pm

Megalogger issue with Kit#3

Post by tux4pres »

Hello,

I'm running into an issue with my new kit #3. I plugged in my kit as described in the guide and no PIDs were listed. The readout was as shown:
Read out with the shipped firmware installed.
Read out with the shipped firmware installed.
ShippedFirmware.jpg (28.63 KiB) Viewed 22842 times


I then uploaded the current firmware to try and remedy the issue. The readout changed for the worse:
Read out with the newest firmware installed.
Read out with the newest firmware installed.
NewestFirmware.jpeg (88.46 KiB) Viewed 22842 times


What can I do to try to help troubleshoot?

Thank you,
Tux4Pres.
tux4pres
Posts: 10
Joined: Wed Nov 11, 2015 1:53 pm

Re: Megalogger issue with Kit#3

Post by tux4pres »

Sorry, I didn't list the things I've tried.

I've tried three different Megas. Two 2560s and a 1280.
I've tried uploading with the GPS and/or the OBD-II unplugged.
I've tried uploading while being powered by the OBD-II via the vehicle's(1999 Jeep Cherokee) 12 volt power.
I've tried several vehicles. 1999 Jeep Cherokee, 1998 Jeep Cherokee, 2000 Honda Odyssey.
I've tried without data logging.
I've tried old versions of megalogger. I was meticulous with mating the libraries with the firmware.
I tried the tester code with the Arduino serial monitor. The first boot it read data, the second boot the text wasn't readable and the rest of the boots have resulted in nothing.
I'm using Arduino software version 1.6.6 to compile and upload the code.

The results have not changed despite my efforts. Unfortunately, I've tried so many different versions of code that I can't pair code changes to results. I am very open to trying whatever troubleshooting you want me to do.

Thanks again,
Tux4Pres.
Syl
Posts: 8
Joined: Fri Sep 18, 2015 12:30 am

Re: Megalogger issue with Kit#3

Post by Syl »

Hi,

I also own an Kit#3. I can tell you what worked for me, maybe it helps you.

- Megalogger sketch 20150509 from this source: http://sourceforge.net/projects/obdcon/files/logger/
Both, sketch an libraries. Make sure you have the korrekt libraries in your Arduino folder at your dokuments.
- Arduino version 1.6.5 with the settings for the Mega 2560.

Pretty much worked at the first shoot. Problem was to create working kml files out of it.

EDIT:

Almost forgot, did you set the config.h file correkt?
tux4pres
Posts: 10
Joined: Wed Nov 11, 2015 1:53 pm

Re: Megalogger issue with Kit#3

Post by tux4pres »

Thank you very much for the reply. Here is what I tried:

I downloaded the file from 050915. It contained the folders: library and megalogger

I deleted the existing libraries:
I2Cdev
MicroLCD
MPU6050
MPU9150
MultiLCD
Narcoleptic
OBD
SIM800
TinyGPS

I added the libraries from the 050915 build:
I2Cdev
MicroLCD
MPU6050
MPU9150
MultiLCD
OBD
TinyGPS

Changed config.h to:
I have the Beitian BT-608 GPS that should be 10Hz.
#define GPS_BAUDRATE 115200
#define USE_MPU6050
//#define USE_MPU9150
LCD settings were already right.
LCD_SSD1289 lcd;

It wouldn't let me upload the config.h file, so here is what I used:

#ifndef CONFIG_H_INCLUDED
#define CONFIG_H_INCLUDED

/**************************************
* OBD-II Adapter options
**************************************/
#define OBD_ADAPTER_MODEL OBD_MODEL_I2C
//#define OBD_ADAPTER_MODEL OBD_MODEL_UART
#define OBD_PROTOCOL PROTO_AUTO

/**************************************
* Data logging options
**************************************/
// enable(1)/disable(0) data logging (if SD card is present)
#define ENABLE_DATA_LOG 1
#define SD_CS_PIN SS

/**************************************
* Data streaming options
**************************************/
// enable(1)/disable(0) data streaming
#define ENABLE_DATA_OUT 1

// uses software(1)/hardware(0) serial for data streaming
#define USE_SOFTSERIAL 0

// this defines the format of data streaming
// FORMAT_BIN is required by Freematics OBD iOS App
// FORMAT_CSV is for text-based output
#define STREAM_FORMAT FORMAT_BIN

/* Default streaming baudrates:
9600bps for BLE
38400bps for BT 2.1
*/
#define STREAM_BAUDRATE 9600

/**************************************
* GPS configuration
**************************************/
#define USE_GPS 1
#define GPSUART Serial2
#define MAX_GPS_PROCESS_TIME 50 /* ms */
#define GPS_DATA_TIMEOUT 2000 /* ms */

// 38400bps for G6010 5Hz GPS receiver
// 115200bps for G7020 10Hz GPS receiver
#define GPS_BAUDRATE 115200 /* bps */

/**************************************
* Accelerometer & Gyro
**************************************/
#define USE_MPU6050 1
//#define USE_MPU9150 1
#define ACC_DATA_RATIO 160
#define GYRO_DATA_RATIO 256
#define COMPASS_DATA_RATIO 8

/**************************************
* Timeout/interval options
**************************************/
#define OBD_MIN_INTERVAL 20 /* ms */
#define ACC_DATA_INTERVAL 200 /* ms */

/**************************************
* LCD module (uncomment only one)
**************************************/
LCD_SSD1289 lcd; /* 3.2" SSD12389 based TFT LCD */
//LCD_ILI9325D lcd; /* 2.8" ILI9325 based TFT LCD */
//LCD_ILI9341 lcd; /* 2.4" ILI9341 based SPI TFT LCD */
//LCD_Null lcd;

#endif


Here is the result:

050915Firmware Results
050915Firmware Results
050915 Firmware.jpg (36.36 KiB) Viewed 22822 times


I tried selecting USE_MPU9150 as well and had the same result.

It compiled and uploaded with no issues. Arduino 1.6.6 to the original Mega2560.

Thanks again for the help.
Tux4Pres.
Syl
Posts: 8
Joined: Fri Sep 18, 2015 12:30 am

Re: Megalogger issue with Kit#3

Post by Syl »

Hm, bad news. What you did look pretty korrekt to me. Only can think of an hardware failure. The lcd shield is pushed all the way in? Ther should be no space between the black connetcor parts.

What you can try is to connect this setup to your car. If the screen changes after a few moments the programm runs correct and ther is only a problem with the lcd output.

Did you make an backup of the pre installed firmeware?
tux4pres
Posts: 10
Joined: Wed Nov 11, 2015 1:53 pm

Re: Megalogger issue with Kit#3

Post by tux4pres »

Syl,

There is a bluetooth board on the underside of the megalogger shield. On the underside of that bluetooth board is an exposed maze of traces that seems to line up with the mega's USB socket's metal exterior. I assume these are grounds and that the bluetooth board is grounded via its connection with the megalogger shield, but those are just my assumptions. When the megalogger shield is fully seated, the bluetooth board's exposed traces either touch or almost touch the USB socket. I can take a picture of this when I get home. I don't remember how it was when I first booted it as I didn't notice the bluetooth board until after I tried it on another mega. Since then, I have tried it with the megalogger shield fully seated and slightly lifed(but still connected to the mega) so the bluetooth board wasn't touching the USB socket. No combination has changed the functionality.

Unfortunately I did not back up the shipped firmware. I really wish I would have though.

I will try again tonight making sure the megalogger shield is seated firmly and that there are no gaps.

Thank you for your help and your speedy responses.
Tux4Pres.
tux4pres
Posts: 10
Joined: Wed Nov 11, 2015 1:53 pm

Re: Megalogger issue with Kit#3

Post by tux4pres »

Here are the pictures of what I described in the above post.

There is a little pin showing, but they seem to seat well in the mega. The slight pin gap seems to be due to the 3.3/5V switch running into the power barrel jack on the mega. Like I said, the pins seem to seat well. It's tough to push the shield down on the mega.
Seated pins USB side:
Seated pins on the USB side.
Seated pins on the USB side.
SeatedPinsUSBSide.jpeg (72.05 KiB) Viewed 22808 times


Seated pins Power side:
Seated pins on the power side.
Seated pins on the power side.
SeatedPinsPowerSide.jpg (37.71 KiB) Viewed 22808 times


Where the Bluetooth board meets the USB socket:
Where the bluetooth board meets the USB socket.
Where the bluetooth board meets the USB socket.
BluetoothMeetsUSB.jpeg (64.84 KiB) Viewed 22808 times


I will continue in the next post. I have run into the image limit on this post.

Tux4pres.
tux4pres
Posts: 10
Joined: Wed Nov 11, 2015 1:53 pm

Re: Megalogger issue with Kit#3

Post by tux4pres »

Where the voltage switch meets the power jack(I just tried switching to 3.3V vs 5V and the results didn't change):
Where the voltage switch meets the power jack.
Where the voltage switch meets the power jack.
VoltageSwitchMeetsPower.jpeg (73.32 KiB) Viewed 22808 times


Closeup of the Bluetooth board's exposed traces:
Closeup of the Bluetooth board's exposed traces.
Closeup of the Bluetooth board's exposed traces.
BluetoothBoardClose.jpeg (105.54 KiB) Viewed 22808 times


I appreciate all of the help. This is such a cool platform and I love that it is open source. I just want mine to get mine to be as cool as it was designed.

Tux4Pres.
Fearias
Posts: 2
Joined: Sat Nov 14, 2015 3:09 pm

Re: Megalogger issue with Kit#3

Post by Fearias »

I'm having the same problem, any solution?

Update: I tried the simple sample that is here: http://arduinodev.com/software/multilcd/ , deleted my instalation of the UTFT library so it will use the files supplied with the Megalogger code and the display works perfect, this is my code:

#include <SPI.h>
#include <memorysaver.h>

#include <MultiLCD.h>

LCD_SSD1289 lcd; /* 3.2" SSD12389 based TFT LCD */

static const PROGMEM uint8_t smile[48 * 48 / 8] = {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3F,0x3F,0x1F,0x0F,0x87,0xC7,0xE1,0xF0,0xF8,0xFC,0xFF,0xFF,0xFF,0x7F,0x3F,0x0F,0x03,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x03,0x07,0x0F,0x1F,0x1F,0x3F,0x3F,0x7F,0x7F,0x7E,0xFE,0xFE,0xFC,0xFC,0xFC,0xFC,0xFC,0xFC,0xFC,0xFC,0xFC,0xFC,0xFE,0xFE,0x7E,0x7F,0x7F,0x3F,0x3F,0x1F,0x1F,0x0F,0x07,0x03,0x01,0x00,0x00,0x00,0x00,0x00,0x00,
};

void setup()
{


lcd.begin();
lcd.clear();
lcd.drawHLine(0,100,200);

lcd.setColor(RGB16_CYAN);
lcd.setFontSize(FONT_SIZE_SMALL);

lcd.setColor(RGB16_WHITE);
lcd.setCursor(60, 8);
lcd.print(" GPS ");
}

void loop()
{

lcd.clear();
lcd.draw(smile, 48, 48);
delay(2000);

lcd.clear();
lcd.setCursor(0, 0);
lcd.setFontSize(FONT_SIZE_SMALL);
lcd.print("Hello, world!");

lcd.setCursor(0, 1);
lcd.setFontSize(FONT_SIZE_MEDIUM);
lcd.print("Hello, world!");

lcd.setCursor(0, 3);
lcd.setFontSize(FONT_SIZE_SMALL);
lcd.printLong(12345678);

lcd.setCursor(64, 3);
lcd.setFontSize(FONT_SIZE_MEDIUM);
lcd.printLong(12345678);

lcd.setCursor(0, 4);
lcd.setFontSize(FONT_SIZE_LARGE);
lcd.printLong(12345678);

lcd.setCursor(0, 6);
lcd.setFontSize(FONT_SIZE_XLARGE);
lcd.printLong(12345678);

delay(3000);
}


If I recompiled the Megalogger code and upload it, the same screen that was show before (with the misplaced characters and missing texts) is displayed, I think there may be some problem with the code, (or local configuration, I will try installing everything from scratch in an other computer), but at least I'm almost sure that the hardware is working (my biggest concern). I will try to recreate the project and post here any updated result...
Fearias
Posts: 2
Joined: Sat Nov 14, 2015 3:09 pm

Re: Megalogger issue with Kit#3

Post by Fearias »

I found the problem.

The compiler is making a cache of the libraries, as I installed the UTFT and other libraries AFTER I installed the megalogger libraries, when the program was compiled, the new libraries caused some conflict, causing that the display of text with the function "lcd.print" only showed the first character in the string, however, the "lcd.printLong" function (or method) was working correctly.

I removed all the libraries I installed and copied again the ones for the Megalogger.

I installed the plugin of VisualMicro in my computer over my install of Visual Studio Community 2015, open the Megalogger project and used the 'Rebuild' option, not the build, the Rebuild caused a complete rebuild of all cached libraries (some how they were being stored in a cache).

Now the Megalogger is working correclty, I will investigate later why the conflict with the installed libraries. but the problem comes from a problem with the cache of the build libraries.

Hope this works for everybody.

Good luck!!
Post Reply