This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <avr/sleep.h> | |
const int32_t led_pin = 13; | |
const int32_t pir_input_pin = 2; | |
int32_t pir_state = LOW; | |
volatile int32_t pinval = 0; | |
void setup() | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main() | |
{ | |
unsigned long long n = 1; | |
unsigned long long saved_n = n; | |
unsigned long long curr_seq_len = 1; | |
unsigned long long prev_seq_len = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Device Tree for Zybo board | |
* Partially generated by Device Tree Generator 1.1 | |
* | |
* (C) Copyright 2007-2013 Xilinx, Inc. | |
* (C) Copyright 2007-2013 Michal Simek | |
* (C) Copyright 2007-2012 PetaLogix Qld Pty Ltd | |
* (C) Copyright 2014 Digilent, Inc. | |
* | |
* Michal SIMEK <[email protected]> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Adafruit NeoPixel Shield RGB Light Wireless control over Bluetooth | |
Author : Rishi F. | |
Adapted from the code written by - http://kuchenzeit.wordpress.com/ | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Brainfuck Interpreter Code. | |
http://en.wikipedia.org/wiki/Brainfuck | |
A recursive, stack based implementation in C | |
Scaling Options: | |
MAX_CELLS - Increase cell count depending on brainfuck program | |
MAX_STACK_SZ - Increase stack size. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
AREA ARM, CODE, READONLY | |
CODE32 | |
PRESERVE8 | |
EXPORT __sortc | |
; r0 = &arr[0] | |
; r1 = length | |
__sortc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define MAX_ELEMENTS 10 | |
extern void __sortc(int *, int); | |
int main() | |
{ | |
int arr[MAX_ELEMENTS] = {5, 4, 1, 3, 2, 12, 55, 64, 77, 10}; | |
__sortc(arr, MAX_ELEMENTS); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <ads7843.h> | |
#define DCLK 51 // SCLK | |
#define CS 46 // CS | |
#define DIN 48 // MISO | |
#define DOUT 47 // MOSI | |
#define IRQ 49 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// UTFT_ViewFont (C)2012 Henning Karlsen | |
// web: http://www.henningkarlsen.com/electronics | |
// | |
// This program is a demo of the included fonts. | |
// | |
// This demo was made for modules with a screen resolution | |
// of 320x240 pixels. | |
// | |
// This program requires the UTFT library. | |
// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <SPI.h> | |
#include <Ethernet.h> | |
// Enter a MAC address and IP address for your controller below. | |
// The IP address will be dependent on your local network: | |
byte mac[] = { "Your MAC" }; |
NewerOlder