usb_depth_sensor_macos.cpp
Go to the documentation of this file.
1 /*
2  * BSD 3-Clause License
3  *
4  * Copyright (c) 2019, Analog Devices, Inc.
5  * All rights reserved.
6  *
7  * Redistribution and use in source and binary forms, with or without
8  * modification, are permitted provided that the following conditions are met:
9  *
10  * 1. Redistributions of source code must retain the above copyright notice, this
11  * list of conditions and the following disclaimer.
12  *
13  * 2. Redistributions in binary form must reproduce the above copyright notice,
14  * this list of conditions and the following disclaimer in the documentation
15  * and/or other materials provided with the distribution.
16  *
17  * 3. Neither the name of the copyright holder nor the names of its
18  * contributors may be used to endorse or promote products derived from
19  * this software without specific prior written permission.
20  *
21  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
22  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
24  * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
25  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
27  * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
28  * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
29  * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  */
33 
34 struct UsbDepthSensor::ImplData {};
35 
37  const aditof::DeviceConstructionData & /*data*/) {}
38 
40 
42  using namespace aditof;
43  Status status = Status::OK;
44 
45  // TO DO
46 
47  return status;
48 }
49 
51  using namespace aditof;
52  Status status = Status::OK;
53 
54  // TO DO
55 
56  return status;
57 }
58 
60  using namespace aditof;
61  Status status = Status::OK;
62 
63  // TO DO
64 
65  return status;
66 }
67 
69 UsbDepthSensor::getAvailableModeDetails(std::vector<std::string> &types) {
70  using namespace aditof;
71  Status status = Status::OK;
72 
73  // TO DO
74 
75  return status;
76 }
77 
79 UsbDepthSensor::getModeDetailsDetails(const std::string &frameName,
81  using namespace aditof;
82  Status status = Status::OK;
83  // TO DO
84 
85  return status;
86 }
87 
89 UsbDepthSensor::setModeDetails(const aditof::DepthSensorModeDetails &type) {
90  using namespace aditof;
91  Status status = Status::OK;
92 
93  // TO DO
94 
95  return status;
96 }
97 
99  using namespace aditof;
100  Status status = Status::OK;
101 
102  // TO DO
103 
104  return status;
105 }
106 
107 aditof::Status UsbDepthSensor::readAfeTemp(float &temperature) {
108  using namespace aditof;
109  Status status = Status::OK;
110 
111  // TO DO
112 
113  return status;
114 }
115 
116 aditof::Status UsbDepthSensor::readLaserTemp(float &temperature) {
117  using namespace aditof;
118  Status status = Status::OK;
119 
120  // TO DO
121 
122  return status;
123 }
124 
127  using namespace aditof;
128  Status status = Status::OK;
129 
130  // TO DO
131 
132  return status;
133 }
134 
136  using namespace aditof;
137  Status status = Status::OK;
138 
139  // TO DO
140 
141  return status;
142 }
143 
146  LOG(WARNING) << "Registering an interrupt callback on a USB connection "
147  "is not supported yet!";
149 }
150 
151 aditof::Status UsbDepthSensor::getFrameProcessParams(
152  std::map<std::string, std::string> &params) {
153  using namespace aditof;
154  Status status = Status::UNAVAILABLE;
155  return status;
156 }
157 
159  const std::map<std::string, std::string> &params) {
160  using namespace aditof;
161  Status status = Status::UNAVAILABLE;
162  return status;
163 }
164 
167  // TODO: select sensor table configuration
168  return aditof::Status::OK;
169 }
170 
172  std::string &iniStr) {
173 
174  return aditof::Status::OK;
175 }
usb_depth_sensor.h
aditof::SensorDetails
Provides details about the device.
Definition: sensor_definitions.h:50
types
GLsizei GLenum GLenum * types
Definition: glcorearb.h:4177
mode
GLenum mode
Definition: glcorearb.h:2764
string
GLsizei const GLchar *const * string
Definition: glcorearb.h:3083
aditof::Status::UNAVAILABLE
@ UNAVAILABLE
The requested action or resource is unavailable.
WARNING
const int WARNING
Definition: log_severity.h:59
google::protobuf::util::error::UNAVAILABLE
@ UNAVAILABLE
Definition: status.h:62
UsbDepthSensor::getFrame
virtual aditof::Status getFrame(uint16_t *buffer) override
Request a frame from the sensor.
Definition: usb_depth_sensor_linux.cpp:422
UsbDepthSensor::open
virtual aditof::Status open() override
Open the communication channels with the hardware.
Definition: usb_depth_sensor_linux.cpp:115
UsbDepthSensor::getDetails
virtual aditof::Status getDetails(aditof::SensorDetails &details) const override
Get a structure that contains information about the instance of the sensor.
Definition: usb_depth_sensor_linux.cpp:647
aditof
Namespace aditof.
Definition: adsd_errs.h:40
google::protobuf::util::error::OK
@ OK
Definition: status.h:47
UsbDepthSensor::adsd3500_register_interrupt_callback
virtual aditof::Status adsd3500_register_interrupt_callback(aditof::SensorInterruptCallback &cb) override
Register a function to be called when a ADSD3500 interrupt occurs.
Definition: usb_depth_sensor_linux.cpp:996
params
GLenum const GLfloat * params
Definition: glcorearb.h:2770
UsbDepthSensor::start
virtual aditof::Status start() override
Start the streaming of data from the sensor.
Definition: usb_depth_sensor_linux.cpp:183
UsbDepthSensor::~UsbDepthSensor
~UsbDepthSensor()
Definition: usb_depth_sensor_linux.cpp:86
buffer
Definition: buffer_processor.h:43
UsbDepthSensor::getIniParamsArrayForMode
aditof::Status getIniParamsArrayForMode(int mode, std::string &iniStr) override
Get ini parameters for Depth Compute library as string.
Definition: usb_depth_sensor_linux.cpp:1044
aditof::Status
Status
Status of any operation that the TOF sdk performs.
Definition: status_definitions.h:48
type
GLenum type
Definition: glcorearb.h:2695
UsbDepthSensor::getHandle
virtual aditof::Status getHandle(void **handle) override
Gets a handle to be used by other devices such as Storage, Temperature, etc. This handle will allow t...
Definition: usb_depth_sensor_linux.cpp:652
LOG
#define LOG(x)
Definition: sdk/include/aditof/log.h:72
aditof::Status::OK
@ OK
Success.
UsbDepthSensor::setDepthComputeParams
virtual aditof::Status setDepthComputeParams(const std::map< std::string, std::string > &params) override
Set ini parameters for Depth Compute library.
Definition: usb_depth_sensor_linux.cpp:1031
UsbDepthSensor::setSensorConfiguration
virtual aditof::Status setSensorConfiguration(const std::string &sensorConf) override
Set sensor configutation table.
Definition: usb_depth_sensor_linux.cpp:1039
aditof::DepthSensorModeDetails
Describes the type of entire frame that a depth sensor can capture and transmit.
Definition: sensor_definitions.h:120
UsbDepthSensor::stop
virtual aditof::Status stop() override
Stop the sensor data stream.
Definition: usb_depth_sensor_linux.cpp:219
UsbDepthSensor::ImplData
Definition: usb_depth_sensor_linux.cpp:64
UsbDepthSensor::UsbDepthSensor
UsbDepthSensor(const std::string &name, const std::string &driverPath)
Definition: usb_depth_sensor_linux.cpp:74
aditof::SensorInterruptCallback
std::function< void(Adsd3500Status)> SensorInterruptCallback
Callback for sensor interrupts.
Definition: depth_sensor_interface.h:50


libaditof
Author(s):
autogenerated on Wed May 21 2025 02:07:01