Moved main.cpp to test folder
This commit is contained in:
29
test/main.cpp
Normal file
29
test/main.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
/*
|
||||
* Blink.cpp
|
||||
*
|
||||
* Created: 18/12/2018 5:11:34 PM
|
||||
* Author : jimmy
|
||||
*/
|
||||
#define F_CPU 8000000
|
||||
#include <avr/io.h>
|
||||
#include <avr/interrupt.h>
|
||||
#include <util/delay.h>
|
||||
#include "../src/TM1637Display.h"
|
||||
|
||||
int main(void) {
|
||||
//*(&PORTA-1) |= (1<<PA0);
|
||||
const int CLK = PA0; //Set the display CLK pin PC1
|
||||
const int DIO = PA1; //Set the display DIO pin PC0
|
||||
TM1637Display display(CLK, DIO, &PORTA); //set up the 4-Digit Display.
|
||||
int count = 0;
|
||||
// 7-Seg Setup
|
||||
display.setBrightness(255); //display to high brightness
|
||||
|
||||
|
||||
while(1){
|
||||
display.showNumberDec(count++);
|
||||
//PORTA ^= (1<<PA0);
|
||||
_delay_ms(1000);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user