Commit graph

21 commits

Author SHA1 Message Date
Drew Fustini
7fb13f9f3d Fix warnings on format truncation and sizeof in strncpy #308
Debian 10 (Buster) has gcc 8.2 which warns about:

source/c_pwm.c:459:65: error: argument to ‘sizeof’ in ‘strncpy’ call is the same expression as the source; did you mean to use the size of the destination? [-Werror=sizeof-pointer-memaccess]
source/c_pwm.c:396:43: error: ‘%s’ directive output may be truncated writing up to 199 bytes into a region of size 100 [-Werror=format-truncation=]
2019-12-11 09:03:44 +00:00
Drew Fustini
1997b53a26 Sleep after loading ADC overlay to allow driver load 2017-06-30 06:46:49 +00:00
Matthew West
09e7597982 Fix ADC error in 3.8 2016-08-10 16:52:54 -07:00
Matthew West
cd2456b157 Fix PWM tests to reflect 4.1+ 2016-08-08 12:09:19 -07:00
Matthew West
8fe1336b0a Bug fixes almost to stability 2016-08-08 10:51:15 -07:00
Matthew West
6b2aa7aabc Change return value convention for errors
Replace 1 for success and 0/-1 for failure with an enum type.
2016-08-05 13:19:54 -07:00
Peter Lawler
86a5145e11 Remove stray sprintf that snuck in during manual edit 2016-05-11 09:00:31 +10:00
plawler
d16654d20a Make friends between 3.8 and 4.1+ kernels 2016-04-29 12:29:29 +10:00
Enzo Macari
d9ad2b3812 Soporte para adc y gpio ok
TODO: PWM
2016-02-03 17:23:35 -03:00
Justin Cooper
6d2610b893 clean up source 2014-05-23 16:03:44 +00:00
Justin Cooper
25e654a982 fix for SPI not loading spidevX.X correctly based on load order 2014-05-23 03:22:48 +00:00
Zach Thorson
fa1b4a3e7e Added a retry to reading for the analog inputs to avoid a bug where reading back and forth between two analog inputs would cause the resource to be unavailable every 16 scans
Corrected the readback of the success bit to correctly check for a read and raise an exception on failure
2013-11-20 14:52:04 -06:00
Zach Thorson
34d7e30e1a Updated the build_path to be more selective over what paths it chooses (This should prevent chosing the wrong helper leading to seg faults)
Improved error messages when ADC fails to setup
Check for null file handle when opening AIN to prevent seg fault
2013-11-14 11:10:09 -06:00
Justin Cooper
670bfcbf1c better error handling of load_device_tree through adc, pwm, and uart 2013-07-30 19:34:24 +00:00
Justin Cooper
5c09f8915a fix for ADC segmentation faults, bump to 0.0.9 2013-07-09 20:13:47 +00:00
Justin Cooper
ab6dab6519 fix tests, initial non-working spi, refactor loading device tree 2000-01-01 00:06:09 +00:00
Justin Cooper
1da7cd7449 Remove debugging fprintf statements 2013-06-25 15:25:43 -05:00
Justin Cooper
c61b5ad4c5 Increase string size for adc directories. 2013-06-25 12:50:19 -05:00
Justin Cooper
bdafa9a6c5 working adc, remove cleanup, add read_raw 2000-01-01 03:57:40 +00:00
Justin Cooper
78610e35a2 clean up adc, and add test 2000-01-01 00:03:14 +00:00
Justin Cooper
651395582a initial adc commit 2000-01-03 02:00:52 +00:00