Created
February 6, 2015 23:54
-
-
Save samirfor/16671074d49c2cdcbf93 to your computer and use it in GitHub Desktop.
Pisca LED
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
/** | |
* Ferramenta SanUSB: http://sanusb.site50.net/ | |
* Compilar com MPLABX+C18: https://drive.google.com/open?id=0B5332OAhnMe2N3czQWxVX0JVSkE&authuser=0 | |
* | |
* Este programa pisca o LED do pino b7. | |
* Foto da placa: https://drive.google.com/file/d/0BwIZj8djOAj2akptcEEwcFpOazg/view?usp=sharing | |
*/ | |
#include "SanUSB48.h" | |
#pragma interrupt interrupcao //Tem que estar aqui ou dentro do firmware.c | |
void interrupcao() { | |
} | |
void main() { | |
clock_int_48MHz(); | |
while (1) { | |
if (!entrada_pin_e3) { //pressionar o botão para gravação | |
Reset(); | |
} | |
inverte_saida(pin_b7); | |
tempo_ms(100); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment