Skip to content

Instantly share code, notes, and snippets.

//-----Custom floatField----------------
/*
Usage:
altFIELD(decimalslField,ee.herz,"Fine"," Hz",0,999.9,10,0.1,setFreq,enterEvent,noStyle)
OR dFIELD(ee.herz,"Fine"," Hz",0,999.9,10,0.1,setFreq,enterEvent,noStyle)
((decimalslField<typeof(ee.herz)>*)&mainMenu[4])->setDecimals(2); // if needed - change dynamiclaly.
OR setDecimals<float>(mainMenu[4],2);
*/
#define dFIELD(...) altFIELD(decimalslField,__VA_ARGS__)
@lorol
lorol / DDSSTM.ino
Last active April 1, 2019 20:59
Updated font choice
#include <Arduino.h>
/********************
DDS AD9833 Generator
https://github.com/neu-rah/ArduinoMenu
Uses:
https://github.com/lorol/AD9833-Library-Arduino - a fork SPIx of
https://github.com/Billwilliams1952/AD9833-Library-Arduino
output: U8G2 https://github.com/olikraus/U8g2_Arduino + Serial
input: Serial + ClickEncoder
MCU STM32L15x (NUCLEO 64)
@lorol
lorol / DDS.ino
Last active March 8, 2021 03:59
DDS AD9833 Generator with ArduinoMenu
#include <Arduino.h>
/********************
DDS AD9833 Generator
https://github.com/neu-rah/ArduinoMenu
Uses:
https://github.com/Billwilliams1952/AD9833-Library-Arduino
menu on LiquidCrystal 2 x 16 (or 4 x 20) lines