2 Overview
The Atmel Sensors Xplained software is implemented as a common service
extension to the Atmel AVR Software Framework (ASF), version 2.5 and later. The
sensor software includes a high-level, portable C/C++ API, binary libraries containing
sensor drivers, sensor configuration mechanisms, and example applications
illustrating sensor API calls. Applications do not require any code that is specific to a
particular sensor device. Instead, the application interacts with sensors in a device-
independent manner and can be retargeted to different combinations of
microcontrollers and sensors using a few basic configuration constants and linking
against the appropriate driver library.
2.1 Common sensors service
The Sensors Xplained API portion is installed as a shared service in an ASF 2.x tree
in the common/services/sensors directory, and includes API and driver header files,
configuration header files for ASF services and target board support modules, and
high-level utility functions.
Sensor device drivers and some interface routines in the Sensors Xplained API are
distributed only as linkable binary modules, without source code. All applications
written to this API must link against the appropriate library archive found in toolchain-
specific subdirectories below the thirdparty/sensors/libs directory. In addition,
the sensor hardware and platform interfaces make extensive use of conditionally
compiled ASF services and platform interfaces. As a result, additional ASF source
files are required when building an application that uses the Sensors Xplained
libraries. These dependencies are managed by the Atmel AVR Studio ? 5 project
facility.
2.1.1 Sensors Xplained API modules
The common/services/sensors directory contains header files and C language
implementation files defining the Sensors Xplained application programming interface
(API). These include the
sensor.h
file (described below) and the
sensor_platform.c source file that is part of the sensor configuration mechanism.
A sensor API hardware abstraction layer (HAL) acts as a translation layer between
the AVR Software Framework drivers, sensor drivers, target board platform, and
sensor API. These statically configured modules provide access to the various driver
and board interfaces. The sensor_platform_init() routine is the primary runtime
mechanism by which applications initialize the target Xplained evaluation board and
Sensors Xplained board for use by the sensor API. Your application should call
sensor_platform_init() as its first step during system initialization. It replaces the
board_init() call that is typically made in other ASF-based applications.
The common/services/sensors directory also contains various other header and
source files. These are used by modules within the sensor service. You should not
include these files directly in your application or depend on the internal definitions,
which are subject to change in future releases.
2.1.2 The sensor.h header file
The common/services/sensors directory contains the sensor.h header file, which
is the primary file containing definitions that are required to use the Common Sensors
Service. These definitions include function prototypes for all API interfaces, data
2
Atmel AVR4016
8367B-AVR-06/11
相关PDF资料
ATAVRSBIN2 INERTIAL TWO SENSOR BOARD
ATAVRSBLP1 LIGHT AND PROXIMITY SENSOR BOARD
ATAVRSBPR1 BAROMETRIC PRESSURE ONE SNSR BRD
ATQT600 KIT EVAL TOUCH FOR QT600
ATU6-P305T-R CABLE CAT6 FULL-BOX 305M GRAY
ATUP-P305T-R CABLE CAT5E PULL-BOX 305M GRAY
ATUP-V305T-R CABLE CAT5E REEL 305M GRAY
AWG28-05/F-1/300-R CABLE 5 COND MULTI 300' RIBBON
相关代理商/技术参数
ATAVRSBIN2 功能描述:多功能传感器开发工具 9DOF Inertial Sensor Board 2 RoHS:否 制造商:Texas Instruments 工具用于评估:LMP91200 接口类型:SPI 工作电压:1.8 V to 5.5 V 最大工作温度:
ATAVRSBLP1 功能描述:光学传感器开发工具 Ambient Light and Proximity Snsr Brd RoHS:否 制造商:ams 工具用于评估: 接口类型: 最大工作温度:
ATAVRSBPR1 功能描述:压力传感器开发工具 Barometric Pressure Sensor Board 1 RoHS:否 制造商:Freescale Semiconductor 工具用于评估:MPL3115A2 接口类型:USB 最大工作温度:
ATAVRSECURITYX 功能描述:安全/ 验证开发工具 Security Module Kit for Xplain Series RoHS:否 制造商:Digi International 产品:Development Kits 工具用于评估:XEB-AW140 接口类型:SPI, USB 工作电源电压:3.1 V to 3.6 V
ATAVRSMD 功能描述:ADAPTER KIT SMD ICE200 RoHS:否 类别:编程器,开发系统 >> 过时/停产零件编号 系列:- 标准包装:1 系列:- 类型:MCU 适用于相关产品:Freescale MC68HC908LJ/LK(80-QFP ZIF 插口) 所含物品:面板、缆线、软件、数据表和用户手册 其它名称:520-1035
ATAVR-SOAKIT 功能描述:插座和适配器 Standoff Adapter Kit for JTAG debuggers RoHS:否 制造商:Silicon Labs 产品:Adapter 用于:EM35x
ATAVRTEMPSENSORX 功能描述:温度传感器开发工具 Temp Sensor kit for Xplain Series RoHS:否 制造商:Texas Instruments 产品类型:Temperature Sensors and Control ICs 工具用于评估:MSP430G2553 接口类型:USB 工作电源电压: 工作电源电流:
ATAVRTS2080A 功能描述:开发板和工具包 - AVR ATmega88 QTouch QTch kit w/SW librar RoHS:否 制造商:Arduino 产品:Evaluation Boards 工具用于评估:ATMega32U4 核心:AVR 接口类型:I2C, UART, USB 工作电源电压:6 V to 20 V