基于STM32G071RBT的SPI读取ADXL357加速度和温度.rar


该工程是基于STM32G071RBT的,通过SPI读取ADXL357的三轴加速度和温度,SPI使用了DMA的方式,采样频率为1KHz,使用STM32CubeMX自带的滴答定时器,1ms采样1次,ADXL357的最大频率为4KHz
资源截图
代码片段和文件信息
/******************************************************************************
 * @file     main_s.c
 * @brief    Code template for secure main function
 * @version  V1.1.1
 * @date     10. January 2018
 ******************************************************************************/
/*
 * Copyright (c) 2013-2018 Arm Limited. All rights reserved.
 *
 * SPDX-License-Identifier: Apache-2.0
 *
 * Licensed under the Apache License Version 2.0 (the License); you may
 * not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing software
 * distributed under the License is distributed on an AS IS BASIS WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

/* Use CMSE intrinsics */
#include 
 
#include “RTE_Components.h“
#include CMSIS_device_header
 
/* TZ_START_NS: Start address of non-secure application */
#ifndef TZ_START_NS
#define TZ_START_NS (0x200000U)
#endif
 
/* typedef for non-secure callback functions */
typedef void (*funcptr_void) (void) __attribute__((cmse_nonsecure_call));
 
/* Secure main() */
int main(void) {
  funcptr_void NonSecure_ResetHandler;
 
  /* Add user setup code for secure part here*/
 
  /* Set non-secure main stack (MSP_NS) */
  __TZ_set_MSP_NS(*((uint32_t *)(TZ_START_NS)));
 
  /* Get non-secure reset handler */
  NonSecure_ResetHandler = (funcptr_void)(*((uint32_t *)((TZ_START_NS) + 4U)));
 
  /* Start non-secure state software application */
  NonSecure_ResetHandler();
 
  /* Non-secure software does not return this code is not executed */
  while (1) {
    __NOP();
  }
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件       8719  2020-01-15 16:36  基于STM32G071RBT的ADXL357 SPI读取.mxproject

     文件      11385  2020-01-15 16:36  基于STM32G071RBT的ADXL357 SPI读取ADXL357.ioc

     文件      28208  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecmsis_armcc.h

     文件      56497  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecmsis_armclang.h

     文件       9014  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecmsis_compiler.h

     文件      62344  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecmsis_gcc.h

     文件      28414  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecmsis_iccarm.h

     文件       1716  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecmsis_version.h

     文件      97995  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_armv8mbl.h

     文件     168914  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_armv8mml.h

     文件      42208  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_cm0.h

     文件      50464  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_cm0plus.h

     文件      43456  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_cm1.h

     文件     104628  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_cm23.h

     文件     111854  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_cm3.h

     文件     175600  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_cm33.h

     文件     123607  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_cm4.h

     文件     148588  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_cm7.h

     文件      47249  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_sc000.h

     文件     110523  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludecore_sc300.h

     文件      11711  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludempu_armv7.h

     文件      10958  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreIncludempu_armv8.h

     文件       2757  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreInclude z_context.h

     文件       1877  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreTemplateARMv8-Mmain_s.c

     文件       6001  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCoreTemplateARMv8-M z_context.c

     文件      16600  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCore_AIncludecmsis_armcc.h

     文件      16510  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCore_AIncludecmsis_armclang.h

     文件       5456  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCore_AIncludecmsis_compiler.h

     文件      12551  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCore_AIncludecmsis_cp15.h

     文件      21749  2019-12-19 13:41  基于STM32G071RBT的ADXL357 SPI读取DriversCMSISCore_AIncludecmsis_gcc.h

............此处省略1094个文件信息

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容, 请发送邮件举报,一经查实,本站将立刻删除。

发表评论

评论列表(条)