text stringlengths 1 24.5M |
|---|
#ifdef ATT_OS_WINDOWS
# include "IPC.hpp"
# include "utils/Error.hpp"
# include "utils/Log.hpp"
# define WIN32_LEAN_AND_MEAN
# define NOMINMAX
# include <Windows.h>
namespace IPC
{
constexpr int SEC_TO_MS = 1000;
WindowsNamedPipe::WindowsNamedPipe(std::string pipeName)
: mPipeName(R"(\\.\pipe... |
#pragma once
namespace math
{
constexpr double PI = 3.14159265358979323846;
} // namespace math
|
#pragma once
#include "config/VideoStream.hpp"
#include "CVTypes.hpp"
#include "Helpers.hpp"
#include "utils/Error.hpp"
#include <array>
namespace math
{
struct EstimatePoseSingleMarkersResult
{
std::vector<cv::Vec3d> positions;
std::vector<cv::Vec3d> rotations;
};
// This function receives the detected ma... |
#pragma once
#include "utils/StrongType.hpp"
#include <opencv2/aruco.hpp>
#include <opencv2/core/affine.hpp>
#include <opencv2/core/mat.hpp>
#include <opencv2/core/matx.hpp>
#include <opencv2/core/quaternion.hpp>
#include <opencv2/core/types.hpp>
#include <vector>
namespace math
{
namespace detail
{
// clang-form... |
/*
License information for PS3EYEDriver
------------------------------------
The license of the PS3EYEDriver is MIT (for newly-written code) and GPLv2 for
all code derived from the Linux Kernel Driver (ov534) sources.
In https://github.com/inspirit/PS3EYEDriver/pull/3, Eugene Zatepyakin writes:
"all of my code ... |
/*
License information for PS3EYEDriver
------------------------------------
The license of the PS3EYEDriver is MIT (for newly-written code) and GPLv2 for
all code derived from the Linux Kernel Driver (ov534) sources.
In https://github.com/inspirit/PS3EYEDriver/pull/3, Eugene Zatepyakin writes:
"all of my code ... |
/*
Copyright 2015 Chadwick Boulay
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
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software... |
/*
Copyright 2015 Chadwick Boulay
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
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software... |
#pragma once
#include "Serial.hpp"
#include "utils/Macros.hpp"
#include "utils/Reflectable.hpp"
#define ATT_DETAIL_SERIAL_COMMENT(p_str, p_counter) \
REFLECTABLE_FIELD_DATA_COUNTER_(const ::serial::Comment, ATT_CONCAT(_srl_comment_, p_counter), p_counter)... |
#include "CustomSerial.hpp"
void serial::Serial<cv::Ptr<cv::aruco::DetectorParameters>>::Format(FileStorageWriter& ctx, const cv::Ptr<cv::aruco::DetectorParameters>& value)
{
// Aruco parameters.
ctx.WriteKey("adaptiveThreshWinSizeMin", value->adaptiveThreshWinSizeMin);
ctx.WriteKey("adaptiveThreshWinSizeM... |
#pragma once
#include "FileStorage.hpp"
#include "SemVer.h"
#include "Serial.hpp"
#include "utils/Error.hpp"
#include "utils/Reflectable.hpp"
#include <opencv2/aruco.hpp>
#include <opencv2/core/persistence.hpp>
#include <array>
#include <memory>
#include <string>
#include <type_traits>
#include <vector>
namespace s... |
#include "FileStorage.hpp"
#include "utils/Assert.hpp"
namespace serial
{
bool FileStorage::Open(const fsys::path& filePath, Mode mode)
{
ATT_ASSERT(!filePath.empty());
ATT_ASSERT(filePath.has_parent_path());
cv::FileStorage::Mode storageMode = cv::FileStorage::Mode::READ;
if (mode == Mode::Read)
... |
#pragma once
#include "Serial.hpp"
#include "utils/Assert.hpp"
#include <opencv2/core/mat.hpp>
#include <opencv2/core/persistence.hpp>
#include <opencv2/core/types.hpp>
#include <filesystem>
#include <iterator>
#include <ranges>
template <>
struct std::iterator_traits<cv::FileNodeIterator>
{
using difference_ty... |
#pragma once
#include <ranges>
#include <string_view>
namespace serial
{
// template <>
// struct serial::Serial<T>
// {
// static void Parse(auto& ctx, T& value) {}
// static void Format(auto& ctx, const T& value) {}
// };
template <typename T>
struct Serial;
enum class Nest
{
Expand,
Compact
};
t... |
#pragma once
#include "CustomSerial.hpp"
#include "FileStorage.hpp"
#include "utils/Log.hpp"
#include "utils/Reflectable.hpp"
#include <exception>
namespace serial
{
namespace fsys = std::filesystem;
template <typename T>
inline bool TryWriteFile(const T& value, const fsys::path& filePath)
{
FileStorage fs{};
... |
#include "GUI.hpp"
#include "utils/Assert.hpp"
class GUI::MainFrame
{
public:
MainFrame(RefPtr<ITrackerControl> _tracker, const Localization& _lc, UserConfig& _config) {}
};
GUI::GUI(RefPtr<ITrackerControl> _tracker, const Localization& _lc, UserConfig& _config)
: impl(new MainFrame(_tracker, _lc, _config))
{... |
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <utils/Test.hpp>
|
#pragma once
#include "AprilTagWrapper.hpp"
#include "GUI.hpp"
#include "OpenVRClient.hpp"
#include "PlayspaceCalib.hpp"
#include "RefPtr.hpp"
#include "TrackerUnit.hpp"
#include "VideoCapture.hpp"
#include "VRDriver.hpp"
namespace tracker
{
class MainLoopRunner
{
static constexpr int DRAW_IMG_SIZE = 480; // TOD... |
#include "OpenVRClient.hpp"
#include "Helpers.hpp"
#include "utils/Env.hpp"
#include <optional>
#include <stdexcept>
#include <string>
namespace
{
inline void ThrowVRError(vr::EVRInitError ec)
{
throw std::runtime_error(vr::VR_GetVRInitErrorAsEnglishDescription(ec));
}
inline void ThrowVRError(vr::EVRInputError... |
#pragma once
#include "Helpers.hpp"
#include <opencv2/core/types.hpp>
#include <openvr.h>
namespace tracker
{
enum class ButtonAction
{
None,
GrabCamera,
GrabTrackers
};
class IVRClient
{
public:
virtual ~IVRClient() = default;
virtual bool CanInit() const { return true; } /// fast check if ini... |
#pragma once
#include "config/ManualCalib.hpp"
#include "GUI.hpp"
#include "OpenVRClient.hpp"
#include "RefPtr.hpp"
#include "TrackerUnit.hpp"
#include "utils/SteadyTimer.hpp"
#include "VRDriver.hpp"
namespace tracker
{
class PlayspaceCalib
{
public:
void Set(const cv::Vec3d& posOffset, const cv::Vec3d& angleOff... |
#pragma once
#include "config/TrackerUnit.hpp"
#include "Helpers.hpp"
#include "math/CVHelpers.hpp"
#include "math/CVTypes.hpp"
#include "utils/Error.hpp"
#include "utils/Types.hpp"
#include <vector>
namespace tracker
{
class TrackerUnit
{
using MarkersList = std::vector<MarkerCorners3f>;
using IdsList = st... |
#include "VideoCapture.hpp"
#include "utils/Assert.hpp"
#include "utils/Log.hpp"
#include "utils/SteadyTimer.hpp"
#include "utils/Test.hpp"
#include <ps3eye/PSEyeVideoCapture.h>
#include <charconv>
#include <memory>
#include <optional>
#include <sstream>
#include <stdexcept>
#include <string>
#include <string_view>
... |
#pragma once
#include "config/VideoStream.hpp"
#include "RefPtr.hpp"
#include "utils/Concepts.hpp"
#include "utils/SteadyTimer.hpp"
#include <opencv2/core.hpp>
#include <opencv2/videoio.hpp>
#include <condition_variable>
#include <memory>
#include <mutex>
namespace tracker
{
struct CapturedFrame
{
cv::Mat imag... |
#include "VRDriver.hpp"
#include "SemVer.h"
#include "utils/Env.hpp"
#include "utils/Error.hpp"
#include "utils/Test.hpp"
#include <sstream>
#include <stdexcept>
#include <string>
inline std::ostream& operator<<(std::ostream& os, const Pose& pose)
{
return os << pose.position.x << ' '
<< pose.posit... |
#pragma once
#include "config/List.hpp"
#include "config/TrackerUnit.hpp"
#include "Helpers.hpp"
#include "IPC/IPC.hpp"
#include "utils/Enum.hpp"
#include <memory>
#include <optional>
#include <string_view>
namespace tracker
{
class VRDriver
{
public:
explicit VRDriver(const cfg::List<cfg::TrackerUnit>& tracker... |
#pragma once
#include "Cross.hpp"
#include "Log.hpp" // IWYU pragma: keep
#ifdef ATT_TESTING
# include "Test.hpp"
#endif
// the strings are not comptime combined to prevent duplicates in binary
/// log an assertion failure, the separate LogValues for __VA_ARGS__ allows for empty message
#define ATT_DETAIL_ASSERT_... |
#pragma once
#include <concepts> // IWYU pragma: keep
namespace utils
{
template <typename T, typename... TArgs>
concept Callable = std::is_invocable_v<T, TArgs...>;
template <typename T, typename TResult, typename... TArgs>
concept CallableR = std::is_invocable_r_v<TResult, T, TArgs...>;
template <typename T1, typ... |
#pragma once
#ifdef ATT_DEBUG
# include "Test.hpp" // IWYU pragma: keep
#endif
#include <cstdlib> // IWYU pragma: keep
// function signature
#if defined(ATT_COMP_CLANG) || defined(ATT_COMP_GCC)
# define ATT_PRETTY_FUNCTION __PRETTY_FUNCTION__
#elif defined(ATT_COMP_MSVC)
# define ATT_PRETTY_FUNCTION __FUNCS... |
#pragma once
#include <algorithm>
#include <array>
#include <optional>
#include <ranges>
#include <string_view>
#include <type_traits>
#define ATT_ENUM(p_name, ...) \
enum class p_name ... |
#include "Env.hpp"
#include "Cross.hpp"
#include <cstdlib>
#include <mutex>
#include <string_view>
namespace
{
constexpr bool StringToBool(std::string_view value)
{
if (value.empty())
return false;
if (value.size() == 1 && value[0] == '0')
return false;
return value[0] != 'f' && value[0]... |
#pragma once
#include "SemVer.h"
#include "StringLiteral.hpp"
#include "utils/Macros.hpp"
#include <chrono>
#include <filesystem>
#include <mutex>
#include <optional>
#include <string>
#include <thread>
#include <unordered_map>
namespace utils
{
using system_clock = std::chrono::system_clock;
namespace fs = std::fil... |
#pragma once
#include "Log.hpp"
#include <source_location>
#include <sstream>
#include <stdexcept>
#include <string>
namespace utils
{
namespace detail
{
template <typename... TArgs>
inline std::string FormatError(const TArgs&... args) noexcept
{
try
{
std::ostringstream ss{}; // NOLINT(misc-const-... |
#include "Log.hpp"
#include "Env.hpp"
#include <iomanip>
namespace utils
{
void LogPrelude(LogTag tag) noexcept
{
LogValues('[',
detail::LogTagToString(tag),
": ");
if (const auto threadName = GetThisThreadName())
{
LogValues(*threadName);
}
else
{
... |
#pragma once
#include "Macros.hpp"
#include "StringLiteral.hpp"
#include <array>
#include <iostream>
#include <source_location>
#include <string_view>
// Macros and functions for logging
// Log verbosity levels, choose what gets printed to stderr
/// No logging (except assertion fails)
#define ATT_LOG_LEVEL_SILENT ... |
#pragma once
#include "Log.hpp"
#include "SteadyTimer.hpp"
#include "StringLiteral.hpp"
#include <mutex>
#include <sstream>
#include <string>
#include <unordered_map>
#if ATT_LOG_LEVEL >= ATT_LOG_LEVEL_DEBUG
# define ATT_LOG_BATCH(p_name, p_value) ::utils::detail::LogBatch(__FILE__, __LINE__, p_name, p_value)
#el... |
#include "LogFileHandler.hpp"
#include "Env.hpp"
#include "Log.hpp"
#include <filesystem>
namespace utils
{
namespace fsys = std::filesystem;
void LogFileHandler::RedirectConsoleToFile()
{
const fsys::path logsDir = GetLogsDir();
if (!fsys::exists(logsDir)) fsys::create_directory(logsDir);
const fsys::... |
#pragma once
#include <fstream>
#include <streambuf>
#include <string>
namespace utils
{
class LogFileHandler
{
public:
void RedirectConsoleToFile();
void CloseAndTimestampFile();
private:
static void TimestampFile();
static std::string GetLogFileName(std::string_view tag);
static std::string G... |
#pragma once
#define ATT_DETAIL_CONCAT(a, b) a##b
#define ATT_CONCAT(a, b) ATT_DETAIL_CONCAT(a, b)
#define ATT_DETAIL_STRINGIZE(a) #a
#define ATT_STRINGIZE(a) ATT_DETAIL_STRINGIZE(a)
#define ATT_NOOP() static_cast<void>(0)
#define ATT_SFINAE_TYPE_TRAIT(p_name, p_tType, p_tName, ...) \
template <p_t... |
#pragma once
#include "Macros.hpp"
#include <concepts>
#include <cstddef>
#include <type_traits>
#include <utility>
/// Placed in a class before a list of REFLECTABLE_FIELDs
#define REFLECTABLE_BEGIN \
friend class ::Reflect; \
template <std::size_t N, typename = void> \... |
#pragma once
#include "utils/Assert.hpp"
#include <chrono>
using std::chrono::duration_cast;
namespace utils
{
using NanoS = std::chrono::nanoseconds;
using MilliS = std::chrono::milliseconds;
using Seconds = std::chrono::seconds;
using FSeconds = std::chrono::duration<double>;
template <typename TDuration>
const... |
#pragma once
#include "utils/Cross.hpp"
#include <string_view>
namespace utils
{
template <std::size_t Length>
requires(Length >= 1)
using RawStringLiteral = const char(&)[Length]; // NOLINT(*c-arrays):
template <typename T>
concept IsRawStringLiteral = std::same_as<T, RawStringLiteral<std::extent_v<std::remov... |
#pragma once
#include "serial/Serial.hpp"
#include <concepts>
#include <ratio>
#include <utility>
#include <vector>
namespace utils
{
template <typename T>
concept UniqueTag = !requires { sizeof(T); };
template <typename T, UniqueTag>
struct StrongType
{
using Type = T;
/// list of strong types has the sa... |
#pragma once
#ifndef ATT_TESTING
# define DOCTEST_CONFIG_DISABLE
#endif
#define DOCTEST_CONFIG_NO_SHORT_MACRO_NAMES
#include <doctest/doctest.h>
// more info: https://github.com/doctest/doctest/tree/master/doc/markdown
/// declare a test case, behaves like function body e.g. TEST_CASE("foo") { foo; bar; }
#define... |
// from https://bitwizeshift.github.io/posts/2021/03/09/getting-an-unmangled-type-name-at-compile-time/
#include <array>
#include <string_view>
#include <utility>
namespace utils
{
namespace detail
{
template <std::size_t... Idxs>
constexpr auto SubstringAsArray(std::string_view str, std::index_sequence<Idxs...>)
{... |
#pragma once
#include <cstddef>
namespace utils
{
// set `cppcoreguidelines-narrowing-conversions.IgnoreConversionFromTypes: size_t;size_type`
// in .clang-tidy to silence some warnings for unsigned to signed conversion when using this type
using Index = std::ptrdiff_t;
}; // namespace utils
using utils::Index;
|
#pragma once
#include <array>
#include <iostream>
#include <sstream>
#include <stdexcept>
#include <string>
#include <string_view>
class SemVer
{
public:
constexpr SemVer(int _major = 0, int _minor = 0, int _patch = 0) noexcept
: major(_major), minor(_minor), patch(_patch)
{
}
/// Parse "majo... |
#pragma once
//
// FILE: 74HC138.h
// AUTHOR: Rob Tillaart
// DATE: 2024-02-22
// VERSION: 0.1.1
// PURPOSE: Arduino library for the 74HC138 3-to-8 line decoder/demultiplexer.
// URL: https://github.com/RobTillaart/74HC138
#include "Arduino.h"
#define LIB_74HC138_VERSION (F("0.1.1"))
class DEV_... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2024-02-22
// PURPOSE: unit tests for the ACD10 library
// URL: https://github.com/RobTillaart/74HC138
//
// supported assertions
// https://github.com/Arduino-CI/arduino_ci/blob/master/cpp/unittest/Assertion.h#L33-L42
// -----------------------... |
#pragma once
//
// FILE: 74HC154.h
// AUTHOR: Rob Tillaart
// DATE: 2024-02-22
// VERSION: 0.2.0
// PURPOSE: Arduino library for the 74HC154 4-to-16 line decoder/demultiplexer.
// URL: https://github.com/RobTillaart/74HC154
#include "Arduino.h"
#define LIB_74HC154_VERSION (F("0.2.0"))
class DEV... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2024-02-23
// PURPOSE: unit tests for the 74HC154 library
// URL: https://github.com/RobTillaart/74HC154
//
// supported assertions
// https://github.com/Arduino-CI/arduino_ci/blob/master/cpp/unittest/Assertion.h#L33-L42
// ---------------------... |
#pragma once
//
// FILE: 74HC590.h
// AUTHOR: Rob Tillaart
// DATE: 2025-04-30
// VERSION: 0.1.0
// PURPOSE: Arduino library for the 54HC590 / 74HC590 binary counter
// URL: https://github.com/RobTillaart/74HC590
#include "Arduino.h"
#define LIB_74HC590_VERSION (F("0.1.0"))
class DEV_74HC590
{
... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2025-04-30
// PURPOSE: unit tests for the 74HC590 library
// URL: https://github.com/RobTillaart/74HC590
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// https://github.com/Arduino-CI/ar... |
//
// FILE: A1301.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.3.0
// DATE: 2010-07-22
// PURPOSE: Arduino library for A1301 A1302 magnetometer.
// URL: https://github.com/RobTillaart/A1301
#include "A1301.h"
/////////////////////////////////////////////////////////////////////////////
//
// CONSTRUCTOR
//... |
#pragma once
//
// FILE: A1301.h
// AUTHOR: Rob Tillaart
// VERSION: 0.3.0
// DATE: 2010-07-22
// PURPOSE: Arduino library for A1301 A1302 magnetometer.
// URL: https://github.com/RobTillaart/A1301
// always check datasheet.
// PIN A1301
// ===============
// 1 GND
// 2 DATA
// ... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2022-12-01
// PURPOSE: unit tests for the A1301 magnetic sensor
// URL: https://github.com/RobTillaart/A1301
// https://www.adafruit.com/product/2857
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// su... |
//
// FILE: ACD10.cpp
// AUTHOR: Rob Tillaart
// DATE: 2023-09-25
// VERSION: 0.2.2
// PURPOSE: Arduino library for for I2C ACD10 CO2 sensor
// URL: https://github.com/RobTillaart/ACD10
// http://www.aosong.com/en/products-77.html
#include "ACD10.h"
ACD10::ACD10(TwoWire *wire)
{
_wire = wire;
... |
#pragma once
//
// FILE: ACD10.h
// AUTHOR: Rob Tillaart
// DATE: 2023-09-25
// VERSION: 0.2.2
// PURPOSE: Arduino library for for I2C ACD10 CO2 sensor
// URL: https://github.com/RobTillaart/ACD10
// http://www.aosong.com/en/products-77.html
#include "Arduino.h"
#include "Wire.h"
#define ACD10_L... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2023-09-25
// PURPOSE: unit tests for the ACD10 library
// URL: https://github.com/RobTillaart/ACD10
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// https://github.com/Arduino-CI/arduin... |
//
// FILE: ACD3100.cpp
// AUTHOR: Rob Tillaart
// DATE: 2024-10-29
// VERSION: 0.1.2
// PURPOSE: Arduino library for I2C ACD3100 CO2 sensor
// URL: https://github.com/RobTillaart/ACD3100
// http://www.aosong.com/products-220.html
#include "ACD3100.h"
ACD3100::ACD3100(TwoWire *wire)
{
_wire = ... |
#pragma once
//
// FILE: ACD3100.h
// AUTHOR: Rob Tillaart
// DATE: 2024-10-29
// VERSION: 0.1.2
// PURPOSE: Arduino library for I2C ACD3100 CO2 sensor
// URL: https://github.com/RobTillaart/ACD3100
// http://www.aosong.com/products-220.html
#include "Arduino.h"
#include "Wire.h"
#define ACD3100... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2023-09-25
// PURPOSE: unit tests for the ACD3100 library
// URL: https://github.com/RobTillaart/ACD3100
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// https://github.com/Arduino-CI/ar... |
//
// FILE: ACS712.cpp
// AUTHOR: Rob Tillaart, Pete Thompson
// VERSION: 0.3.10
// DATE: 2020-08-02
// PURPOSE: ACS712 library - current measurement
// URL: https://github.com/RobTillaart/ACS712
#include "ACS712.h"
// CONSTRUCTOR
ACS712::ACS712(uint8_t analogPin, float volts, uint16_t maxADC, float mVp... |
#pragma once
//
// FILE: ACS712.h
// AUTHOR: Rob Tillaart, Pete Thompson
// VERSION: 0.3.10
// DATE: 2020-08-02
// PURPOSE: ACS712 library - current measurement
// URL: https://github.com/RobTillaart/ACS712
//
// Tested with a RobotDyn ACS712 20A breakout + UNO.
//
#include "Arduino.h"
#define ACS712_LIB... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2020-12-06
// PURPOSE: unit tests for the ACS712 current sensor
// https://github.com/RobTillaart/ACS712
// https://www.adafruit.com/product/2857
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// s... |
//
// FILE: AD5144A.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.4.0
// PURPOSE: I2C digital potentiometer AD5144A
// DATE: 2021-04-30
// URL: https://github.com/RobTillaart/AD5144A
//
// Datasheet: REV-C 7/2019
#include "AD5144A.h"
// Commands page 29 datasheet
//
// not implemented (yet)
// 0 NO... |
#pragma once
//
// FILE: AD5144A.h
// AUTHOR: Rob Tillaart
// VERSION: 0.4.0
// PURPOSE: I2C digital PotentioMeter AD5144A
// DATE: 2021-04-30
// URL: https://github.com/RobTillaart/AD5144A
//
// Datasheet: REV-C 7/2019
#include "Arduino.h"
#include "Wire.h"
#define AD51XXA_VERSION (F("0.4.0"... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2021-04-30
// PURPOSE: unit tests for I2C digital PotentioMeter AD5144A
// https://github.com/RobTillaart/AD5144A
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// ------------------... |
//
// FILE: AD520X.cpp
// AUTHOR: Rob Tillaart
// DATE: 2020-07-24
// VERSION: 0.5.1
// PURPOSE: Arduino library for AD5204 and AD5206 digital potentiometers
// (+ AD8400, AD8402, AD8403)
// URL: https://github.com/RobTillaart/AD520X
#include "AD520X.h"
// HARDWARE SPI
AD520X::AD520X(uint8_t se... |
#pragma once
//
// FILE: AD520X.h
// AUTHOR: Rob Tillaart
// DATE: 2020-07-24
// VERSION: 0.5.1
// PURPOSE: Arduino library for AD5204 and AD5206 digital potentiometers
// (+ AD8400, AD8402, AD8403)
// URL: https://github.com/RobTillaart/AD520X
#include "Arduino.h"
#include "SPI.h"
#define AD520... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.1.0
// DATE: 2020-12-08
// PURPOSE: unit tests for the AD520X digital potentiometers
// https://github.com/RobTillaart/AD520X
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// -... |
//
// FILE: AD523X.cpp
// AUTHOR: Rob Tillaart
// DATE: 2024-11-21
// VERSION: 0.1.0
// PURPOSE: Arduino library for SPI AD5231 and AD5235 10 bit digital potentiometers.
// URL: https://github.com/RobTillaart/AD523X
#include "AD523X.h"
// HARDWARE SPI
AD523X::AD523X(uint8_t select, uint8_t reset, __SPI_... |
#pragma once
//
// FILE: AD523X.h
// AUTHOR: Rob Tillaart
// DATE: 2024-11-21
// VERSION: 0.1.0
// PURPOSE: Arduino library for SPI AD5231 and AD5235 10 bit digital potentiometers.
// URL: https://github.com/RobTillaart/AD523X
#include "Arduino.h"
#include "SPI.h"
#define AD523X_LIB_VERSION ... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.1.0
// DATE: 2024-11-22
// PURPOSE: unit tests for the AD523X digital potentiometers
// https://github.com/RobTillaart/AD523X
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// -... |
//
// FILE: AD5245.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.4.0
// PURPOSE: Arduino library for I2C digital potentiometer AD5245.
// DATE: 2022-07-31
// URL: https://github.com/RobTillaart/AD5245
#include "AD5245.h"
#define AD5245_WRITE 0x00
#define AD5245_RESET 0x40
#define AD5245... |
#pragma once
//
// FILE: AD5245.h
// AUTHOR: Rob Tillaart
// VERSION: 0.4.0
// PURPOSE: Arduino library for I2C digital potentiometer AD5245.
// DATE: 2022-07-31
// URL: https://github.com/RobTillaart/AD5245
//
// Experimental
#include "Arduino.h"
#include "Wire.h"
#define AD5245_LIB_VERSION (F... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2022-07-31
// PURPOSE: unit tests for I2C digital PotentioMeter AD5245
// https://github.com/RobTillaart/AD5245
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// --------------------... |
//
// FILE: AD5246.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.2.1
// PURPOSE: Arduino Library for AD5246, I2C 128 step rheostat.
// DATE: 2023-08-02
// URL: https://github.com/RobTillaart/AD5246
#include "AD5246.h"
AD5246::AD5246(TwoWire *wire)
{
// fixed address 0x2E.
_wire = wire;
// power on re... |
#pragma once
//
// FILE: AD5246.h
// AUTHOR: Rob Tillaart
// VERSION: 0.2.1
// PURPOSE: Arduino Library for AD5246, I2C 128 step rheostat.
// DATE: 2023-08-02
// URL: https://github.com/RobTillaart/AD5246
// experimental - to be tested - use at own risk
#include "Arduino.h"
#include "Wire.h"
#define AD5... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2023-08-02
// PURPOSE: unit tests for I2C digital rheostat AD5246
// https://github.com/RobTillaart/AD5246
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// -------------------------... |
//
// FILE: AD5248.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.1.1
// PURPOSE: Library for I2C digital potentiometer AD5243 + rheostat AD5248
// DATE: 2023-12-12
// URL: https://github.com/RobTillaart/AD5248
#include "AD5248.h"
#define AD5248_RDAC0 0x00
#define AD5248_RDAC1 0x80
#define AD524... |
#pragma once
//
// FILE: AD5248.h
// AUTHOR: Rob Tillaart
// VERSION: 0.1.1
// PURPOSE: Library for I2C digital potentiometer AD5243 + rheostat AD5248
// DATE: 2023-12-12
// URL: https://github.com/RobTillaart/AD5248
#include "Arduino.h"
#include "Wire.h"
#define AD5248_LIB_VERSION (F("0.1.1"))
#def... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2023-12-12
// PURPOSE: unit tests for I2C digital PotentioMeter AD5243 + rheostat AD5248
// https://github.com/RobTillaart/AD5243_RT
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
//... |
//
// FILE: AD524X.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.5.2
// PURPOSE: I2C digital potentiometer AD5241 AD5242
// DATE: 2013-10-12
// URL: https://github.com/RobTillaart/AD524X
#include "AD524X.h"
#define AD524X_RDAC0 0x00
#define AD524X_RDAC1 0x80
#define AD524X_RESET 0x40
#de... |
#pragma once
//
// FILE: AD524X.h
// AUTHOR: Rob Tillaart
// VERSION: 0.5.2
// PURPOSE: I2C digital PotentioMeter AD5241 AD5242
// DATE: 2013-10-12
// URL: https://github.com/RobTillaart/AD524X
#include "Arduino.h"
#include "Wire.h"
#define AD524X_LIB_VERSION (F("0.5.2"))
#define AD524X_OK ... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2020-12-03
// PURPOSE: unit tests for I2C digital PotentioMeter AD5241 AD5242
// https://github.com/RobTillaart/AD524X
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// -------------... |
//
// FILE: AD5263.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.1.3
// PURPOSE: Arduino library for I2C digital potentiometer AD5263 and compatibles.
// DATE: 2023-10-09
// URL: https://github.com/RobTillaart/AD5263
#include "AD5263.h"
#define AD5263_RDAC0 0x00
#define AD5263_RDAC1 0x20
#defin... |
#pragma once
//
// FILE: AD5263.h
// AUTHOR: Rob Tillaart
// VERSION: 0.1.3
// PURPOSE: Arduino library for I2C digital potentiometer AD5263 and compatibles.
// DATE: 2023-10-09
// URL: https://github.com/RobTillaart/AD5263
// based upon AD524X interface.
#include "Arduino.h"
#include "Wire.h"
#... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2023-01-09
// PURPOSE: unit tests for I2C digital potentiometer AD5263 and compatibles.
// https://github.com/RobTillaart/AD5263
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// --... |
//
// FILE: AD5370.cpp
// AUTHOR: Rob Tillaart
// DATE: 2025-02-24
// VERSION: 0.1.0
// PURPOSE: Arduino library for AD5370
// URL: https://github.com/RobTillaart/AD5370
// http://www.aosong.com/en/products-77.html
#include "AD5370.h"
/////////////////////////////////////////////
//
// CONSTRUC... |
#pragma once
//
// FILE: AD5370.h
// AUTHOR: Rob Tillaart
// DATE: 2025-02-24
// VERSION: 0.1.0
// PURPOSE: Arduino library for
// URL: https://github.com/RobTillaart/AD5370
//
#include "Arduino.h"
#include "SPI.h"
#define AD5370_LIB_VERSION (F("0.1.0"))
#ifndef __SPI_CLASS__
// MBED must be t... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2025-02-24
// PURPOSE: unit tests for the AD5370 library
// URL: https://github.com/RobTillaart/AD5370
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// https://github.com/Arduino-CI/ardu... |
//
// FILE: AD5593R.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.1.1
// DATE: 2024-01-30
// PURPOSE: Arduino library for AD5593R, I2C, 8 channel ADC / DAC / GPIO device.
// URL: https://github.com/RobTillaart/AD5593R
#include "AD5593R.h"
// CONFIG REGISTERS (aka pointer bytes)
#define AD5593_NOP ... |
#pragma once
//
// FILE: AD5593R.h
// AUTHOR: Rob Tillaart
// VERSION: 0.1.1
// DATE: 2024-01-30
// PURPOSE: Arduino library for AD5593R, I2C, 8 channel ADC / DAC / GPIO device.
// URL: https://github.com/RobTillaart/AD5593R
//
// read datasheet for details.
#include "Arduino.h"
#include "Wire.h"
#defin... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.1.0
// DATE: 2024-11-27
// PURPOSE: unit tests for the AD5933R IO device
// https://github.com/RobTillaart/AD5933R
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// ------------... |
//
// FILE: AD5620.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.3.0
// DATE: 2024-10-25
// PURPOSE: Arduino library for AD5620 / AD5640 Digital Analog Convertor (12/14 bit).
#include "AD5620.h"
// HARDWARE SPI
AD5620::AD5620(uint8_t slaveSelect, __SPI_CLASS__ * mySPI)
{
_select = slaveSelect;
_hwSPI ... |
#pragma once
//
// FILE: AD5620.h
// AUTHOR: Rob Tillaart
// VERSION: 0.3.0
// DATE: 2024-10-25
// PURPOSE: Arduino library for AD5620 / AD5640 Digital Analog Convertor (12/14 bit).
#include "Arduino.h"
#include "SPI.h"
#define AD5620_LIB_VERSION (F("0.3.0"))
#ifndef __SPI_CLASS__
// MBED must be t... |
//
// FILE: unit_test_001.cpp
// AUTHOR: Rob Tillaart
// DATE: 2024-10-25
// PURPOSE: unit tests for the AD5620 DA convertor.
// https://github.com/RobTillaart/AD5620
// https://github.com/Arduino-CI/arduino_ci/blob/master/REFERENCE.md
//
// supported assertions
// ----------------------------... |
//
// FILE: AD5660.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.2.0
// DATE: 2024-10-29
// PURPOSE: Arduino library for AD5660 Digital Analog Convertor (16 bit).
#include "AD5660.h"
// HARDWARE SPI
AD5660::AD5660(uint8_t slaveSelect, __SPI_CLASS__ * mySPI)
{
_select = slaveSelect;
_hwSPI = true;
_... |
#pragma once
//
// FILE: AD5660.h
// AUTHOR: Rob Tillaart
// VERSION: 0.2.0
// DATE: 2024-10-29
// PURPOSE: Arduino library for AD5660 Digital Analog Convertor (16 bit).
#include "Arduino.h"
#include "SPI.h"
#define AD5660_LIB_VERSION (F("0.2.0"))
#ifndef __SPI_CLASS__
// MBED must be tested befor... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.