有人知道哪种类型的LLCP传输与:
结合使用NPP只是单向的,因此可能因为确认而与面向连接相结合,但我不知道。 SNEP对确认收到的包裹有这样的认可,所以也许它与无连接的LLCP相结合以避免冗余,但我不确定。
我希望你能帮助我, 谢谢!
答案 0 :(得分:0)
我在Google源代码的target.c文件中找到了以下内容:
/*
* Services a LLCP conversation with a BEAM device, such as Android ICS, or
* an NPP device, such as Android GB. First attempts to connect on well known
* SNEP service. If that request is denied, connects to the NPP service by
* name. Once connected, sends the NDEF record via the available protocol.
*
* LLCP is a connection oriented protocol. The state is managed by llcp.c.
* The basic flow is as follows:
* 1) Connect on SNEP service (4)
* 2) If fails, connect on NPP service by name
* 3) Once connected, send payload via SNEP or NPP
* 4) If SNEP, wait for acknowledgment (NPP does not ackonwledge)
* 5) Disconnect
*
* Arguments:
* resp - Buffer to be reused to receive LLCP commands
* resp_len - Size of resp in bytes
* ndef - Data to send to peer, e.g. a NDEF record
* ndef_len - Length of payload in bytes
*
* Returns:
* true if all data was passed to peer, false on error or timeout
*/
答案 1 :(得分:0)
NPP和SNEP都使用面向连接的LLCP通道