Skip to content

Instantly share code, notes, and snippets.

View pabigot's full-sized avatar

Peter A. Bigot pabigot

View GitHub Profile
@pabigot
pabigot / 00README.md
Last active August 29, 2015 13:55
Support for Diagnostics in Template Metaprogramming
@pabigot
pabigot / 00README.md
Last active August 29, 2015 13:55
Examples for a blog post on C++ overloading
@pabigot
pabigot / Makefile
Last active August 29, 2015 14:01
The Effect of the ARM Cortex-M NOP Instruction
# BSPACM - Makefile for ARM Cortex-M instruction delay experiment
#
# Written in 2014 by Peter A. Bigot <http://pabigot.github.io/bspacm/>
#
# To the extent possible under law, the author(s) have dedicated all
# copyright and related and neighboring rights to this software to
# the public domain worldwide. This software is distributed without
# any warranty.
#
# You should have received a copy of the CC0 Public Domain Dedication
@pabigot
pabigot / 00README.md
Last active January 4, 2016 00:49
Files supporting a unit test comparison at http://www.pabigot.com/c/c-unit-test-frameworks/
@pabigot
pabigot / output
Last active September 3, 2016 13:13
pump stream continues after callback
lilith[4835]$ node pb.js
pump cb 2 0 [Error: second call, carrying on]
ws finished 4 49152
@pabigot
pabigot / 0000-README.md
Last active January 3, 2018 19:35
ppk-v11-hangs-on-linux-bug-report patch

Nordic PPK Linux Patches

This gist has patches to the Nordic PPK software to help it run under Linux.

Some other hints:

  • If you get whining about unable to find JLINKARM.dll, modify the
@pabigot
pabigot / README.md
Last active March 30, 2019 14:59
Example code for Nordic devzone issue TBD
@pabigot
pabigot / 0001-drivers-timer-nrf_rtc_timer-clarify-intent-of-ZLI-co.patch
Last active August 19, 2019 16:12
diagnostics patch for zephyrproject-rtos/zephyr issue 17965
From 56036a278ba819bdabf3b32f580d9ecd51123db7 Mon Sep 17 00:00:00 2001
From: Peter Bigot <peter.bigot@nordicsemi.no>
Date: Mon, 19 Aug 2019 11:00:00 -0500
Subject: [PATCH] drivers/timer/nrf_rtc_timer: clarify intent of ZLI
compensation
The variable enabling entry to the zero latency interrupt compensation
loop was named generically, and its logic inverted, making the code
difficult to understand. Change the name and initial value to more
clearly indicate its role.
@pabigot
pabigot / fragment.c
Last active January 8, 2020 14:21
example of service request with reset attempt for zephyrproject-rtos/zephyr pr #21090
int err;
struct k_poll_signal sig;
struct onoff_client cli;
/* Blocking start using signal */
struct k_poll_event evts[] = {
K_POLL_EVENT_INITIALIZER(K_POLL_TYPE_SIGNAL,
K_POLL_MODE_NOTIFY_ONLY,
&sig),
};
@pabigot
pabigot / named.txt
Created January 17, 2020 16:14
fragments to get a named phandle reference
/* binding */
description: whatever
compatible: "something,switch"
properties:
gpios:
type: phandle-array
required: true
gpio-names:
type: string-array
required: false