Root/lm32/logic/sakc/firmware/gdb-test/main.c

1#include "soc-hw.h"
2
3void main()
4{
5    gpio0->oe = 0x000000ff;
6    for(;;) {
7        int i;
8
9        for(i=0; i<8; i++) {
10            uint32_t out1, out2;
11
12            out1 = 0x01 << i;
13            out2 = 0x80 >> i;
14            gpio0->out = out1 | out2;
15
16            msleep(100);
17        }
18    }
19}
20
21

Archive Download this file

Branches:
master



interactive