Skip to content

Commit 2d7f024

Browse files
Update README.md
1 parent f956cae commit 2d7f024

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -145,13 +145,13 @@ void main(void)
145145
...
146146
while (1) {
147147
148-
float fUsage = 0.0f;
149148
__cpu_usage__(10, {
150-
fUsage = __usage__; /*< "__usage__" stores the result */
149+
float fUsage = __usage__; /*< "__usage__" stores the result */
150+
printf("task 1 cpu usage %3.2f %%\r\n", (double)fUsage);
151151
}) {
152152
delay_us(30000);
153153
}
154-
printf("task 1 cpu usage %3.2f %%\r\n", (double)fUsage);
154+
155155
156156
delay_us(70000);
157157
}

0 commit comments

Comments
 (0)