From 36529f3f93f5f66d94dff8c5fc5ef61ccf428493 Mon Sep 17 00:00:00 2001 From: Martin Prudek Date: Wed, 20 May 2015 21:45:27 +0200 Subject: [PATCH] Cosmetic changes. --- pmsm-control/test_sw/main_pmsm.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/pmsm-control/test_sw/main_pmsm.c b/pmsm-control/test_sw/main_pmsm.c index f0fc982..6f3c670 100644 --- a/pmsm-control/test_sw/main_pmsm.c +++ b/pmsm-control/test_sw/main_pmsm.c @@ -62,15 +62,14 @@ struct rpi_state rps={ .doLogs=0, .alpha_offset=960, .main_commutator=zero_commutator, /* komutace vypnuta */ - .main_controller=zero_controller /* rizeni vypnuto */ + .main_controller=zero_controller /*rizeni vypnuto */ }; /** * \brief Initilizes GPCLK. */ -int clk_init() -{ +int clk_init(){ initialise(); /*namapovani gpio*/ initClock(PLLD_500_MHZ, 10, 0); gpioSetMode(4, FSEL_ALT0); @@ -112,7 +111,6 @@ void * pos_monitor(void* param){ /* * \brief * Feedback loop. - * TODO: replace bunch of 'IFs' with Object-like pattern */ void * control_loop(void* param){ int i; @@ -128,8 +126,6 @@ void * control_loop(void* param){ uint16_t last_index; /*we have index up-to date*/ spi_read(&poc); /*pocatecni informace*/ clock_gettime(CLOCK_MONOTONIC ,&t); - /* start after one second */ - t.tv_sec++; while(1){ /* wait until next shot */ clock_nanosleep(CLOCK_MONOTONIC, TIMER_ABSTIME, &t, NULL); -- 2.39.2