REDAC HybridController
Firmware for LUCIDAC/REDAC Teensy
Loading...
Searching...
No Matches
factorize.h
Go to the documentation of this file.
1// Copyright (c) 2024 anabrid GmbH
2// Contact: https://www.anabrid.com/licensing/
3//
4// SPDX-License-Identifier: MIT OR GPL-2.0-or-later
5
6#pragma once
7
8#include <utility>
9
10namespace utils {
11
12// This function takes an input and divides it into two number x and y, that multiply to the input number
13// within the given delta range. This is used for FlexIO timing
14std::pair<unsigned long long, unsigned long long> factorize(unsigned long long input,
15 unsigned int acceptable_delta = 10);
16
17} // namespace utils
std::pair< unsigned long long, unsigned long long > factorize(unsigned long long input, unsigned int acceptable_delta=10)
Definition factorize.cpp:12