Add calculation for pin high/low time in high-voltage-booster #2

Closed
opened 6 years ago by Ruakij · 1 comments
Ruakij commented 6 years ago (Migrated from gitea.railduction.eu)

Calculate the next tick for the high-voltage-booster based on the defined tick time interval and a PWM frequency to boost in.

Calculate the next tick for the high-voltage-booster based on the defined tick time interval and a PWM frequency to boost in.
Ruakij commented 6 years ago (Migrated from gitea.railduction.eu)

Added calculation for high/low-time:

boost_highVoltage_nextTick = clock() + F_CPU * 1/(boost_frequency/2)



The nextTick should then be half of the period-time of the given frequency



1/frequency gives period-time

Added calculation for high/low-time:<br> <code>boost_highVoltage_nextTick = clock() + F_CPU * 1/(boost_frequency/2)</code><br> <br> The nextTick should then be half of the period-time of the given frequency<br> <br> 1/frequency gives period-time
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: Ruakij/Geigercounter#2
Loading…
There is no content yet.