pot plugin w. example

This commit is contained in:
2018-11-17 02:45:54 +01:00
parent f79f869d55
commit be17cabfdc
85 changed files with 7864 additions and 103 deletions

View File

@@ -0,0 +1,18 @@
void setup()
{
//setup channel 0 with frequency 312500 Hz
sigmaDeltaSetup(0, 312500);
//attach pin 18 to channel 0
sigmaDeltaAttachPin(18,0);
//initialize channel 0 to off
sigmaDeltaWrite(0, 0);
}
void loop()
{
//slowly ramp-up the value
//will overflow at 256
static uint8_t i = 0;
sigmaDeltaWrite(0, i++);
delay(100);
}