-
Notifications
You must be signed in to change notification settings - Fork 15
[Question] Usage #2
Comments
First you have to get the encryption key from Vanmoof. The WebService is used for this (https://github.com/Poket-Jony/vanbike-lib/blob/main/example/index.html#L33). |
hi, i got my encryption key but the bluetooth does not seem to work i get: Uncaught (in promise) Error: Bluetooth driver not available the WebBluetooth samples from the google site workt though! any tipps? |
okay the problem was that SSL HAS to be activated otherwise web bluetooth will not work o_O |
Thanks for testing. The S3 has different service IDs and was therefore not displayed. I've already started expanding the S3 profile, but there is still a lot of work to be done. See eb93d61 |
ok let me know if you need a s3 to test, i live in berlin and i am a coder as well :) |
i tried your change.
|
The service IDs and characteristics are from the Vanmoof app. I guess that some primary services have to be specified as optional services. The best thing is to simply specify the security service in the "createBluetoothConfigEntity()" method (eb93d61#diff-c7f977ef208700181a5281c121bad51434fd86db96f26c6a6045e646c40e09aaR69) and see whether it is then displayed. The primary services act as filters for the Bluetooth devices. |
ok i read a little bit how things work ( i never did anything with bluetooth before) BluetoothService.js:123 Uncaught (in promise) Error: Characteristic "6acc5502-e631-4069-944d-b8ca7598ad50" not found! this is part of the security service. my conclusion is the security service uuid must be wrong. |
ok i found one problem, u try to discover all services and swallow all errors, so i put in some more logging while discovering and id get this: BluetoothService.js:52 try service 6acc5500-e631-4069-944d-b8ca7598ad50 thats why its does not end up in _servicesAndCharacteristics[] |
ok now i defined everything as optional except the bike info service and apparently u have to do this in the beginng even though the method that fetches it later is called "getPrimaryService" o_O now i get BluetoothService.js:131 Uncaught (in promise) TypeError: Cannot convert undefined or null to object because the command is undefined in profile createAuthenticateCommandEntity(passcode) { |
With the S1, some services also had to be defined as optional. In commit cf7981f I think that the problem with the undefined command should be fixed. |
Great project. Very interested. I have S3 and also can help with testing or contributing. Let me know if I can help. |
ok i created a pull request, but even with your changes authentication does not seem to work, it does no throw any error but eventually the bikes disconnectes me and i cannot send any commands - btw i also never see a "connected" dot in the bike hmmm i can see that he reads the challenge key correctly (2 bytes) and sets no command but sets the data and encrypts it, after writing that bike disconnects... any idea what wrong with authentication? i do not have the source code of the offical app ;) |
Thanks retroactive, I also got an S3 I merged your pull request in my repository, no errors now, but also no connect. :-( |
unfortunately i only fixed the obvious errors, why the connect does not work only poket-joney can answer, or someone finds the source code? im not used to disassemble ios/android apps. |
I have it decompiled it's easy with apktool but the Service ID's in it are the same that you use. |
I made my email adress visible, write me a note if you want to have a look by your self |
are u still looking into it? did u find how to authenticate? you can send me the code or contact me at ******** |
Hi,
I like the idea. Could you give a bit more detailed info how to run the code?
I tried the example in chrome and all the requested configs, but without succes
The text was updated successfully, but these errors were encountered: