Skip to content

Instantly share code, notes, and snippets.

@motters
motters / ILI9844_Defines.h
Last active September 27, 2017 14:43
Driver for ILI9844
// Change the width and height if required (defined in portrait mode)
// or use the constructor to over-ride defaults
#define TFT_WIDTH 320
#define TFT_HEIGHT 480
// Delay between some initialisation commands
#define TFT_INIT_DELAY 0x80 // Not used unless commandlist invoked
/**
@motters
motters / SensorFactory.cpp
Last active August 29, 2018 18:10
Factory to create, retrieve and delete instances of sensors
#include <utility>
#include <memory>
#include <string>
#include <map>
#include <stdexcept>
#include <iostream>
/**
* Parent class for sensors to inherit
@motters
motters / main.cpp
Last active October 18, 2021 21:24
Counting falling edges from PWM using PPI & a Timer
#include <zephyr.h>
#include <device.h>
#include <drivers/pwm.h>
#include <drivers/adc.h>
#include <devicetree.h>
#include <nrfx_gpiote.h>
#include <nrfx_ppi.h>
#include <nrfx_timer.h>