Skip to content

Instantly share code, notes, and snippets.


Scott W Harden swharden

View GitHub Profile
View ad7705-datasheet.c
// C code from the AD7705/AD7706 datasheet
#include <math.h>
#include <io6811.h>
#define NUM_SAMPLES 1000 /* change the number of data samples */
#define MAX_REG_LENGTH 2 /* this says that the max length of a register is 2 bytes */
Read(int, char);
swharden /
Created January 31, 2023 17:20
Extract text from a folder of PPTX files and save the output in a HTML report
This script finds text in a folder of PPT files and saves what is found
in a HMTL report that can be easily searched. It separates long phrases
from stray words to make important content easier to spot.
import datetime
import collections
swharden / GenerateColorPalettes.cs
Last active June 17, 2022 20:42
A C# .NET 6 app for generating XML color palettes
View GenerateColorPalettes.cs
// This .NET 6 console app generates XML color palette files compatible with Adobe Illustrator and CorelDraw.
// Color palettes are sourced from the ScottPlot package.
foreach (var pal in ScottPlot.Palette.GetPalettes())
string xml = GetPaletteXml(pal);
string saveFolder = Path.GetFullPath("palettes");
if (!Directory.Exists(saveFolder))