Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 7521

MicroPython • Re: How to show "00000000" in this counter

$
0
0
Try...

Code:

while True:        if update_flag:            rCtr += 1            update_flag = False            #if (rCtr % 100) == 0:            if True:              clock_count = 2*(max_count - data[0]+1)              pulse_count = max_count - data[1]              freq = pulse_count * ( MCAL / clock_count)  # calibration constant             # print("{0:d},{1:d},{2:d},{3:0.2f} Hz".format(i,clock_count,pulse_count,freq))             # i += 1              print("{:,} Hz".format(freq))         else:              print('0000000')
No, still the same. I don't know anything about ASM or statemachines, but it looks like if the statemachines don't see an input, the program don't continue to the "while True" section. I actually don't have a ;) clue.

Statistics: Posted by jdev99 — Tue Jul 01, 2025 2:45 pm



Viewing all articles
Browse latest Browse all 7521

Trending Articles