This commit is contained in:
MegiDervishi 2020-12-21 18:09:07 +01:00
commit ad83ae83e4
2 changed files with 3 additions and 11 deletions

6
led.c
View file

@ -5,15 +5,15 @@
int main (void)
{
/* set pin 5 of PORTB for output*/
/* set pin 4 of PORTB for output*/
DDRB |= _BV(DDB4);
while(1) {
/* set pin 5 high to turn led on */
/* set pin 4 high to turn led on */
PORTB |= _BV(PORTB4);
_delay_ms(BLINK_DELAY_MS);
/* set pin 5 low to turn led off */
/* set pin 4 low to turn led off */
PORTB &= ~_BV(PORTB4);
_delay_ms(BLINK_DELAY_MS);
}

View file

@ -1,8 +0,0 @@
heptc arduinolib.epi
heptc -target c prog.ept
gcc -c -I /Users/megidervishi/.opam/4.10.0/lib/heptagon/c -I . arduinolib.c prog_c/*.c
$(TARGET).c:
heptc $(CFILE).epi
heptc -target c $(HEPT).ept
$(CC) $(CFLAGS) -c -I $(ADDR) -I . $(CFILE).c $(TARGET).c