CW-B-W commented on issue #1669:
URL: https://github.com/apache/mynewt-nimble/issues/1669#issuecomment-1872598661

   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](https://github.com/apache/mynewt-nimble/blob/master/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 
https://github.com/apache/mynewt-nimble/pull/1597 to resolve the issue.
   
   
   
   Is the example you used 
[porting/examples/linux](https://github.com/apache/mynewt-nimble/blob/master/porting/examples/linux/main.c)?
   
   As I saw 
[porting/examples/linux](https://github.com/apache/mynewt-nimble/blob/master/porting/examples/linux/main.c)
 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()`
   
https://github.com/apache/mynewt-nimble/blob/64067f5168bd4de097b7830a078862a5df95d9a5/nimble/transport/socket/src/ble_hci_socket.c#L836-L841
   
   and the remove `ble_hci_sock_init()` in the example 
(`porting/examples/linux`)?
   
https://github.com/apache/mynewt-nimble/blob/64067f5168bd4de097b7830a078862a5df95d9a5/porting/examples/linux/main.c#L69-L70
   
   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()`?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to