Skip to content

Instantly share code, notes, and snippets.

View pratimugale's full-sized avatar

Pratim Ugale pratimugale

View GitHub Profile
@pratimugale
pratimugale / main.c
Created June 23, 2019 15:25 — forked from shirriff/main.c
Example code using a timer with the BeagleBone Black's PRU microcontroller. This code generates 5 pulses with 100ns width.
/*
* Demonstration of the BeagleBone's PRU, using a timer.
* Ken Shirriff, http://righto.com
*/
#include <stdint.h>
#define DELAY_NS 100 // Use 500000000 for 0.5 second delay
#define WRITE_PIN 15 /* P8_11, Ethernet output data, pr1_PRU0_pru_r30_15 */
// PRU Interrupt control registers