Toggle RF signal and LED every half second
This commit is contained in:
parent
29c3daa029
commit
46d4d2ce69
1 changed files with 14 additions and 13 deletions
|
@ -1,18 +1,19 @@
|
||||||
/*
|
#define F_CPU 9600000 / 8
|
||||||
* Sender.cpp
|
|
||||||
*
|
|
||||||
* Created: 31.01.2016 14:09:45
|
|
||||||
* Author : mandlm
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <avr/io.h>
|
#include <avr/io.h>
|
||||||
|
#include <util/delay.h>
|
||||||
|
|
||||||
|
int main()
|
||||||
|
{
|
||||||
|
DDRB |= (1 << PB4) | (1 << PB3);
|
||||||
|
|
||||||
int main(void)
|
while (true)
|
||||||
{
|
|
||||||
/* Replace with your application code */
|
|
||||||
while (1)
|
|
||||||
{
|
{
|
||||||
|
PORTB |= (1 << PB3);
|
||||||
|
PORTB |= (1 << PB4);
|
||||||
|
_delay_ms(500);
|
||||||
|
PORTB &= ~(1 << PB3);
|
||||||
|
PORTB &= ~(1 << PB4);
|
||||||
|
_delay_ms(500);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue