Hello,
I'm trying to use the Arc path as a RPM indication of a dashboard,
I setup a timer to trigger a "ChangeRpm" slot every 100ms, below is my "ChangeRpm" code,
if ( 0 == ReverseFlag ) { RpmArc.EndAngle += 5; if ( RpmArc.EndAngle >= 320.0) { ReverseFlag = 1; } } else { RpmArc.EndAngle -= 5; if ( RpmArc.EndAngle <= 90.0 ) { ReverseFlag = 0; } }
Then when I start the prototyper, the front end of rpm arc is like jumping back and forth, please see the footage below.
https://ask.embedded-wizard.de/?qa=blob&qa_blobid=18363368457057052073
Could you advise how to solve this issue?
Regards,
Noah
Hello Noah,
I do not see any problems with your implementation and the video. What do you mean with "jumping back and forth"? What I observe is that the arc moves with large steps. This is caused because the single step is 5 degree. Maybe you can explain better the problem?
Best regards
Paul Banach
I'm not sure what you mean with 'reset', but each time after the value of the property EndAngle has been changed, the entire arc is recalculated again and the area occupied by the Stroked Path view is redrawn automatically. Does it answer your question?
Ask Embedded Wizard - Archive
Welcome to the Ask Embedded Wizard archive. This community forum served us well for many years, but we've evolved our support approach!
Your resources:
The Embedded Wizard Online Documentation provides comprehensive documentation, tutorials, examples and ready-to-use software packages.
For dedicated assistance, explore our Embedded Wizard Product Support.
You can still browse the valuable discussions from our community history here.
Embedded Wizard Website | Privacy Policy | Imprint