Some old AVR projects
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
avr-projects/devel/lib_tests/test_loops_visual.c

27 lines
355 B

#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <assert.h>
#include "lib/loops.h"
void main()
{
repeat(5) printf("Five times!\n");
repeatx(500) printf(".");
printf("\n");
int i = 0;
until (i == 100) i++;
10 years ago
until (i == 0) {
i--;
printf("i = %d\n", i);
}
10 years ago
printf("\n");
10 years ago
loop(moo, 7) {
printf("moo = %d\n", moo);
}
10 years ago
}