27 Mart 2025'ten itibaren AOSP'yi derlemek ve AOSP'ye katkıda bulunmak için aosp-main
yerine android-latest-release
kullanmanızı öneririz. Daha fazla bilgi için AOSP'de yapılan değişiklikler başlıklı makaleyi inceleyin.
Koleksiyonlar ile düzeninizi koruyun
İçeriği tercihlerinize göre kaydedin ve kategorilere ayırın.
btsock_interface_t Yapı Referansı
#include <
bt_sock.h
>
|
size_t
|
size
|
|
bt_status_t
(*
|
listen
)(
btsock_type_t
type, const char *service_name, const uint8_t *service_uuid, int channel, int *sock_fd, int flags, int callingUid)
|
|
bt_status_t
(*
|
connect
)(const bt_bdaddr_t *bd_addr,
btsock_type_t
type, const uint8_t *uuid, int channel, int *sock_fd, int flags, int callingUid)
|
|
Tanımı,
bt_sock.h
dosyasının
49. satırı
.
bt_status_t
(* connect)(const bt_bdaddr_t *bd_addr,
btsock_type_t
type, const uint8_t *uuid, int channel, int *sock_fd, int flags, int callingUid)
|
Uzak cihazın RFCOMM UUID kanalına bağlanır. Bağlandığında btsock_connect_signal ve kabul edilecek yeni bir soket fd'sinin okunabileceği soket fd'sini döndürür. callingUid, soketi isteyen uygulamanın UID'sidir. Bu, trafik muhasebesi amacıyla kullanılır.
Tanımı,
bt_sock.h
dosyasının
71. satırı
içindedir.
bt_status_t
(* listen)(
btsock_type_t
type, const char *service_name, const uint8_t *service_uuid, int channel, int *sock_fd, int flags, int callingUid)
|
Bir RFCOMM UUID'sini veya kanalını dinleme Uzak bir cihaz bağlandığında btsock_connect_signal işlevinin okunabileceği soket fd değerini döndürür. UUID veya kanal sağlanmazsa bir kanal ayrılır ve bt_sdp'de create_sdp_record(...) işlevine kanal numarası sağlanarak bir hizmet kaydı oluşturulabilir. callingUid, soketi isteyen uygulamanın UID'sidir. Bu, trafik muhasebesi amacıyla kullanılır.
Tanımı,
bt_sock.h
dosyasının
62. satırı
içindedir.
Bu yapının dokümanları aşağıdaki dosyadan oluşturulmuştur:
-
hardware/libhardware/include/hardware/
bt_sock.h
Bu sayfadaki içerik ve kod örnekleri, İçerik Lisansı sayfasında açıklanan lisanslara tabidir. Java ve OpenJDK, Oracle ve/veya satış ortaklarının tescilli ticari markasıdır.
Son güncelleme tarihi: 2025-07-27 UTC.
[[["Anlaması kolay","easyToUnderstand","thumb-up"],["Sorunumu çözdü","solvedMyProblem","thumb-up"],["Diğer","otherUp","thumb-up"]],[["İhtiyacım olan bilgiler yok","missingTheInformationINeed","thumb-down"],["Çok karmaşık / çok fazla adım var","tooComplicatedTooManySteps","thumb-down"],["Güncel değil","outOfDate","thumb-down"],["Çeviri sorunu","translationIssue","thumb-down"],["Örnek veya kod sorunu","samplesCodeIssue","thumb-down"],["Diğer","otherDown","thumb-down"]],["Son güncelleme tarihi: 2025-07-27 UTC."],[],[],null,["# Android Hardware Abstraction Layer: btsock_interface_t Struct Reference\n\nbtsock_interface_t Struct Reference\n===================================\n\n[Data Fields](#pub-attribs) \nbtsock_interface_t Struct Reference \n\n`\n#include \u003c\n`[bt_sock.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h)`\n\u003e\n`\n\n|-------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Data Fields ----------- ||\n| size_t | [size](/reference/hal/structbtsock__interface__t#a854352f53b148adc24983a58a1866d66) |\n| ||\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* | [listen](/reference/hal/structbtsock__interface__t#a9d38d485b8f8af482153e9fda49f1d87) )( [btsock_type_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h) type, const char \\*service_name, const uint8_t \\*service_uuid, int channel, int \\*sock_fd, int flags, int callingUid) |\n| ||\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* | [connect](/reference/hal/structbtsock__interface__t#a3db005809916dd7c595f37b088c4a277) )(const bt_bdaddr_t \\*bd_addr, [btsock_type_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h) type, const uint8_t \\*uuid, int channel, int \\*sock_fd, int flags, int callingUid) |\n| ||\n\n\nDetailed Description\n--------------------\n\n\nDefinition at line\n[49](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h)\nof file\n[bt_sock.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h)\n.\n\nField Documentation\n-------------------\n\n\n|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* connect)(const bt_bdaddr_t \\*bd_addr, [btsock_type_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h) type, const uint8_t \\*uuid, int channel, int \\*sock_fd, int flags, int callingUid) |\n\n\nConnect to a RFCOMM UUID channel of remote device, It returns the socket fd from which the btsock_connect_signal and a new socket fd to be accepted can be read out when connected. The callingUid is the UID of the application which is requesting the socket. This is used for traffic accounting purposes.\n\n\nDefinition at line\n[71](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h)\nof file\n[bt_sock.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h)\n.\n\n|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* listen)( [btsock_type_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h) type, const char \\*service_name, const uint8_t \\*service_uuid, int channel, int \\*sock_fd, int flags, int callingUid) |\n\n\nListen to a RFCOMM UUID or channel. It returns the socket fd from which btsock_connect_signal can be read out when a remote device connected. If neither a UUID nor a channel is provided, a channel will be allocated and a service record can be created providing the channel number to create_sdp_record(...) in bt_sdp. The callingUid is the UID of the application which is requesting the socket. This is used for traffic accounting purposes.\n\n\nDefinition at line\n[62](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h)\nof file\n[bt_sock.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h)\n.\n\n|-------------|\n| size_t size |\n\n\nset to size of this struct\n\n\nDefinition at line\n[51](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h)\nof file\n[bt_sock.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h)\n.\n\n*** ** * ** ***\n\nThe documentation for this struct was generated from the following file:\n\n- hardware/libhardware/include/hardware/ [bt_sock.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sock.h)"]]