Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

readDescriptor fails with ReferenceError #4

Closed
sjrcgtek opened this issue Mar 7, 2016 · 1 comment
Closed

readDescriptor fails with ReferenceError #4

sjrcgtek opened this issue Mar 7, 2016 · 1 comment

Comments

@sjrcgtek
Copy link

sjrcgtek commented Mar 7, 2016

Call like this:

device.readDescriptor(MY_UUID,"00002902-0000-1000-8000-00805f9b34fb",app.ui.displayStatus,app.ui.displayStatus)

Fails with ReferenceError: value is not defined.

easyble readDescriptor implementation is passing 'value' to the call to evothings.ble.readDescriptor which appears to be wrong based on other calls to that same function.

@sjrcgtek
Copy link
Author

sjrcgtek commented Mar 7, 2016

Actually, it looks like that call to readDescriptor was copied from a call to writeDescriptor but never changed. The success callback as is does not accept any parameters. I think the call should be:

    evothings.ble.readDescriptor(
        device.deviceHandle,
        descriptor.handle,
        success,
        fail);

When I do that locally, I am able to read descriptors without the reference error.

@ghost ghost closed this as completed in e4ee6eb Mar 8, 2016
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant