- uint8 ATT_ParsePacket(l2capDataEvent_t *pL2capMsg, attPacket_t *pPkt);
-
- uint8 ATT_CompareUUID(const uint8 *pUUID1, uint16 len1, const uint8 *pUUID2, uint16 len2);
-
- uint8 ATT_ConvertUUIDto128(const uint8 *pUUID16, uint8 *pUUID128);
-
- uint8 ATT_ConvertUUIDto16(const uint8 *pUUID128, uint8 *pUUID16);
-
- uint16 ATT_BuildErrorRsp(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseErrorRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildExchangeMTUReq(uint8 *pBuf, uint8 *pMsg);
-
- uint16 ATT_BuildExchangeMTURsp(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseExchangeMTURsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildFindInfoReq(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseFindInfoRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildFindInfoRsp(uint8 *pBuf, uint8 *pMsg);
-
- uint16 ATT_BuildFindByTypeValueReq(uint8 *pBuf, uint8 *pMsg);
-
- uint16 ATT_BuildFindByTypeValueRsp(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseFindByTypeValueRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildReadByTypeReq(uint8 *pBuf, uint8 *pMsg);
-
- uint16 ATT_BuildReadByTypeRsp(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseReadByTypeRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildReadReq(uint8 *pBuf, uint8 *pMsg);
-
- uint16 ATT_BuildReadRsp(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseReadRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildReadBlobReq(uint8 *pBuf, uint8 *pMsg);
-
- uint16 ATT_BuildReadBlobRsp(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseReadBlobRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildReadMultiReq(uint8 *pBuf, uint8 *pMsg);
-
- uint16 ATT_BuildReadMultiRsp(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseReadMultiRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildReadByGrpTypeRsp(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseReadByGrpTypeRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildWriteReq(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseWriteRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildPrepareWriteReq(uint8 *pBuf, uint8 *pMsg);
-
- uint16 ATT_BuildPrepareWriteRsp(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParsePrepareWriteRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildExecuteWriteReq(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseExecuteWriteRsp(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- uint16 ATT_BuildHandleValueInd(uint8 *pBuf, uint8 *pMsg);
-
- bStatus_t ATT_ParseHandleValueInd(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParseExchangeMTUReq(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParseFindInfoReq(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParseFindByTypeValueReq(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParseReadByTypeReq(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParseReadReq(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParseReadBlobReq(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParseReadMultiReq(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParseWriteReq(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParseExecuteWriteReq(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParsePrepareWriteReq(uint8 sig, uint8 cmd, uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ParseHandleValueCfm(uint8 *pParams, uint16 len, attMsg_t *pMsg);
-
- bStatus_t ATT_ExchangeMTUReq(uint16 connHandle, attExchangeMTUReq_t *pReq);
-
- bStatus_t ATT_FindInfoReq(uint16 connHandle, attFindInfoReq_t *pReq);
-
- bStatus_t ATT_FindByTypeValueReq(uint16 connHandle, attFindByTypeValueReq_t *pReq);
-
- bStatus_t ATT_ReadByTypeReq(uint16 connHandle, attReadByTypeReq_t *pReq);
-
- bStatus_t ATT_ReadReq(uint16 connHandle, attReadReq_t *pReq);
-
- bStatus_t ATT_ReadBlobReq(uint16 connHandle, attReadBlobReq_t *pReq);
-
- bStatus_t ATT_ReadMultiReq(uint16 connHandle, attReadMultiReq_t *pReq);
-
- bStatus_t ATT_ReadByGrpTypeReq(uint16 connHandle, attReadByGrpTypeReq_t *pReq);
-
- bStatus_t ATT_WriteReq(uint16 connHandle, attWriteReq_t *pReq);
-
- bStatus_t ATT_PrepareWriteReq(uint16 connHandle, attPrepareWriteReq_t *pReq);
-
- bStatus_t ATT_ExecuteWriteReq(uint16 connHandle, attExecuteWriteReq_t *pReq);
-
- bStatus_t ATT_HandleValueCfm(uint16 connHandle);
-
- bStatus_t ATT_ErrorRsp(uint16 connHandle, attErrorRsp_t *pRsp);
-
- bStatus_t ATT_ExchangeMTURsp(uint16 connHandle, attExchangeMTURsp_t *pRsp);
-
- bStatus_t ATT_FindInfoRsp(uint16 connHandle, attFindInfoRsp_t *pRsp);
-
- bStatus_t ATT_FindByTypeValueRsp(uint16 connHandle, attFindByTypeValueRsp_t *pRsp);
-
- bStatus_t ATT_ReadByTypeRsp(uint16 connHandle, attReadByTypeRsp_t *pRsp);
-
- bStatus_t ATT_ReadRsp(uint16 connHandle, attReadRsp_t *pRsp);
-
- bStatus_t ATT_ReadBlobRsp(uint16 connHandle, attReadBlobRsp_t *pRsp);
-
- bStatus_t ATT_ReadMultiRsp(uint16 connHandle, attReadMultiRsp_t *pRsp);
-
- bStatus_t ATT_ReadByGrpTypeRsp(uint16 connHandle, attReadByGrpTypeRsp_t *pRsp);
-
- bStatus_t ATT_WriteRsp(uint16 connHandle);
-
- bStatus_t ATT_PrepareWriteRsp(uint16 connHandle, attPrepareWriteRsp_t *pRsp);
-
- bStatus_t ATT_ExecuteWriteRsp(uint16 connHandle);
-
- bStatus_t ATT_HandleValueNoti(uint16 connHandle, attHandleValueNoti_t *pNoti);
-
- bStatus_t ATT_HandleValueInd(uint16 connHandle, attHandleValueInd_t *pInd);
-
- void ATT_SetParamValue(uint16 value);
-
- uint16 ATT_GetParamValue(void);
OSAL 学习笔记
1-OSAL.C
* @fn osal_strlen 计算字符串的长度。字符串必须空结尾。
* @fn osal_memcpy 一般内存复制
* @fn osal_revmemcpy
//一般的颠倒内存复制。从资源缓存的最后开始,通过使用资源地址的指针移动len字节的,然后指针自减。
* @fn osal_memdup
//分配一个缓存(和osal_mem_alloc()),并复制这个资源缓存到刚分配好的控件.
* @fn osal_memcmp 一般内存比较
* @fn osal_memset 设置内存缓存值
* @fn osal_rand 产生随机数
* @fn osal_msg_allocate 动态分配一个OSAL消息缓存
* @fn osal_msg_deallocate 释放一个OSAL消息缓存(接收任务调用)
* @fn osal_msg_send 为某个任务发送一个OSAL消息
* @fn osal_msg_receive 检索接收命令消息。
* @fn osal_msg_find 发现 在一个OSAL消息匹配任务ID和事件参数。
* @fn osal_msg_extract
* //从OSAL队列中间 提取和移除 一个OSAL消息
* @fn osal_set_event 为一个任务设置一个 OSAL 事件
* @fn osal_clear_event 清除一个任务的事件标志。
* @fn osal_init_system OSAL 初始化,必须在主函数中被调用
* @fn osal_start_system 开始运行OSAL 主循环
* @fn osal_run_system 现至少一个等待事件的第一个任务。
2-OSAL_bufmgr.c
* @fn osal_bm_alloc 分配器函数的实现
* @fn osal_bm_free 取消分配器函数 的实现
* @fn osal_bm_adjust_header 调整header
* @fn osal_bm_adjust_tail 调整tail
3-OSAL_cbtimer.c
* @fn osal_CbTimerInit 初始化函数
* @fn osal_CbTimerProcessEvent//回调 定时器 任务事件处理函数
* @fn osal_CbTimerStart//当定时器到期,注册调用函数将被调用。
* @fn osal_CbTimerUpdate更新一个已经启动的 消息定时器
* @fn osal_CbTimerStop//停止一个已经启动的定时器。
4-OSAL_ClockBLE.c
* @fn osalTimeUpdate 更新 OSAL时间和定时器,
* @fn osalClockUpdate //用 运行ms 更新OSAL时间表,
* @fn osal_setClock//设置新时间。
* @fn osal_getClock //得到当前时间。
* @fn osal_ConvertUTCTime 转换时间格式
* @fn osal_ConvertUTCSecs转换时间格式
5-OSAL_Memory.c
* @fn osal_mem_init内存管理初始化
* @fn osal_mem_kick //任务初始化
* @fn osal_mem_alloc执行 OSAL 动态内存分配函数
* @fn osal_mem_free //执行OSAL动态内存 释放函数
6-OSAL_PwrMgr.c
* @fn osal_pwrmgr_init //初始化 电源管理系统
* @fn osal_pwrmgr_task_state//每一个任务调用函数,来陈述是否这个任务要保存电源
* @fn osal_pwrmgr_powerconserve //当没有活动安排 这个函数从主循环被调用,不应该从别的地方被调用。
7-OSAL_snv.c
8-OSAL_timers.c
* @fn osalTimerInit 初始化OSAL定时器系统
* @fn osalAddTimer增加一个定时器到定时器列表
* @fn osalFindTimer 在定时器列表中发现一个定时器
* @fn osalDeleteTimer 从一个列表中删除一个定时器
* @fn osal_start_timerEx //调用开始一个定时器在n ms内
* @fn osal_stop_timerEx //停止一个已经启动的定时器。
* @fn osalTimerUpdate更新 定时器结构
* @fn osal_adjust_timers 更新已经过去的定时器结构
* @fn osal_GetSystemClock 读取本地系统时钟
==================================================================
以上是一个BLE应用里的OSAL所用到的函数名字,及其功能,方便以后查询。
==================================================================