GithubHelp home page GithubHelp logo

Comments (4)

andrzej-kaczmarek avatar andrzej-kaczmarek commented on May 29, 2024 1

ble_hci_sock_init calls should be removed from apps.

ble_transport_ll_init initializes LL side of transport which in case of external controller is a HCI socket so the socket should be initialized there.

from mynewt-nimble.

CW-B-W avatar CW-B-W commented on May 29, 2024 1

Hello @Fanhang32,

I'm only a user of this project, and I only played it with FreeRTOS, therefore the below might not be completely correct.


In mynewt-nimble v1.5.0, the architecture of HCI transport had been modified.
(You may refer to nimble/doc/transport.md for the current architecture.)

When I was migrating my personal project from v1.4.0 to v1.5.0, I found the examples at that time were not compatible with v1.5.0.
For adapting to the v1.5.0 architecture, I opened PR #1597 to resolve the issue.

Is the example you used porting/examples/linux?

As I saw porting/examples/linux has not been maintained for a long time, I think this example might be kinda outdated and need to be adapted to the new HCI transport architecture.

Would it be better if we keep ble_hci_sock_init() in ble_transport_ll_init()

void
ble_transport_ll_init(void)
{
ble_hci_sock_init();
}

and remove ble_hci_sock_init() in the example (porting/examples/linux)?

nimble_port_init();
ble_hci_sock_init();

I think ble_transport_ll_init() is a more upper-level API for users to initialize the controller, while ble_hci_socket_init() may be the platform-specific implementation for ble_transport_ll_init()?

from mynewt-nimble.

Fanhang32 avatar Fanhang32 commented on May 29, 2024 1

@andrzej-kaczmarek @CW-B-W Got it , thanks a lot! I‘ve removed ble_hci_sock_init in example apps in #1670

from mynewt-nimble.

Fanhang32 avatar Fanhang32 commented on May 29, 2024

If it is indeed necessary to do so,i can fix it by remove ble_hci_sock_init from ble_transport_ll_init in ble_hci_socket.c

from mynewt-nimble.

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.