0e00df4ec71e883b658e8099259c566572f272de
Stefan Schuermans added cycle counter peripheral

Stefan Schuermans authored 12 years ago

1) #include "cyc_cnt.h"
Stefan Schuermans implemented LCD peripheral

Stefan Schuermans authored 12 years ago

2) #include "lcd.h"
Stefan Schuermans added "LEDs" I/O peripheral...

Stefan Schuermans authored 12 years ago

3) #include "leds.h"
4) 
Stefan Schuermans implemented loading of data...

Stefan Schuermans authored 12 years ago

5) const int myconst = 0x12345678;
6) 
7) int myvar = 0x11223344;
8) 
Stefan Schuermans slower LED animation for ex...

Stefan Schuermans authored 12 years ago

9) volatile int data[100];
10) 
Stefan Schuermans implemented LCD peripheral

Stefan Schuermans authored 12 years ago

11) void delay(void)
Stefan Schuermans slower LED animation for ex...

Stefan Schuermans authored 12 years ago

12) {
Stefan Schuermans implemented LCD peripheral

Stefan Schuermans authored 12 years ago

13)   cyc_cnt_delay_ms(200);
Stefan Schuermans slower LED animation for ex...

Stefan Schuermans authored 12 years ago

14) }
Stefan Schuermans initial firmware and testbed

Stefan Schuermans authored 12 years ago

15) 
16) int main()
17) {
Stefan Schuermans added "LEDs" I/O peripheral...

Stefan Schuermans authored 12 years ago

18)   unsigned int i;
19) 
Stefan Schuermans added cycle counter peripheral

Stefan Schuermans authored 12 years ago

20)   for (i = 0; i < sizeof(data) / sizeof(data[0]); ++i)
21)     data[i] = i;
22) 
Stefan Schuermans implemented LCD peripheral

Stefan Schuermans authored 12 years ago

23)   lcd_init();
24) 
Stefan Schuermans slower LED animation for ex...

Stefan Schuermans authored 12 years ago

25)   while (1) {
26)     for (i = 0x1; i < 0x80; i <<= 1) {
27)       leds_set_state(i);
28)       delay();
29)     }
30)     for (i = 0x80; i > 0x1; i >>= 1) {
31)       leds_set_state(i);
32)       delay();
33)     }
34)   }
Stefan Schuermans added "LEDs" I/O peripheral...

Stefan Schuermans authored 12 years ago

35)