您好,欢迎访问三七文档
当前位置:首页 > 电子/通信 > 综合/其它 > Bluetooth-HFP
HANDS-FREEPROFILEProtocolStackRoles•AudioGateway(AG)Devicethatisthegatewayoftheaudio,bothforinputandoutput.TypicaldevicesactingasAudioGatewaysarecellularphones.•Hands-Freeunit(HF)DeviceactingastheAudioGatewayremoteaudioinputandoutputmechanism.Italsoprovidessomeremotecontrolmeans.FeaturesConnections•SLC(Servicelevelconnection)Baseontransportchannel(Rfcomm),usedtotransfercommandsandresultcodeswhichareusedforremotecontrol.•SCOBaseonHCI(softwareimplemention)orChipdirectly.WhichisusedfortransferPCMaudiodata.Notes:InAndroidplatform,ScoSocketisusedforSCOcontrolconnectionestablishanddisconnect.Notusedtransferaudiodata.ATCommand&ResultCode•TheformatofanATcommandfromtheHFtotheAGshallbe:ATcommandcr•TheformatoftheOKcodefromtheAGtotheHFshallbe:crlfOKcrlf•TheformatofthegenericERRORcodefromtheAGtotheHFshallbe:crlfERRORcrlf•TheformatofanunsolicitedresultcodefromtheAGtotheHFshallbe:crlfresultcodecrlfnotes:cr[13]lf[10]Examples:ATD+8613146815263\r/*Dailanumber*/ATA\r/*Answeracall*/\r\nok\r\n\r\n+CIEV:3,1\r\n/*Incomingcall*/ATcommandcategory•Basiccommands:ATA•Actioncommands:“AT+CHUP”•ReadCommands:“AT+CIND?”•Setcommands:“AT+CMEE=1”•Testcommands:“AT+CIND=?”SLCestablishmentAnsweranincomingcallPlaceACallFromHFThreeWayCallingServices•HFServicerecord•AGServicerecordScoorSLCconnectionmaybainitiatefromanyside.Asusual,SCOconnectioninitiatefromAGside.CodeDistribution•packages/apps/Phone/src/com/android/phone/BluetoothAtPhonebook.javaBluetoothHandsfree.javaBluetoothHandsfree.java•frameworks/base/core/java/android/bluetooth/AtCommandHandler.javaAtCommandResult.javaAtParser.javaBluetoothHeadset.javaHeadsetBase.javaIbluetoothHeadset.aidlScoSocket.java
本文标题:Bluetooth-HFP
链接地址:https://www.777doc.com/doc-5290108 .html