Lines Matching refs:plat
181 if (plat == NULL) { in mraa_pwm_init()
189 if (plat->pins[pin].capabilites.pwm != 1) { in mraa_pwm_init()
194 if (plat->adv_func->pwm_init_replace != NULL) { in mraa_pwm_init()
195 return plat->adv_func->pwm_init_replace(pin); in mraa_pwm_init()
197 if (plat->adv_func->pwm_init_pre != NULL) { in mraa_pwm_init()
198 if (plat->adv_func->pwm_init_pre(pin) != MRAA_SUCCESS) in mraa_pwm_init()
202 if (plat->pins[pin].capabilites.gpio == 1) { in mraa_pwm_init()
205 mux_i = mraa_gpio_init_raw(plat->pins[pin].gpio.pinmap); in mraa_pwm_init()
224 if (plat->pins[pin].pwm.mux_total > 0) { in mraa_pwm_init()
225 if (mraa_setup_mux_mapped(plat->pins[pin].pwm) != MRAA_SUCCESS) { in mraa_pwm_init()
231 int chip = plat->pins[pin].pwm.parent_id; in mraa_pwm_init()
232 int pinn = plat->pins[pin].pwm.pinmap; in mraa_pwm_init()
234 if (plat->adv_func->pwm_init_post != NULL) { in mraa_pwm_init()
236 mraa_result_t ret = plat->adv_func->pwm_init_post(pret); in mraa_pwm_init()
249 … mraa_pwm_context dev = mraa_pwm_init_internal(plat == NULL ? NULL : plat->adv_func , chipin, pin); in mraa_pwm_init_raw()
278 mraa_pwm_period_us(dev, plat->pwm_default_period); in mraa_pwm_init_raw()
325 if (us < plat->pwm_min_period || us > plat->pwm_max_period) { in mraa_pwm_period_us()
481 if (plat == NULL) { in mraa_pwm_get_max_period()
484 return plat->pwm_max_period; in mraa_pwm_get_max_period()
490 if (plat == NULL) { in mraa_pwm_get_min_period()
493 return plat->pwm_min_period; in mraa_pwm_get_min_period()