Annotation of libaitcrc/example/test.c, revision 1.2.10.1
1.1 misho 1: #include <stdio.h>
2: #include <sys/types.h>
3: #include <aitcrc.h>
4:
5:
6: int main()
7: {
1.2 misho 8: u_char pd[7] = { 0xFF, 0x01, 0x00, 0x04, 0x3F, 0x00, 0x01 };
9: u_char pp[8] = { 0xA0, 0x00, 0x00, 0x04, 0x20, 0x00, 0xAF, 0x01 };
1.1 misho 10:
1.2.10.1! misho 11: printf("reflect=%u\n", crcReflect(3001123, 32));
1.1 misho 12:
1.2 misho 13: printf("pelco_d=0x%x pelco_p=0x%x\n", crcPelco('d', pd), crcPelco('p', pp));
14:
1.1 misho 15: return 0;
16: }
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>