]> git.baikalelectronics.ru Git - kernel.git/commit
iio: magnetometer: mag3110: Add ability to run in continuous mode
authorRichard Tresidder <rtresidd@electromag.com.au>
Tue, 8 May 2018 07:59:54 +0000 (15:59 +0800)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sat, 12 May 2018 10:01:59 +0000 (11:01 +0100)
commitd9d8d9c3c9ba89d1885c5de8d1476916584741bd
treeb929280c5a92b43534e02eb5a8ab6d916f555aaa
parent6cef60212a3f728ad83dcf53ea7fd965048f1806
iio: magnetometer: mag3110: Add ability to run in continuous mode

Adds the ability to run the Mag3110 in continuous mode to speed up the
sampling rate.
Depending on the sampling rate requested the device can be put in or out
of continuous mode automatically.
Shifting out of continuous mode requires a potential 1 / ODR wait which
is also implemented.
Modified the sleep method when data is not ready to allow for
sampling > 50sps to work.

Signed-off-by: Richard Tresidder <rtresidd@electromag.com.au>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/magnetometer/mag3110.c