Skip to content

Instantly share code, notes, and snippets.

View bobboteck's full-sized avatar
📻
-.-. --.-

Roberto D'Amico bobboteck

📻
-.-. --.-
View GitHub Profile
@bobboteck
bobboteck / pwm-gianni.c
Created February 25, 2021 20:30
Test PWM Generation for PICO
#include <stdio.h>
#include "pico/stdlib.h"
#include "hardware/gpio.h"
#include "pico/binary_info.h"
#include "hardware/pwm.h"
#include "hardware/clocks.h"
const uint LED_PIN = 25;
int main()
@bobboteck
bobboteck / TestTimerOne.ino
Last active August 24, 2020 13:37
Very simple test of TimerOne Arduino Library. Configured for execute Interrupt Service Request every 1 micro Second. The ISR change the output level on PIN 9.
#include <TimerOne.h>
void setup()
{
Timer1.initialize(1); // Initialise Timer 1 @ 1 microSecond
Timer1.attachInterrupt(TimerOne_ISR); // Attach interrupt to the timer service routine
pinMode(9, OUTPUT);
digitalWrite(9, 0);
}