Hi, I i have written a code for 500 KHz frequency counter . Micro con. I have used is a 89c2051 and the compiler is MikroC 3.6 version. demo. My syntax "value=65535*read+TH1*256+TL1" always load 0 into value. value is a unsigned long, read is a unsigned short which is incremented by 1 for every overflow (interrupt) of timer 1. Because of my code consumes 1990 bytes of hex code(10 bytes below limitation range), I inspect .list and .asm and i found severe mistake in compilation. I don't know why. please help.
Attachments
-
23.2 KB Views: 13
-
27.4 KB Views: 9