Using clone ELM327 Bluetooth OBDII adapter with Leaf

My Nissan Leaf Forum

Help Support My Nissan Leaf Forum:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.
Jim,
Is your battery app no longer available?

I downloaded it about 10 minutes ago on one tablet,
but now the download fails on the 3rd tablet.

Since the App installs as "battery", you might want to call it
LEAF-Batt-1 or some such if you update it.

Thanks, Gary
 
Bassman said:
Will try it with my Evo 3D running Android 4.0.3 and my ELM327.

Connected the first time, but didn't show capacity numbers or percentage. After the first connection, failed to connect, kept giving a connected failed error in a black text box, even when the ELM327 wasn't on and even after uninstalling the battery app and re-installing it. The error keeps flashing on my phone when I try to run the app.
 
Downloaded and running without a hitch (and without bluetooth) on my LG Optimus Elite Virgin Mobile android phone.
Waiting for my cheap ELM327 clone to arrive from Amazon by tomorrow.
 
New version available on the same page (6) as the old one.

This one will retry the EV-CAN commands until it gets a response. New status of "Connected - Waiting" (Yellow) means that Bluetooth has connected to the ELM327 but the Leaf is not responding to the pack request commands.

Tested by sitting in the Leaf with car off. Start program and it connects to the ELM327 and messages changes to "Connected - Waiting" (Yellow). Press Leaf Power button twice to get to "ready" state and message changes to "Connected" (Green)

Anytime a response is overdue the status message will switch back to "Connected - Waiting" and when the timer hits 2 it will retry the request. So you may see it cycle even after you get it working depending on CAN traffic.

Also shorten retry timer.
 
garygid said:
It would help to post some links to sources that
have proven to sell ELM327 devices that work well.
Thanks

I posted a link to mine a few pages back. Here it is:

http://www.amazon.com/gp/product/B009F4JHHO/ref=oh_details_o00_s00_i00?ie=UTF8&psc=1" onclick="window.open(this.href);return false;

Works well, so far.
 
On one of my 3 Android tablets, the Leaf Battery app complains that the
MACADR table is not found in some sql database. If I say continue it
complains of a null pointer, but then displays the data bars, but ALL
the values are 4.000 with no one higher and one lower value.

Perhaps this error will go away after I pair the tablet with an ELM327 device?

I will try and update here.
 
I have one of the cheap Chinese ELM327 modules purchased for next to nothing off of Ebay. It has no serial number or mac address on the label on the outside. As others have mentioned, it doesn't work well at all, perhaps one time out of 3. I noticed before I installed Turbo3's app that I was having problems. I was able to get CP voltages once using the commands shown in the first post of this thread using the elm327 terminal app, but just the one time. Usually I would get "Can Error" when I issued the final command after that. I was thinking about buying one of the larger modules so I can rewire it to the EV can bus.
 
I have a clone and a "real" mini (body about 3/4" high) ELM327.

The ones that have a body about twice that long...
some appear to have a seam in the body about half-way
down the body. However, all of these longer-body devices
are clones, I believe, and most of these are no longer
labeled with the word "ELM327".

I think that the clones have not cloned the ELM327 chip,
but simulated its function with a small uP. Presumably,
the clone's performance depends upon how well their
firmware does the job.

Getting any of these open down at the point where
one can modify the two connections to the CAN bus
appears to be... difficult.

In the first post of this thread, Turbo3 posted a photo
of a device with a slightly larger case (call it a 3x case,
about 3 times the length of the mini body), where the label
covered 4 screw holes. That might be the better type
to try, in spite of its extra body length.
 
I bought this one:
http://www.amazon.com/AGPtek%C2%AE-Bluetooth-CAN-BUS-Diagnostic-Scanner/dp/B008U1MOM8/ref=pd_sim_auto_2" onclick="window.open(this.href);return false;

It has worked flawlessly, and seems to have a unique MAC address. The case would be very difficult to open.

The new app works very nicely. I had noticed that if you left the app running while driving, the old app would eventually lock up and stop updating. it would take a stop/restart to get it going. Sometimes you would even have to force stop it. No more. This one handles it by going into the "connected waiting" state for a sec, then back to connected without fuss. It also smoothly handled the sequence where I started the app, then plugged in the adapter, then turned the car on. The only buglet I saw was that the app didn't notice when I unplugged the adapter. It seemed to stay connected, although I only waited a minute or so before hitting stop. Perhaps if I had waited longer it would have timed out.
 
The program saves the mac address in a database in a folder named BT_CAN which should have two files in it. One called btcan.db size 32kb and the other btcan.db-journal size 0. I have not touched this code so it may need additional error handling or I may make a special version without it.

For those having trouble with null pointer please use File Manager to look for that folder and files. If you have an SD card look there otherwise look in Local. It will be a top level folder.

Also if you get an error and it has a Java line number please post the error message and line number.

For those getting this error, have you blocked the app from accessing storage?

PM me if you have bought an OBDII Bluetooth adapter that does not work and are willing to loan it to me. I would like to verify if there really are "bad" ones. I have had no problems with the two cheap ones I bought and I have a third one coming soon.
 
davewill said:
I bought this one:
http://www.amazon.com/AGPtek%C2%AE-Bluetooth-CAN-BUS-Diagnostic-Scanner/dp/B008U1MOM8/ref=pd_sim_auto_2" onclick="window.open(this.href);return false;
It has worked flawlessly, and seems to have a unique MAC address. The case would be very difficult to open.

The new app works very nicely. I had noticed that if you left the app running while driving, the old app would eventually lock up and stop updating. it would take a stop/restart to get it going. Sometimes you would even have to force stop it. No more. This one handles it by going into the "connected waiting" state for a sec, then back to connected without fuss. It also smoothly handled the sequence where I started the app, then plugged in the adapter, then turned the car on. The only buglet I saw was that the app didn't notice when I unplugged the adapter. It seemed to stay connected, although I only waited a minute or so before hitting stop. Perhaps if I had waited longer it would have timed out.

After about a minute or more andriod will report back to my program that the Bluetooth link is down. Until then the program has no way to know there is a problem. When this happens the message will switch back to the Red "Not Connected". I tried adding code to go back to the auto connect mode but have not gotten it to work. Just press the Start button and select OBDII device to try to reconnect.

When people do have problems it is important to either use the Stop button to kill the program or if you get the fails to respond message from android select Force Close. Otherwise the program is just paused and then restarted when you think you are starting it again. It is not like Windows. The operation system normally decides when to kill a program after you switch away from it. So use the Stop button.

Of course, if the program is working fine for you you can use this feature to go back and look at the cp chart at a later time since it is still in memory just paused. Just hold down the Home button and reselect the app.
 
Turbo3 said:
The program saves the mac address in a database in a folder named BT_CAN which should have two files in it. One called btcan.db size 32kb and the other btcan.db-journal size 0. I have not touched this code so it may need additional error handling or I may make a special version without it.

For those having trouble with null pointer please use File Manager to look for that folder and files. If you have an SD card look there otherwise look in Local. It will be a top level folder.

Also if you get an error and it has a Java line number please post the error message and line number.

For those getting this error, have you blocked the app from accessing storage?
.. .
Line 323 error says table MACADR does not exist.
The BT_CAN folder is there, and the btcan.db file is there, at 40k bytes, not 32.
The... journal first is along there.

Who creates these files, the Android OS as part of the BT pairing?
I could try to delete them to see if the system chokes?

My "genuine" and "clone" mini ELM327 devices both worked intermittently
with the app running on the other two tablets.
 
Gary,
Yes, try deleting the folder with the two files. They are created by this program. It is part of the original code I downloaded using the links you provided.

I am thinking of removing all that code and just replacing it with a simple text file holding the last mac address.
 
Since there were 7 other files there, I just deleted the db and journal files,
and now it starts up just fine. Thanks.

I will try the app again in the car with this tablet.
Some of the iMiEV apps must have created the files without
that table, and "your" app apparently will create the file
if it is misding, but not add the table if a file exists without
the expected table.

Yes, they probably used the db for storing historical data,
so using the db made sense to them?
 
Gary, My clone ELM327's mac is 11:22:33:DD:EE:FF

I have added code to list the mac address on the selection screen.

I changed the folder name to LEAF_BT_CAN but now I see the same "is not a valid Bluetooth address" the first time I start the program up. This means the current code has a bug that I will look into and fix.

Look for a new version later today to fix this startup problem.
 
New version available at the bottom of the first post on page 1. This should make it easier to check for updates (suggested by drees).

Renamed the folder used to save the mac address to LEAF_BT_CAN so it does not conflict with the iMiEV app. Added better code to check if mac address has been initialized to aviod bad mac/null pointer errors. Original code only tested for <>" " but not the null case of "". I check that the mac address is a 17 character string. All devices on the selection list now include their mac address.

Added a new state when no mac address as been selected. Renamed "Start" button to "Select OBDII" and "STOP" button to "EXIT". Fixed problem where program could get stuck in an endless loop.

Please provide module name (Main,scanner,Charts) and Java line number for any errors that popup on the screen.

Since I am using a new folder everyone will need to select their OBDII device again when you first start up the program. After that it should be remembered.

Unless you also are using the iMiEV battery app you can delete the BT_CAN folder and files within.

If you have had trouble in the past give this one a try and report if it now works for you or if there is some improvement.
 
received my blue tooth, connected it, paired using code 1234 with my Android phone (LG Optimus Elite), turned on my Leaf and opened the app.

evrything worked. 97.6% capacity for my 2011 Nissan Leaf I purchase last December. Will charge to 100% and will check again.

Thanks for this low cost battery monitoring.

http://www.amazon.com/gp/product/B0090ZJPMK/ref=oh_details_o01_s00_i00?ie=UTF8&psc=1" onclick="window.open(this.href);return false;
 
If you turn ON the Bluetooth of the Android device when you start up
(that is, you found it OFF and turned it ON), then you might want to
turn it back OFF as you exit the app?

You might want to put a small version number (v3) somewhere on the
screen, so it will be easier for users to describe which version that
they are having problems with.

However, splendid work.
I will test in the car tomorrow, I hope.
Cheers, Gary
 
davewill said:
I bought this one:
http://www.amazon.com/AGPtek%C2%AE-Bluetooth-CAN-BUS-Diagnostic-Scanner/dp/B008U1MOM8/ref=pd_sim_auto_2" onclick="window.open(this.href);return false;

It has worked flawlessly, and seems to have a unique MAC address. The case would be very difficult to open.
Thanks for the feed back. The one I ordered on eBay looks exactly like yours in the pics, but we'll see if it is actually the same or not. If not, I'll just get the one you got.

Some more reading of Amazon reviews had one good one that highlights a subtle difference in the case - the retaining clip on the good one was solid where the bad one had notches cut out. The good one also appeared to have a matte finish rather than clear. We'll see what one I get next week hopefully!
 
Back
Top