targets/OSX/plc_OSX_main.c
branchpython3
changeset 3782 39480d9d3d3f
parent 3781 25195da82745
equal deleted inserted replaced
3781:25195da82745 3782:39480d9d3d3f
    53 {
    53 {
    54     if (next == period && next == 0) {
    54     if (next == period && next == 0) {
    55         dispatch_suspend(PLC_timer);
    55         dispatch_suspend(PLC_timer);
    56     } else {
    56     } else {
    57         dispatch_time_t start;
    57         dispatch_time_t start;
    58         start = dispatch_time(DISPATCH_TIME_NOW, next);
    58         start = dispatch_walltime(NULL, next);
    59         dispatch_source_set_timer(PLC_timer, start, period, 0);
    59         dispatch_source_set_timer(PLC_timer, start, period, 0);
    60         dispatch_resume(PLC_timer);
    60         dispatch_resume(PLC_timer);
    61     }
    61     }
    62 }
    62 }
    63 
    63