182 |
svejda |
1 |
#include "abcda.h" |
181 |
svejda |
2 |
|
|
|
3 |
|
|
|
4 |
void main() |
|
|
5 |
{ |
|
|
6 |
|
182 |
svejda |
7 |
int i,j,n,cas; |
181 |
svejda |
8 |
|
182 |
svejda |
9 |
const int8 pis[2*5]={0b00000001,0b11110110,0b11110110,0b11110110,0b00000001, |
|
|
10 |
0b00000001,0b11110110,0b11110110,0b11110110,0b00000001}; |
|
|
11 |
int8 napis[2*8]; |
|
|
12 |
|
181 |
svejda |
13 |
setup_adc_ports(NO_ANALOGS); |
|
|
14 |
setup_adc(ADC_OFF); |
|
|
15 |
setup_psp(PSP_DISABLED); |
|
|
16 |
setup_spi(SPI_SS_DISABLED); |
|
|
17 |
setup_timer_0(RTCC_INTERNAL|RTCC_DIV_1); |
|
|
18 |
setup_timer_1(T1_DISABLED); |
|
|
19 |
setup_timer_2(T2_DISABLED,0,1); |
|
|
20 |
setup_comparator(NC_NC_NC_NC); |
|
|
21 |
setup_vref(FALSE); |
|
|
22 |
|
|
|
23 |
while(TRUE) |
|
|
24 |
{ |
182 |
svejda |
25 |
for(i=0;i<=2;i++) |
|
|
26 |
for(j=0;j<=100;j++) |
|
|
27 |
{ |
|
|
28 |
for(n=0;n<=8;n++) |
|
|
29 |
{ |
|
|
30 |
for(cas=0;cas<5;cas++) |
|
|
31 |
{ |
|
|
32 |
output_B(pis[napis[i-0x40]+cas]); |
|
|
33 |
delay_ms(1); |
|
|
34 |
} |
|
|
35 |
delay_ms(2); |
|
|
36 |
} |
|
|
37 |
delay_ms(142); |
|
|
38 |
} |
|
|
39 |
} |
181 |
svejda |
40 |
} |