Commit b5ba0c1d authored by Thomas Schöpping's avatar Thomas Schöpping
Browse files

Merge remote-tracking branch 'origin/vl53l1x'

parents 2be7977c 8941e612
This diff is collapsed.
/*
AMiRo-LLD is a compilation of low-level hardware drivers for the Autonomous Mini Robot (AMiRo) platform.
Copyright (C) 2016..2020 Thomas Schöpping et al.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* @file alld_VL53L1X.h
* @brief ToF sensor macros and structures.
*
* @addtogroup lld_vl53l1x
* @{
*/
#ifndef AMIROLLD_VL53L1X_H
#define AMIROLLD_VL53L1X_H
#include <amiro-lld.h>
#include <vl53l1_api.h>
/******************************************************************************/
/* CONSTANTS */
/******************************************************************************/
/**
* @brief Maximum I2C frequency (in Hz).
*/
#define VL53L1X_LLD_I2C_MAXFREQUENCY 1000000
/**
* @brief Default I2C address.
*/
#define VL53L1X_LLD_I2C_ADDR_DEFAULT 0x29
/******************************************************************************/
/* SETTINGS */
/******************************************************************************/
/******************************************************************************/
/* CHECKS */
/******************************************************************************/
/******************************************************************************/
/* DATA STRUCTURES AND TYPES */
/******************************************************************************/
/*
* Structures and types are declared in a separate file, because ST API requires
* this information, too.
*/
#include <vl53l1_platform_user_data.h>
/**
* @brief The state of the VL53L1X device.
* @details Represents the state of the XSHUT signal.
*/
typedef enum {
VL53L1X_LLD_STATE_OFF = 0x00, /**< Device is deactivated via XSHUT signal. */
VL53L1X_LLD_STATE_ON = 0x01, /**< Device is active according to XSHUT signal. */
} vl53l1x_lld_state_t;
typedef enum {
VL53L1X_LLD_RM_SHORT = 0,
VL53L1X_LLD_RM_MED = 1,
VL53L1X_LLD_RM_LONG = 2
} vl53l1x_lld_range_mode;
/******************************************************************************/
/* MACROS */
/******************************************************************************/
/******************************************************************************/
/* EXTERN DECLARATIONS */
/******************************************************************************/
#ifdef __cplusplus
extern "C" {
#endif
apalExitStatus_t vl53l1x_lld_getState(VL53L1XDriver* vl53l1x, vl53l1x_lld_state_t* state);
apalExitStatus_t vl53l1x_lld_init(VL53L1XDriver* vl53l1x);
apalExitStatus_t vl53l1x_lld_reset(VL53L1XDriver* vl53l1x);
apalExitStatus_t vl53l1x_lld_setRangemode(VL53L1XDriver* dev, vl53l1x_lld_range_mode mode);
/**
* @brief Start ranging while listening on the
*
* @details detailed description
*
* @param param
*
* @return return type
*/
apalExitStatus_t vl53l1x_lld_start_ranging(VL53L1XDriver* vl53l1x);
#ifdef __cplusplus
}
#endif
/******************************************************************************/
/* INLINE FUNCTIONS */
/******************************************************************************/
#endif /* AMIROLLD_VL53L1X_H */
/** @} */
################################################################################
# AMiRo-LLD is a compilation of low-level hardware drivers for the Autonomous #
# Mini Robot (AMiRo) platform. #
# Copyright (C) 2016..2020 Thomas Schöpping et al. #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
# the Free Software Foundation, either version 3 of the License, or #
# (at your option) any later version. #
# #
# This program is distributed in the hope that it will be useful, #
# but WITHOUT ANY WARRANTY; without even the implied warranty of #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
# GNU General Public License for more details. #
# #
# You should have received a copy of the GNU General Public License #
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
# This research/work was supported by the Cluster of Excellence Cognitive #
# Interaction Technology 'CITEC' (EXC 277) at Bielefeld University, which is #
# funded by the German Research Foundation (DFG). #
################################################################################
# path to this directory
AMIROLLD_ST_VL53L1X := $(dir $(lastword $(MAKEFILE_LIST)))
# include paths
AMIROLLD_INC += $(AMIROLLD_ST_VL53L1X) \
$(AMIROLLD_ST_VL53L1X)/api/core \
$(AMIROLLD_ST_VL53L1X)/api/platform
# C source files
AMIROLLD_CSRC += $(AMIROLLD_ST_VL53L1X)alld_VL53L1X.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_api.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_api_calibration.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_api_core.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_api_debug.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_api_preset_modes.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_api_strings.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_core.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_core_support.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_error_strings.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_register_funcs.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_silicon_core.c \
$(AMIROLLD_ST_VL53L1X)api/core/vl53l1_wait.c
# $(AMIROLLD_ST_VL53L1X)api/platform/vl53l1_platform_log.c
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment