DeanCording / owonb35

Bluetooth Client for Owon B35 Multimeter
MIT License
31 stars 5 forks source link

Version of gattlib #1

Open aliale09 opened 4 years ago

aliale09 commented 4 years ago

Dear Mr. DeanCording, I am sorry, I couldn't find your email using git. So I am writing this issue with a hope for your help with compiling of owonb32 client under Xubuntu 18.04.03. It's not possible to compile the client. As I could see from the gcc log, the problem is in wrong version of gattlib I have in the system. There is no specific information about the version you used. Would you be so kind to specify it? I have compiled the library to work with Bluez 5.49.

The client compilation errors are likes this: owonb35.c:575:71: note: each undeclared identifier is reported only once for each function it appears in owonb35.c:575:22: error: too many arguments to function ‘gattlib_connect’ connection = gattlib_connect(NULL, address, BDADDR_LE_PUBLIC, BT_SEC_LOW, 0, 0); ^~~~~~~ In file included from owonb35.c:38:0: /usr/local/include/gattlib.h:276:20: note: declared here gatt_connection_t gattlib_connect(const char src, const char *dst, unsigned long options);

DeanCording commented 4 years ago

Thank you for contacting me about this.

It appears that the GattLib library has been updated recently to support Bluez DBUS.

I would suggest trying GattLib v0.2 release https://github.com/labapart/gattlib/releases/ tag/v0.2

Let me know how it works and if there is still a problem, I can look at over the next few days.

Cheers,

Dean

On Thursday, 3 October 2019 07:53:28 AEST aliale09 wrote:

Dear Mr. DeanCording,I am sorry, I couldn't find your email using git.So I am writing this issue with a hope for your help with compiling of owonb32 client under Xubuntu 18.04.03. It's not possible to compile the client. As I could see from the gcc log, the problem is in wrong version of gattlib I have in the system. There is no specific information about the version you used.Would you be so kind to specify it?I have compiled the library to work with Bluez 5.49. The client compilation errors are likes this:owonb35.c:575:71: note: each undeclared identifier is reported only once for each function it appears in owonb35.c:575:22: error: too many arguments to function ‘gattlib_connect’connection = gattlib_connect(NULL, address, BDADDR_LE_PUBLIC, BT_SEC_LOW, 0, 0);^~~~~~~In file included from owonb35.c:38:0:/usr/local/include/gattlib.h:276:20: note: declared heregatt_connection_t gattlib_connect(const char src, const char *dst, unsigned long options); —You are receiving this because you are subscribed to this thread.Reply to this email directly, view it on GitHub[1], or mute the thread[2].[3]


[1] https://github.com/DeanCording/owonb35/issues/1? email_source=notifications&email_token=AAB5KIUCDIXM4BANZBNKT7DQMUJ5RA5CNFSM 4I434SA2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HPIBK7Q [2] https://github.com/notifications/unsubscribe-auth/ AAB5KIQN3FBUXLIG3WORPGLQMUJ5RANCNFSM4I434SAQ [3] https://github.com/notifications/beacon/ AAB5KISQG3OOZWZWHYZQGL3QMUJ5RA5CNFSM4I434SA2YY3PNVWWK3TUL52HS4DFUV EXG43VMWVGG33NNVSW45C7NFSM4HPIBK7Q.gif

aliale09 commented 4 years ago

Hi

Thanks for replying me. Unfortunately, there is another problem under my home Ubuntu 18.04. When I try to compile libgattool v0.2, it complains: No such file or directory

include <bluetooth/uuid.h>

And there is no such file as "requirements.dep" in the latest gattlib-master folder:

libbluetooth3 libbluetooth-dev libglib2.0-dev python3-dev libpython3-dev

I suppose, libgattool v0.2 uses libbluetooth2, and I should install corresponding libbluetooth-dev. It might be a problem to go back to its previous version for the system.

So I will try to compile everything at PC on my workplace, where Ubuntu 16.04 actually needs to become connected with the Owon 35 multimeter.

With best regards and hopes, Alevanau, Aliaksandr

On 2019-10-03 00:32, Dean Cording wrote:

Thank you for contacting me about this.

It appears that the GattLib library has been updated recently to support Bluez DBUS.

I would suggest trying GattLib v0.2 release https://github.com/labapart/gattlib/releases/ tag/v0.2

Let me know how it works and if there is still a problem, I can look at over the next few days.

Cheers,

Dean

On Thursday, 3 October 2019 07:53:28 AEST aliale09 wrote:

Dear Mr. DeanCording,I am sorry, I couldn't find your email using git.So I am writing this issue with a hope for your help with compiling of owonb32 client under Xubuntu 18.04.03. It's not possible to compile the client. As I could see from the gcc log, the problem is in wrong version of gattlib I have in the system. There is no specific information about the version you used.Would you be so kind to specify it?I have compiled the library to work with Bluez 5.49. The client compilation errors are likes this:owonb35.c:575:71: note: each undeclared identifier is reported only once for each function it appears in owonb35.c:575:22: error: too many arguments to function ‘gattlib_connect’connection = gattlib_connect(NULL, address, BDADDR_LE_PUBLIC, BT_SEC_LOW, 0, 0);^~~~~~~In file included from owonb35.c:38:0:/usr/local/include/gattlib.h:276:20: note: declared heregatt_connection_t gattlib_connect(const char src, const char *dst, unsigned long options); —You are receiving this because you are subscribed to this thread.Reply to this email directly, view it on GitHub[1], or mute the thread[2].[3]


[1] https://github.com/DeanCording/owonb35/issues/1? email_source=notifications&email_token=AAB5KIUCDIXM4BANZBNKT7DQMUJ5RA5CNFSM 4I434SA2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HPIBK7Q [2] https://github.com/notifications/unsubscribe-auth/ AAB5KIQN3FBUXLIG3WORPGLQMUJ5RANCNFSM4I434SAQ [3] https://github.com/notifications/beacon/ AAB5KISQG3OOZWZWHYZQGL3QMUJ5RA5CNFSM4I434SA2YY3PNVWWK3TUL52HS4DFUV EXG43VMWVGG33NNVSW45C7NFSM4HPIBK7Q.gif

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/DeanCording/owonb35/issues/1?email_source=notifications&email_token=ANL7DT7G3OM4SOCCZTFDHKLQMUOPLA5CNFSM4I434SA2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEAGMUMA#issuecomment-537709104, or mute the thread https://github.com/notifications/unsubscribe-auth/ANL7DT6ZZAPR2GP5ZRO6JNTQMUOPLANCNFSM4I434SAQ.

DeanCording commented 4 years ago

There are precompiled versions of Gatlib that you can install without needing to compile it. They are linked to on the Gatlib GitHub page.

On Thursday, 3 October 2019 19:52:08 AEST aliale09 wrote:

Hi

Thanks for replying me.Unfortunately, there is another problem under my home Ubuntu 18.04.When I try to compile libgattool v0.2, it complains:No such file or directory#include <bluetooth/uuid.h>

And there is no such file as "requirements.dep" in the latest gattlib-master folder:

libbluetooth3libbluetooth-devlibglib2.0-devpython3-devlibpython3-dev

I suppose, libgattool v0.2 uses libbluetooth2, and I should install corresponding libbluetooth-dev.It might be a problem to go back to its previous version for the system.

So I will try to compile everything at PC on my workplace, where Ubuntu 16.04 actually needs to become connected with the Owon 35 multimeter.

With best regards and hopes,Alevanau, Aliaksandr

On 2019-10-03 00:32, Dean Cording wrote:> Thank you for contacting me about this.>> It appears that the GattLib library has been updated recently to > support Bluez DBUS.>> I would suggest trying GattLib v0.2 release > https://github.com/labapart/gattlib/releases/> tag/v0.2>> Let me know how it works and if there is still a problem, I can look > at over the next few> days.>>> Cheers,>> Dean>> On Thursday, 3 October 2019 07:53:28 AEST aliale09 wrote:>>> Dear Mr. DeanCording,I am sorry, I couldn't find your email using > git.So I am writing this> issue with a hope for your help with compiling of owonb32 client under > Xubuntu 18.04.03.> It's not possible to compile the client. As I could see from the gcc > log, the problem is in> wrong version of gattlib I have in the system. There is no specific > information about the> version you used.Would you be so kind to specify it?I have compiled > the library to work> with Bluez 5.49.> The client compilation errors are likes this:owonb35.c:575:71: note: > each undeclared> identifier is reported only once for each function it appears in > owonb35.c:575:22: error:> too many arguments to function ‘gattlib_connect’connection = > gattlib_connect(NULL,> address, BDADDR_LE_PUBLIC, BT_SEC_LOW, 0, 0);^~~~~~~In file > included from> owonb35.c:38:0:/usr/local/ include/gattlib.h:276:20: note: declared > heregatt_connection_t> gattlib_connect(const char src, const char *dst, unsigned long > options);> —You are receiving this because you are subscribed to this > thread.Reply to this email> directly, view it on GitHub[1], or mute the thread[2].[3]>>>> --------> [1] https://github.com/DeanCording/owonb35/issues/1?> email_source=notifications&email_token=AAB5KIUCDIXM4BANZBNKT7DQMUJ5RA5CNFSM

4I434SA2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HPIBK7Q> [2] https://github.com/notifications/unsubscribe-auth/> AAB5KIQN3FBUXLIG3WORPGLQMUJ5RANCNFSM4I434SAQ> [3] https://github.com/ notifications/beacon/> AAB5KISQG3OOZWZWHYZQGL3QMUJ5RA5CNFSM4I434SA2YY3PNVWWK3TUL52HS4DFUV EXG43VMWVGG33NNVSW45C7NFSM4HPIBK7Q.gif>> —> You are receiving this because you authored the thread.> Reply to this email directly, view it on GitHub > https:// github.com/DeanCording/owonb35/issues/1? email_source=notifications&email_token=ANL7DT7G3OM4SOCCZTFDHKLQMUOPLA5CNFS M4I434SA2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPW SZGOEAGMUMA#issuecomment-537709104, > or mute the thread > https://github.com/ notifications/unsubscribe-auth/ ANL7DT6ZZAPR2GP5ZRO6JNTQMUOPLANCNFSM4I434SAQ.>

—You are receiving this because you commented.Reply to this email directly, view it on GitHub[1], or mute the thread[2].[3]


[1] https://github.com/DeanCording/owonb35/issues/1? email_source=notifications&email_token=AAB5KIRMJZS7LYFZEXGN2ODQMW6ERA5CNFSM 4I434SA2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZ GOEAHU6ZY#issuecomment-537874279 [2] https://github.com/notifications/unsubscribe-auth/ AAB5KITW4FV3U7HCDGBPITTQMW6ERANCNFSM4I434SAQ [3] https://github.com/notifications/beacon/ AAB5KIUNZFQGFJTLVSNDPF3QMW6ERA5CNFSM4I434SA2YY3PNVWWK3TUL52HS4DFVREX G43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEAHU6ZY.gif

aliale09 commented 4 years ago

Hi again, Dean

Thanks for your advice. I did as you said, just installed latest gattlib with legacy Bluez support and downloaded binary owonb35 client. It works, but periodically prints out together with readings:

Unrecognized packet: 1a f0 04 00 07 00 1a f0 04 00 07 00

Maybe it's because of a new version of these multimeters, I don't know. However, multimeterBLE APP under Android works with it well. Would you be so kind to tell me what is this about? May this unrecognized packed appear because of Bluetooth adapter, or it is sent by the meter itself? I have purchased it from: https://sagitta.se/artikel.php?kid=111-141&sok=&id=3969&sort=