Giter Club home page Giter Club logo

Comments (5)

KingOfBrian avatar KingOfBrian commented on August 28, 2024 2

Oops, sorry about that, I ran the command but it didn't finish. I pushed again and it should be ready now.

from rzbluetooth.

KingOfBrian avatar KingOfBrian commented on August 28, 2024 1

Nice, I haven't noticed that in my testing with a simulation app, and I never had a device that would change it's services.

By design, RZBluetooth doesn't hold on to any Service or Characteristic objects, so none of the state managed by RZBluetooth should need invalidation. It was my assumption that the backing peripheral.services array and service.characteristics arrays would be managed by Core Bluetooth, either by updating the object state, or by removing the modified object from the parent -- The API surface of CBPeripheral just doesn't seem to present another option. With this assumption, RZBluetooth will just re-discover the service or characteristics if removed. The Core Bluetooth documentation is pretty thin here, so if you find any information to the contrary, I'd be very interested!

The delegate is actually implemented, but commented out, so if you don't need to respond to the event and would like to get rid of the log message, I can just uncomment it and route the log the RZBLog. However I think it could be desirable to expose the event for a consumer to respond to if desired. Do you have any opinions on if or how you would like to consume it? Currently, RZPeripheral has a lifecycle (connectionEvent:error:) and delegate (RZBPeripheralConnectionDelegate), which could be expanded to add support for modifyServices:. The change should be pretty trivial, as it's just percolating up some information, but the naming would be a bit off, and I'd want to tread carefully and avoid complicating the API if it's not required.

Thanks for the bug report. I can probably get a few hours on Monday to clean this up.

Brian

from rzbluetooth.

cpatterson-lilly avatar cpatterson-lilly commented on August 28, 2024

I realized (after writing the report) that RZBluetooth doesn't need to do anything in particular, as you said. I think I'm fine with just logging it to silence the warning. I don't need it for anything in my case at any rate. My apps are working fine without it; I just wanted to let you know about the warning.

from rzbluetooth.

KingOfBrian avatar KingOfBrian commented on August 28, 2024

I just pushed up 1.2 that has the fix you pushed up, a few others, and will route this delegate to the log. Thanks for the feedback!

from rzbluetooth.

cpatterson-lilly avatar cpatterson-lilly commented on August 28, 2024

Will you be merging 1.2 to master and updating the podspec?

from rzbluetooth.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.