Commit 2c9f8964 authored by Jeroen Vreeken's avatar Jeroen Vreeken
Browse files

Modify spg 1d to use 64 bit ints for time

parent 3759e37a
......@@ -139,8 +139,8 @@ static void setpoint_generator_1d_calculate(struct controller_block *spg)
uint64_t command_t;
int64_t t;
command_t = priv->cur_command.t.tv_nsec +
priv->cur_command.t.tv_sec * 1000000000;
command_t = (uint64_t)priv->cur_command.t.tv_nsec +
(uint64_t)priv->cur_command.t.tv_sec * 1000000000;
priv->command_t = command_t;
t = (command_t - controller_time_nseconds) / priv->period_nsec;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment