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 debian:unstable | |
ENV DEBIAN_FRONTEND=noninteractive | |
RUN apt update \ | |
&& apt install -y \ | |
autoconf \ | |
bison \ | |
build-essential \ | |
curl \ |
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 typing import Union | |
import asyncio | |
from bleak import BleakClient | |
from bleak.backends.device import BLEDevice | |
async def main(address: Union[BLEDevice, str]) -> None: | |
async with BleakClient(address) as client: | |
await client.pair() |
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
// Wire Master Writer | |
// by Nicholas Zambetti <http://www.zambetti.com> | |
// Demonstrates use of the Wire library | |
// Writes data to an I2C/TWI Peripheral device | |
// Refer to the "Wire Peripheral Receiver" example for use with this | |
// Created 29 March 2006 | |
// This example code is in the public domain. |
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
export LG_ENV=$(pwd)/inventory.yaml |
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
#include <csignal> | |
#include <chrono> | |
#include <iostream> | |
#include <optional> | |
#include <thread> | |
#include <variant> | |
template <class Context, class... States> class FSM { | |
public: |
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
#include <csignal> | |
#include <cstdlib> | |
#include <ctime> | |
#include <atomic> | |
#include <chrono> | |
#include <iostream> | |
#include <optional> | |
#include <thread> | |
#include <variant> |
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
file=$(cat env) | |
for line in $file; do | |
export "${line}" | |
done |
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
#include <stddef.h> | |
#include <stdio.h> | |
typedef void MyFunc(void); | |
typedef struct { | |
int a; | |
int b; | |
MyFunc *c; | |
} MyTransition; |
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
#include <stddef.h> | |
#include <stdio.h> | |
typedef struct { | |
int a; | |
int b; | |
} MyLine; | |
typedef struct { | |
MyLine const *firstElement; |
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
#include <algorithm> | |
#include <atomic> | |
#include <chrono> | |
#include <condition_variable> | |
#include <functional> | |
#include <iostream> | |
#include <mutex> | |
#include <thread> | |
constexpr size_t const NUM_WORKER_THREADS = 3; |