Moved to raldone01/config_fish.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from time import perf_counter_ns | |
# Derived from https://github.com/godunko/scd40-sandbox/blob/893654c479f64c9078e839a6242d53695bddb9d3/documentation/NOTES.md?plain=1#L8 | |
# Thank you for doing the hard work, godunko! | |
# Clock definitions | |
HCLK = 216_000_000 # 216 MHz in Hz | |
FMCCLK = HCLK / 2 # FMC clock derived from HCLK | |
T_FMCCLK = 1 / FMCCLK # FMC clock period in seconds | |
T_FMCCLK_ns = T_FMCCLK * 1e9 # FMC clock period in nanoseconds |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import argparse | |
import cv2 | |
import numpy as np | |
import os | |
import sys | |
import logging # Step 2: Import the logging library | |
# Initialize logging | |
logging.basicConfig(level=logging.INFO) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cmake_minimum_required(VERSION 3.10.2) | |
project(c_lcm) | |
set(CMAKE_CXX_STANDARD 17) | |
add_executable(c_lcm main.cpp) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
interface Parent { | |
/** | |
* This property is null when this isn't attached to anything. | |
*/ | |
val parent: Parent? | |
val children: List<Parent> | |
/** | |
* @throws NoMutationAllowedException |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
timespec timespecDiff(timespec start, timespec stop) { | |
timespec ret; | |
ret.tv_sec = stop.tv_sec - start.tv_sec; | |
if(start.tv_nsec > stop.tv_nsec) { | |
ret.tv_nsec = 1000000000 - start.tv_nsec + stop.tv_nsec; | |
ret.tv_sec--; | |
} else | |
ret.tv_nsec = stop.tv_nsec - start.tv_nsec; | |
return ret; | |
} |