38 dbg_print(
"Reading base clock from PWM subdevice %d\n", subdev->
id);
41 dbg_print(
" --> calculated offset is 0x%x!\n", offset);
60 dbg_print(
"Setting PWM period for channel %d on subdevice %d\n", subdev->
id, channel);
63 dbg_print(
" --> calculated offset is 0x%x!\n", offset);
83 dbg_print(
"Reading period value from pwm %d of subdevice %d\n", channel, subdev->
id);
86 dbg_print(
" --> calculated offset is 0x%x!\n", offset);
107 dbg_print(
"Setting PWM hight time for channel %d on subdevice %d\n", subdev->
id, channel);
110 dbg_print(
" --> calculated offset is 0x%x!\n", offset);
129 dbg_print(
"Reading hightime value from pwm %d of subdevice %d\n", channel, subdev->
id);
132 dbg_print(
" --> calculated offset is 0x%x!\n", offset);
uint32_t nof_channels
Address space size.
Data structures for flink devices and subdevices.
int flink_pwm_get_hightime(flink_subdev *subdev, uint32_t channel, uint32_t *hightime)
Gets the PWM hightime.
int flink_pwm_set_hightime(flink_subdev *subdev, uint32_t channel, uint32_t hightime)
Sets the PWM hightime.
ssize_t flink_read(flink_subdev *subdev, uint32_t offset, uint8_t size, void *rdata)
Read from a flink subdevice.
int flink_pwm_get_baseclock(flink_subdev *subdev, uint32_t *frequency)
Reads the base clock of a PWM subdevice.
int flink_pwm_set_period(flink_subdev *subdev, uint32_t channel, uint32_t period)
Sets the PWM period.
#define PWM_FIRSTPWM_OFFSET
int flink_pwm_get_period(flink_subdev *subdev, uint32_t channel, uint32_t *period)
Gets the PWM period.
ssize_t flink_write(flink_subdev *subdev, uint32_t offset, uint8_t size, void *wdata)
Write to a flink subdevice.
#define dbg_print(fmt,...)