一 概述
SC7A20 是一款高精度 12bit 數(shù)字三軸加速度傳感器芯片,內(nèi)置功能更豐富,功耗更低,體積更小,測量更精確。芯片通過 I2C/SPI 接口與 MCU 通信,加速度測量數(shù)據(jù)以中斷方式或查詢方式獲取。INT1 和 INT2 中斷管腳提供多種內(nèi)部自動檢測的中斷信號,適應(yīng)多種運動檢測場合,中斷源包括 6D/4D 方向檢測中斷信號、自由落體檢測中斷信號、睡眠和喚醒檢測中斷信號、單擊和雙擊檢測中斷信號。芯片內(nèi)置高精度校準(zhǔn)模塊,對傳感器的失調(diào)誤差和增益誤差進(jìn)行精確補(bǔ)償。±2G、±4G、±8G 和±16G 四種可調(diào)整的全量程測量范圍,靈活測量外部加速度,輸出數(shù)據(jù)率 1HZ 和 400HZ 間可選。芯片內(nèi)置自測試功能允許客戶系統(tǒng)測試時檢測系統(tǒng)功能,省去復(fù)雜的轉(zhuǎn)臺測試。芯片內(nèi)置產(chǎn)品傾斜校準(zhǔn)功能,對貼片和板卡安裝導(dǎo)致的傾斜進(jìn)行補(bǔ)償,不占系統(tǒng)資源,系統(tǒng)文件升級不影響傳感器參數(shù)。
二 工作模式
三種工作模式:正常模式(Normal mode)、掉電模式(Power Down)、低功耗模式(Lowpower),正常模式能保證更高的三軸輸出數(shù)據(jù)精度,低功耗模式能減少電流消耗。根據(jù) SC7660/SC7A20 規(guī)格書,XYZ 三軸的數(shù)據(jù)輸出速率(ODR)、XYZ 三軸的數(shù)據(jù)使能控制(Xen、Yen、Zen)及工作模式的選擇(Operating Modes)可通過寄存器 CTRL_REG1(20h)和寄存器 CTRL_REG4(23h)的 HR 來控制實現(xiàn)設(shè)置,如表 1、表 2 所示。
正常模式(Normal)
在此模式下,能保證更好的數(shù)據(jù)采樣精度,XYZ 三軸的數(shù)據(jù)可按照設(shè)置好的 ODR(數(shù)據(jù)更新率)周期性的輸出三軸數(shù)據(jù)寄存器。
掉電模式(Power Down)
在此模式下,除了 IIC 和 SPI 外所有的內(nèi)部模塊都被關(guān)閉以節(jié)省功耗,所有寄存器之前配置過的參數(shù)數(shù)據(jù)都被保存,而三軸輸出的數(shù)據(jù)寄存器的數(shù)據(jù)不再更新,仍維持上一次正常工作時采樣的數(shù)據(jù)。
低功耗(Low Power)模式
此模式的主要特點是功耗低,數(shù)據(jù)輸出情況和正常模式一致,三軸數(shù)據(jù)可按照設(shè)置好的ODR 周期性地輸出三軸數(shù)據(jù)。
三 三軸數(shù)據(jù)讀取操作
3.1 查詢狀態(tài)寄存器 STATUS 并讀取數(shù)據(jù)
當(dāng)有 X、Y、Z 軸有數(shù)據(jù)更新時,對應(yīng)狀態(tài)標(biāo)識寄存器 STATUS_REG(27h)的 ZYXDA、ZDA、YDA、XDA 位會自動置 1,此時可直接讀取三軸數(shù)據(jù)寄存器 OUT_X_L(28H)、OUT_X_H(29H)、OUT_Y_L(2AH)、OUT_Y_H(2BH)、OUT_Z_L(2CH)、OUT_Z_H(2DH),以上寄存器全部讀取操作完成后,狀態(tài)標(biāo)識寄存器 STATUS_REG 的 ZYXDA、ZDA、YDA、XDA 位才能自動清 0。若在數(shù)據(jù)讀取前,數(shù)據(jù)發(fā)生再次更新,上次數(shù)據(jù)會被自動覆蓋,且此時 STATUS_REG 的 ZYXOR、ZOR、YOR、XOR 會自動置 1,而讀完三軸數(shù)據(jù)寄存器內(nèi)容后會自動清 0。若 CTRL_REG4(23h)的 BDU 位是置 0 的,數(shù)據(jù)會不斷更新,上述狀態(tài)標(biāo)志變化情況仍然會發(fā)生。
3.2 查詢 DataReady(DRY)信號并讀取數(shù)據(jù)
通過配置相應(yīng)的中斷寄存器,可以將 STATUS_REG(27h)狀態(tài)寄存器的 ZYXDA 位通過INT1 腳反映。具體配置方法為:將 CTRL_REG3(22H)的 I1_DRDY1 置 1,并通過配置CTRL_REG6(25H)中的 H_LACTIVE 位來選擇 INT 腳的極性(高電平有效或者是低電平有效)。當(dāng)設(shè)置為高電平有效時(H_LACTIVE=0),三軸有新數(shù)據(jù)更新則 INT1 腳會自動升為高電平,此時完成三軸數(shù)據(jù)讀操作后,ZYXDA,ZDA,YDA,XDA 位會自動清 0,同時 INT1引腳自動降為低電平。相反,當(dāng)設(shè)置為高電平有效時(H_LACTIVE=1),三軸有新數(shù)據(jù)更新則 INT1 腳會自動降為低電平,此時完成三軸數(shù)據(jù)讀操作后,ZYXDA,ZDA,YDA,XDA位會自動清 0,同時 INT1 引腳自動升為高電平。
3.3 BDU 功能
如果主機(jī)(MCU)讀三軸數(shù)據(jù)寄存器內(nèi)容的速度較慢,并且讀寫速度無法和 DRDY 信號或者狀態(tài)寄存器標(biāo)志位的更新速度同步,強(qiáng)烈建議一定要將寄存器 CRTL_REG4(23H)的最高位 BDU 置 1。通過該方法可以保證讀取的三軸輸出數(shù)據(jù)(OUT_X_L~OUT_Z_H;0x28-0x2D)是同一時刻,即某一個運動狀態(tài)下的數(shù)據(jù)值。將 BDU 置 1 是為了使三軸數(shù)據(jù)不能自動連續(xù)更新,直至某軸高位和低位數(shù)據(jù)都被讀取,才會有最新數(shù)據(jù)更新到該寄存器中。
四 組件的使用
1 Gitee鏈接地址
Demo位于amaziot_bloom_os_sdksample3rd1.2_SC7A20
Gitee源碼地址:https://gitee.com/ning./hongdou
Github源碼地址:https://github.com/ayumid/hongdou
編譯指令:.build.bat -l .amaziot_bloom_os_sdksample3rd1.2_SC7A20
2 組件功能介紹
實現(xiàn)三軸傳感器驅(qū)動,獲取基礎(chǔ)三軸加速度,根據(jù)加速度計算芯片和水平面夾角,俯仰角,橫滾角。
3 代碼講解
1 drv_sc7a20_get_angle
功能:該函數(shù)用于,獲取Z軸傾角,即和水平面的角度。
參數(shù):
參數(shù) | 釋義 |
pAngleZ | Z軸傾角 |
返回值:無
示例:
drv_sc7a20_get_angle(&zAngle);
2 drv_sc7a20_get_roll
功能:該函數(shù)用于,獲取橫滾角。
參數(shù):
參數(shù) | 釋義 |
x | X軸加速度 |
y | Y軸加速度 |
z | Z軸加速度 |
返回值:無
示例:
roll = drv_sc7a20_get_roll(accX, accY, accZ);
3 drv_sc7a20_get_pitch
功能:該函數(shù)用于,顯示漢字。
參數(shù):
參數(shù) | 釋義 |
x | X軸加速度 |
y | Y軸加速度 |
z | Z軸加速度 |
返回值:無
示例:
pitch = drv_sc7a20_get_pitch(accX, accY, accZ);
4 drv_sc7a20_get_acc
功能:該函數(shù)用于,顯示數(shù)字。
參數(shù):
參數(shù) | 釋義 |
pXa | X軸加速度存儲區(qū)指針 |
pYa | Y軸加速度存儲區(qū)指針 |
pZa | Z軸加速度存儲區(qū)指針 |
返回值:無
示例:
drv_sc7a20_get_acc(&accX, &accY, &accZ);
5 drv_sc7a20_i2c_write
功能:該函數(shù)用于,寫sc7a20的寄存器。
參數(shù):
參數(shù) | 釋義 |
addr | 寄存器地址 |
data | 寫入寄存器值 |
返回值:無
示例:
//初始化sc7a20 RegAddr = 0x20; RegWriteValue = 0x47; ret = drv_sc7a20_i2c_write(&RegAddr, &RegWriteValue);//50Hz+正常模式xyz使能
6 drv_sc7a20_i2c_read
功能:該函數(shù)用于,讀sc7a20的寄存器內(nèi)容。
參數(shù):
參數(shù) | 釋義 |
addr | 寄存器地址 |
data | 讀取的寄存器值 |
返回值:無
示例:
RegAddr = 0X28 + i; drv_sc7a20_i2c_read(&RegAddr, &buff[i]);
7 drv_sc7a20_i2c_init
功能:該函數(shù)用于,在指定位置顯示一個字符,包括部分字符。
參數(shù):
參數(shù) | 釋義 |
x,y | 顯示坐標(biāo) |
size1 | 選擇字體 6x8/6x12/8x16/12x24 |
mode | 0,反色顯示;1,正常顯示 |
返回值:無
示例:
drv_ssd1315_show_char(48,48,t,16,1);//顯示ASCII字符
8 drv_sc7a20_i2c_init
功能:該函數(shù)用于,初始化使用的第0組 i2c 總線。
參數(shù):無
返回值:無
示例:
//初始化i2c總線 ret = drv_sc7a20_i2c_init();
4 Demo實戰(zhàn)
4.1 創(chuàng)建一個Demo
復(fù)制20.1_file_xtu示例工程,到同一個文件夾下,修改文件名為1.2_SC7A20,如圖:
4.2 修改makefile
增加文件組件所在目錄頭文件路徑,和源文件路徑,如圖:
4.3 增加頭文件
使用代碼編輯器,將新建的工程文件加入代碼編輯器中,打開main.c,修改main.c,加入am.h等頭文件,如圖:
4.4 修改代碼
在Phase2Inits_exit 創(chuàng)建一個任務(wù),如圖:
4.5 宏定義介紹
sample_sc7a20_uart_printf
輸出日志到DEBUG 串口,日志比較少,可以輸出到這個串口,如果日志比較多,需要輸出到usb口,以免不必要的問題出現(xiàn)
sample_sc7a20_catstudio_printf
輸出日志到USB 串口,使用catstudio查看,catstudio查看日志需要更新對應(yīng)版本mdb.txt文件,軟件打開filtter過濾日志,只查看用戶輸出的日志
SAMPLE_SC7A20_STACK_SIZE
棧空間宏定義
4.6 全局變量介紹
sample_sc7a20_int_detect_stack_ptr
任務(wù)棧空間,本例使用數(shù)組實現(xiàn),用戶在做項目時,可以預(yù)先估算下當(dāng)先任務(wù)需要的大致棧空間,OS沒有提供可以查看棧空間使用情況的API
sample_sc7a20_int_detect_task_ref
任務(wù)指針
4.7 函數(shù)介紹
Phase1Inits_enter
底層初始化,本例空
Phase1Inits_exit
底層初始化,本例空
Phase2Inits_enter
底層初始化,本例空
Phase2Inits_exit
創(chuàng)建主任務(wù),初始化消息隊列,定時器,任務(wù)等。
代碼片段:
OSATaskCreate(&sample_sc7a20_int_detect_task_ref, sample_sc7a20_int_detect_stack_ptr, SAMPLE_SC7A20_STACK_SIZE, 100, "detect_task", sample_sc7a20_detect_task, NULL);
sample_sc7a20_detect_task
主任務(wù),獲取imsi,rsrq等參數(shù)信息。
代碼片段:
void sample_sc7a20_detect_task(void *param) { GPIO_ReturnCode ret = 0; UINT32 value = 0; OSA_STATUS status = OS_SUCCESS; UINT32 flag_value = 0; unsigned char RegAddr = 0; unsigned char RegWriteValue = 0; unsigned char RegReadValue0 = 0; unsigned char RegReadValue1 = 0; INT16 accX = 0; INT16 accY = 0; INT16 accZ = 0; float pitch = 0.0; float roll = 0.0; float zAngle = 0.0; //初始化i2c總線 ret = drv_sc7a20_i2c_init(); sample_sc7a20_catstudio_printf("ql_i2c_init ret %d", ret); OSATaskSleep(1 * 200); //上電后,讀sc7a20 io擴(kuò)展芯片的個寄存器,測試用 RegAddr = 0x0F; ret = drv_sc7a20_i2c_read(&RegAddr, &RegReadValue0); sample_sc7a20_catstudio_printf("read reg 00 i2c value=0x%x, ret=%d", RegReadValue0, ret); //等1s OSATaskSleep(1 * 200); //初始化sc7a20 RegAddr = 0x20; RegWriteValue = 0x47; ret = drv_sc7a20_i2c_write(&RegAddr, &RegWriteValue);//50Hz+正常模式xyz使能 sample_sc7a20_catstudio_printf("write i2c value=0x%x, ret=%d", RegWriteValue, ret); RegAddr = 0x21; RegWriteValue = 0x00; ret = drv_sc7a20_i2c_write(&RegAddr, &RegWriteValue);//關(guān)閉濾波器,手冊上面沒有濾波器截止頻率設(shè)置說明,開啟后無法測量靜止?fàn)顟B(tài)下的重力加速度 sample_sc7a20_catstudio_printf("write i2c value=0x%x, ret=%d", RegWriteValue, ret); RegAddr = 0x22; RegWriteValue = 0x00; ret = drv_sc7a20_i2c_write(&RegAddr, &RegWriteValue);//關(guān)閉中斷 sample_sc7a20_catstudio_printf("write i2c value=0x%x, ret=%d", RegWriteValue, ret); RegAddr = 0x23; RegWriteValue = 0x88; ret = drv_sc7a20_i2c_write(&RegAddr, &RegWriteValue);//讀取完成再更新,小端模式,、2g+正常模式,高精度模式 sample_sc7a20_catstudio_printf("write i2c value=0x%x, ret=%d", RegWriteValue, ret); //等1s OSATaskSleep(1 * 200); while(1) { // status = OSAFlagWait(sample_sc7a20_int_detect_flg_ref, 0x01, OSA_FLAG_OR_CLEAR, &flag_value, OSA_SUSPEND); // //紅豆版,設(shè)置了邊沿,但是還是會上升沿,下降沿都觸發(fā),所以會執(zhí)行兩次 // if(flag_value & 0x01) // { // } RegAddr = 0x27; ret = drv_sc7a20_i2c_read(&RegAddr, &RegReadValue0); // sample_sc7a20_catstudio_printf("read reg 27 i2c value=0x%x, ret=%d", RegReadValue0, ret); RegReadValue0 = RegReadValue0 & 0x0F; if(0x0F == RegReadValue0) { drv_sc7a20_get_acc(&accX, &accY, &accZ); pitch = drv_sc7a20_get_pitch(accX, accY, accZ); roll = drv_sc7a20_get_roll(accX, accY, accZ); drv_sc7a20_get_angle(&zAngle); sample_sc7a20_catstudio_printf("aX:%d aY:%d aZ:%d pitch:%.04f roll:%.04f Angle: %.04f", accX, accY, accZ, pitch, roll, zAngle); } sample_sc7a20_sleep(1); } }
4.8 編譯
在SDK根目錄打開命令行,輸入命令.build.bat -l .amaziot_bloom_os_sdksample3rd1.2_SC7A20
PS F:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRF λ .build.bat -l .amaziot_bloom_os_sdksample3rd1.2_SC7A20 子目錄或文件 outbin 已經(jīng)存在。 命令語法不正確。 子目錄或文件 buildobj 已經(jīng)存在。 gnumake: Entering directory `F:/3.asr-b/cat.1-asr1606/1.software/BlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRF/amaziot_bloom_os_sdk/sample/3rd/1.2_SC7A20' armcc.exe -c --cpu Cortex-R4 --no_unaligned_access -g -O2 --apcs /inter --diag_suppress 2084,1,2,177,188,223,550,1296,2795,6319,9931,9933 --diag_error=warning --gnu --thumb --loose_implicit_cast -DDATA_COLLECTOR_IMPL -DISPT_OVER_SSP -DDIAG_SSP_DOUBLE_BUFFER_USE_DYNAMIC_ALLOCATION -DENV_XSCALE -DL1_DCXO_ENABLED -DLTE_HIGH_MOBILITY_OPTIMIZATION -DRUN_XIP_MODE -DCRANE_Z2 -DCA_LONG_IPC_MSG -DNEZHA3 -DNEZHA3_1826 -DUPGRADE_PLMS -DUPGRADE_PLMS_SR -DLTE_GSMMULTIBCCH -DGPLC_LTE_RSSI_SCAN -DL1V_NEW_RSSI -DUPGRADE_PLMS_3G -DUPGRADE_PLMS_L1 -DUPGRADE_FG_PLMS -DFG_PLMS_URR -DUPGRADE_L1A_FG_PLMS -DUPGRADE_PLMS_STAGE_2 -DUPGRADE_MBCCH -DMULTI_BCCH_READY_IND -DURR_MRAT_ICS_SEARCH -DUPGRADE_ICS -DMRAT_NAS -DUPGRADE_PLMS_SEARCH_API -DICS_MBCCH -DICS_MBCCH_2G_RSSI -DDIAG_NEWPP -DPHS_SW_DEMO -DPHS_SW_DEMO_TTC -DPHS_SW_DEMO_TTC_PM -DFULL_SYSTEM -D_DDR_INIT_ -D_TAVOR_HARBELL_ -DUPGRADE_ARBEL_PLATFORM -D_TAVOR_B0_SILICON_ -DTDL1C_SPY_ENABLE -DDLM_TAVOR -DTAVOR -DFLAVOR_DUALCORE -DDEBUG_D2_MOR_REG_RESEREVED_ENABLE -D_DIAG_USE_COMMSTACK_ -D_TAVOR_DIAG_ -DPM_DEBUG_MODE_ENABLED -DPM_D2FULL_MODE -DPM_EXT_DBG_INT_ARR -DFEATURE_WB_AMR_PS -DMACRO_FOR_LWG -DHL_LWG -DOPTIMIZE_FOR_2G_BCCH -DPLAT_TEST -D_FDI_USE_OSA_ -DPLAT_USE_THREADX -DLWIP_IPNETBUF_SUPPORT -DCRANE_MCU_DONGLE -DAT_OVER_UART -DPHS_SW_DEMO_TTC_PM -DUPGRADE_LTE_ONLY -DEXT_AT_MODEM_SUPPORT -DLTEONLY_THIN_SINGLE_SIM -DLFS_FILE_SYS -DLFS_FILE_SYS_V2 -DPSM_ENABLE -DNO_PAHO_MQTT -DNO_XML -DNO_LWM2M -DREMOVE_MBEDTLS -DNO_AT_NET -DCRANE_SD_NOT_SUPPORT -DNTP -DYMODEM_EEH_DUMP -DENABLE_DM_LTEONLY -DLTEONLY_THIN -DNO_EXTEND_MY_Q_AT -DNOT_SUPPORT_HTTPS -DNOT_SUPPORT_PM813 -DCRANEL_4MRAM -DREMOVE_PB -DUART_NEW_VERSION -DREMOVE_MEP -DREMOVE_SMS -DREMOVE_ENVSIM -DAPN_INCODE -DLTEONLY_THIN_SINGLE_SIM_2MFLASH -DASR160X_OPENCPU_FEATURE -DENABLE_UART3_FEATRUE -DENABLE_UART4_FEATRUE -DYUGE_MBEDTLS_3_2_1 -DENABLE_MAC_TX_DATA_LOGGING -DDISABLE_NVRAM_ACCESS -DINTEL_UPGRADE_EE_HANDLER_SUPPORT -DLTE_W_PS -DL1_DUAL_MODE -DUPGRADE_HERMON_DUAL -DINTEL_UPGRADE_DUAL_RAT -DINTEL_UPGRADE_GPRS_CIPHER_FLUSH -DUPGRADE_ENHANCED_QUAD_BAND -DINTEL_2CHIP_PLAT -DI_2CHIP_PLAT -DUPGRDE_TAVOR_COMMUNICATION -DRUN_WIRELESS_MODEM -DFLAVOR_DDR12MB_GB1MB5 -DFEATURE_SHMEM -DACIPC_ENABLE_NEW_CALLBACK_MECHANISM -DRELIABLE_DATA -DMAP_NSS -DTV_FNAME=""SW_PLATFORM=PMD2NONE PHS_SW_DEMO PHS_SW_DEMO_PM SRCNUCLEUS FULL_SYSTEM NOACRTC PDFLT PLAT_TEST PV2 DIAGOSHMEM NVM WITHL1V"" -DTV_FDESC=""SW_DESCRIPTION="" -DENABLE_ACIPC -D_DATAOMSL_ENABLED_ -DUSB_CABLE_DETECTION_VIA_PMIC -DMIPS_TEST -DMIPS_TEST_RAM -DFLAVOR_DIET_RAM -DNVM_INCLUDE -DMSL_INCLUDE -DMSL_POOL_MEM -DNO_AUDIO -DOSA_QUEUE_NAMES -D_DIAG_DISABLE_USB_ -DOSA_NUCLEUS -DOSA_USED -DPM_D2NONE_MODE -DCRANE_SOC_TEMPERATURE_SENSOR -DL1_SW_UPDATE_FOR_DIGRF -DPHS_L1_SW_UPDATE_R7 -DUPGRADE_LTE -DFRBD_CALIB_NVM -DFRBD_AGC_CALIB -DFRBD_FDT_CALIB -DHSPA_MPR -DCAPT_PARAMS_OPTIMIZE -DL1_WB_R99_ONLY -DL1V_WB_R99_ONLY -DINTERGRATED_RF_SUPPORT -DL1_RX_DIV_SUPPORT -DENABLE_OOS_HANDLING -DTAVOR_D2_WB_L1_SUPPORT -DL1_DDR_HIGH_FREQ -DUPGRADE_DIGRF3G_SUPPORT -DW_PS_PLUS_G_PAGING -D"NO_APLP=0" -DINTEL_UPGRADE_UNIFIED_VOICE_TASK -DINTEL_UPGRADE_R99 -DAPLP_SPY_ENABLE -D__TARGET_FEATURE_DOUBLEWORD -DWHOLE_UMTS_STACK -DUSE_TTPCOM_CSR_BLUETOOTH_AUDIO_GAIN_CONTROL -DL1_UPGRADE_R5 -DUPGRADE_EDGE -DUPGRADE_R4_FS1 -DINTEL_UPGRADE_GSM_CRL_IF -DUPGRADE_EGPRS_M -DINTEL_UPGRADE_EGPRS_M -DINTEL_UPGRADE_RF_PARAMS_IN_CF_TDS -DINTEL_UPGRADE_2SAMPLES_PER_SYMBOL -D"GPRS_MULTISLOT_CLASS=12" -D"EGPRS_MULTISLOT_CLASS=12" -DMARVELL_UPGRADE_BSIC_REDESIGN -DMSL_INCLUDE -DINTEL_HERMON_SAC -DCRANE_CUST_BUILD -DL1_SW_UPDATE_FOR_DIGRF -DFLAVOR_COM -DSILICON_PV2 -DSILICON_SEAGULL -DSILICON_TTC_CORE_SEAGULL -DPCAC_INCLUDE -Otime -DBUILD_DATE=""06 13 2024"" -DBUILD_TIME=""14:42:24"" -Iatcmdsinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhoptelephonyyugeinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhalUARTinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhalcoreinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhalPMUinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhalGPIOinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xosposixinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xdiagdiag_logicsrc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xcswSysCfginc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xcswplatforminc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xenvwin32inc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xcswBSPinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xcswplatformdev_platbuild -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xososainc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xosthreadxinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xosnu_xscaleinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcacpsminc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcachttpclientsrc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xdiagdiag_logicinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhoptimerinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhopintcinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xcswPMinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhoppminc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilTickManagerinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhopBSPinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhoptelephonyatcmdsrvinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhoptelephonyatparserinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhoptelephonysdkinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcachttpclientinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcacciinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcaclwipv4v6srcinclude -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcaclwipv4v6srcincludearch -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcaclwipv4v6srcincludeipv4 -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcaclwipv4v6srcincludeipv6 -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcaclwipv4v6srcincludelwip -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcaclwipv4v6srcincludenetif -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhopmmi_matinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xtavorArbelinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xtavorenvinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhoptelephonymodeminc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcacdusterinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcacfotainc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhalI2Cinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhalACIPCinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilfatsysflash -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilFDIsrcINCLUDE -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhalMMUinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilFDIsrcFDI_ADD -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilFDIsrcFM_INC -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilfatsysfshdr -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutillittlefsinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcacttsinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcacdialinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilcsw_memoryinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhoputilitiesinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhopcommpminc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilnvminc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilEEhandlerinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilEEhandlersrc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhopRTCinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhoptelephonyci_clientinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhalBT_deviceinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhalUARTinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhopmrdinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhopdmainc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilsoftutilinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhalSPIinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcacwebsocketinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcacatnet_srvinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xsoftutilfotacomminc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xaud_swAudioinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xaud_swACM_COMMinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xaud_swaudio_stubsrc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhopaaminc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xaud_swAudioHALinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xhaldbgshellinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFincludeasr160xpcacopencpuinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFamaziot_bloom_os_sdkutils -IF:/3.asr-b/cat.1-asr1606/1.software/BlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRF/amaziot_bloom_os_sdk/sample/3rd/1.2_SC7A20aminc -IF:/3.asr-b/cat.1-asr1606/1.software/BlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRF/amaziot_bloom_os_sdk/sample/3rd/1.2_SC7A20atcmdsinc -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFamaziot_bloom_os_sdk3rd_drives -IF:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFamaziot_bloom_os_sdk3rd_drivesSC7A20 -o buildobj/ext_at_cmds.o F:/3.asr-b/cat.1-asr1606/1.software/BlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRF/amaziot_bloom_os_sdk/sample/3rd/1.2_SC7A20/atcmds/src/ext_at_cmds.c armlink.exe buildobj/main.o buildobj/ext_at_cmds.o buildobj/ext_at_controller.o buildobj/drv_sc7a20.o -o F:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFoutbinArbel_PMD2NONE_40M.axf --via F:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFprebuilt_1606lArbel_PMD2NONE_targ_objliblist.txt --elf --scatter F:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFprebuilt_1606lCrane_DS_4M_Ram_2M_Flash_XIP_CIPSRAM_Common_SingleSIM.sct --predefine="-DLTEONLY_THIN_SINGLE_SIM" --map --symbols --info sizes,totals --list F:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFoutbinArbel_PMD2NONE_40M.map --keep init.o(Header) --keep init.o(Vectors) --diag_suppress 6312,6314,6319,6329 --feedback F:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFoutfeedbackLinkOptLteonlyThin_SingleSim_NoSMS.txt F:3.asr-bcat.1-asr16061.softwareBlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRFtoolsbuildimage_1606l.bat SDK_PROD_TYPE : [DM] SDK_CUST_SKU : [THIN_SINGLE_SIM_NO_SMS] SDK_PS_MODE : [LTEONLY] SDK_CHIP_VER : [Z2A0] SDK_OS_TYPE : [TX] Platform Convertion Tools v4.01 with PS option extension Convertion done! |INPUT |outbincp_1606L.bin |MARK |NAME |EXEADDR .LOADADDR.LENGTH .CPZLADDR|COMPRESS STASTIC | |--------|--------|--------.--------.--------.--------|------------------------------| |This Is LteOnly 4M| |RW_CPZ_1|DDR_RW_ |7e119000.80065250.0000cdf4.80066000|0000cdf4->00003000 |This Is LteOnly 4M| |RW_CPZ_2|PS_NCAH |7e388000.80072044.00001300.80069000|00001300->00001000 |This Is LteOnly 4M| |RW_CPZ_3|ITCM |7e3dac00.80073344.0000f51c.8006a000|0000f51c->0000a000 |This Is LteOnly 4M| |RW_CPZ_4|CODE_PS |7e1aa000.80082860.0002fe38.80074000|0002fe38->0001e000 |This Is LteOnly 4M| |RW_CPZ_5|CODEPSB |7e1dc000.800b2698.000339c0.80092000|000339c0->0001b000 |This Is LteOnly 4M| |RW_CPZ_6|CODEPSC |7e213000.800e6058.000323ec.800ad000|000323ec->0001b000 |This Is LteOnly 4M| |RW_CPZ_7|CODEPSD |7e249000.80118444.00028d88.800c8000|00028d88->0001a000 |This Is LteOnly 4M| |RW_CPZ_8|CODEPSE |7e277000.801411cc.0002e310.800e2000|0002e310->0001a000 |This Is LteOnly 4M| |RW_CPZ_9|CODEPSF |7e2a9000.8016f4dc.0001c948.800fc000|0001c948->00011000 |This Is LteOnly 4M| |RW_CPZ_A|CODE_PL |7e2ca000.8018be24.0002fa44.8010d000|0002fa44->0001e000 |This Is LteOnly 4M| |RW_CPZ_B|CODEPLB |7e2fa000.801bb868.00039058.8012b000|00039058->00021000 |This Is LteOnly 4M| |RW_CPZ_C|CODEPLC |7e337000.801f48c0.000268d4.8014c000|000268d4->00011000 |--------|--------|--------.--------.--------.--------|------------------------------| | | 0x00204194 -> 0x00146000| | | 2.016(MB) -> 1.273(MB)| |------------------------------------------------------------------------------------| cp_1606L.axf cp_1606L.bin cp_1606L.map gnumake: Leaving directory `F:/3.asr-b/cat.1-asr1606/1.software/BlOOM_OS_1606_OPENCPU_1191_A09_WIHT_NEWRF/amaziot_bloom_os_sdk/sample/3rd/1.2_SC7A20' "copy NEZHAC_CP_CNR_MIFI_TX.bin to ./ " 已復(fù)制 1 個文件。
4.9 生成固件
參考入門中開發(fā)工具,生成工具。
4.10 測試
測試步驟:
參考編譯教程,和文檔開頭的編譯指令,進(jìn)行編譯
按照編譯教程選擇對應(yīng)的選項
燒錄
4.11 固件
上電后,串口會打印出當(dāng)前的三軸數(shù)據(jù),并通過三軸數(shù)據(jù)計算出z軸傾角,俯仰角,橫滾角;
點擊下載 SC7A20 Demo 固件
5 生態(tài)組件鏈接
加速度傳感器
本文章源自奇跡物聯(lián)開源的物聯(lián)網(wǎng)應(yīng)用知識庫Cellular IoT Wiki,更多技術(shù)干貨歡迎關(guān)注收藏Wiki:Cellular IoT Wiki 知識庫(https://rckrv97mzx.feishu.cn/wiki/wikcnBvAC9WOkEYG5CLqGwm6PHf)
歡迎同學(xué)們走進(jìn)AmazIOT知識庫的世界!
這里是為物聯(lián)網(wǎng)人構(gòu)建的技術(shù)應(yīng)用百科,以便幫助你更快更簡單的開發(fā)物聯(lián)網(wǎng)產(chǎn)品。
Cellular IoT Wiki初心:
在我們長期投身于蜂窩物聯(lián)網(wǎng) ODM/OEM 解決方案的實踐過程中,一直被物聯(lián)網(wǎng)技術(shù)碎片化與產(chǎn)業(yè)資源碎片化的問題所困擾。從產(chǎn)品定義、芯片選型,到軟硬件研發(fā)和測試,物聯(lián)網(wǎng)技術(shù)的碎片化以及產(chǎn)業(yè)資源的碎片化,始終對團(tuán)隊的產(chǎn)品開發(fā)交付質(zhì)量和效率形成制約。為了減少因物聯(lián)網(wǎng)碎片化而帶來的重復(fù)開發(fā)工作,我們著手對物聯(lián)網(wǎng)開發(fā)中高頻應(yīng)用的技術(shù)知識進(jìn)行沉淀管理,并基于 Bloom OS 搭建了不同平臺的 RTOS 應(yīng)用生態(tài)。后來我們發(fā)現(xiàn),很多物聯(lián)網(wǎng)產(chǎn)品開發(fā)團(tuán)隊都面臨著相似的困擾,于是,我們決定向全體物聯(lián)網(wǎng)行業(yè)開發(fā)者開放奇跡物聯(lián)內(nèi)部沉淀的應(yīng)用技術(shù)知識庫 Wiki,期望能為更多物聯(lián)網(wǎng)產(chǎn)品開發(fā)者減輕一些重復(fù)造輪子的負(fù)擔(dān)。
Cellular IoT Wiki沉淀的技術(shù)內(nèi)容方向如下:
奇跡物聯(lián)的業(yè)務(wù)服務(wù)范圍:基于自研的NB-IoT、Cat1、Cat4等物聯(lián)網(wǎng)模組,為客戶物聯(lián)網(wǎng)ODM/OEM解決方案服務(wù)。我們的研發(fā)技術(shù)中心在石家莊,PCBA生產(chǎn)基地分布在深圳、石家莊、北京三個工廠,滿足不同區(qū)域&不同量產(chǎn)規(guī)模&不同產(chǎn)品開發(fā)階段的生產(chǎn)制造任務(wù)。跟傳統(tǒng)PCBA工廠最大的區(qū)別是我們只服務(wù)物聯(lián)網(wǎng)行業(yè)客戶。
連接我們,和10000+物聯(lián)網(wǎng)開發(fā)者一起 降低技術(shù)和成本門檻
讓蜂窩物聯(lián)網(wǎng)應(yīng)用更簡單~~
哈哈你終于滑到最重要的模塊了,
千萬不!要!劃!走!忍住沖動!~
歡迎加入飛書“開源技術(shù)交流群”,隨時找到我們哦~
點擊鏈接如何加入奇跡物聯(lián)技術(shù)話題群(https://rckrv97mzx.feishu.cn/docx/Xskpd1cFQo7hu9x5EuicbsjTnTf)可以獲取加入技術(shù)話題群攻略
Hey 物聯(lián)網(wǎng)從業(yè)者,
你是否有了解過奇跡物聯(lián)的官方公眾號“eSIM物聯(lián)工場”呢?
這里是奇跡物聯(lián)的物聯(lián)網(wǎng)應(yīng)用技術(shù)開源wiki主陣地,歡迎關(guān)注公眾號,不迷路~
及時獲得最新物聯(lián)網(wǎng)應(yīng)用技術(shù)沉淀發(fā)布
審核編輯 黃宇
-
物聯(lián)網(wǎng)
+關(guān)注
關(guān)注
2909文章
44557瀏覽量
372758 -
加速度傳感器
+關(guān)注
關(guān)注
12文章
471瀏覽量
55140
發(fā)布評論請先 登錄
相關(guān)推薦
評論