Commit Graph

187 Commits

Author SHA1 Message Date
Alan Carvalho de Assis 2129ce134c drivers/sensors/mlx90614.c: Fix MLX90614 to reflash new device address 2018-11-02 07:05:40 -06:00
Alan Carvalho de Assis 9689448d2a drivers/sensors/mlx90614.c: Add support for the Infrared Thermometer MLX90614 2018-10-28 15:58:14 -06:00
Daniel P. Carvalho 3abe871a80 drivers/sensors/ina226.c: Add INA226 device driver. 2018-10-19 09:04:56 -06:00
raiden00pl af8a002a10 Merged in raiden00/nuttx_h7 (pull request #720)
I2C support for STM32H7

* stm32h7/chip.h: update peripherals

* stm32h7x3xx_rcc.h: update definitions

* stm32h7x3xx_rcc.c: remove some unused code and configure I2C clocks

* stm32h7: add lower half I2C driver (based on F7 I2C driver)

* configs/nucleo-h743zi: add LSM303AGR and LSM6DSL configuration

* Remove whitespace

* sensors/lsm303agr.c, sensors/lsm6dsl.c: add mising include, remove whitespace

Approved-by: GregoryN <gnutt@nuttx.org>
2018-09-16 15:58:25 +00:00
Ouss4 adda352b15 drivers/sensors/dhtxx.c: Driver for DHTxx sensor. 2018-09-01 07:25:30 -06:00
Gregory Nutt 11a1b2598e Fix some naming convention violations in the last commit. 2018-08-25 08:30:28 -06:00
DisruptiveNL cd2ced4d9a drivers/sensors and configs/nucleo-l476g: Add support for LSM303AGR and LSM6DSL sensors 2018-08-25 08:19:31 -06:00
Xiang Xiao e1202d2ed3 Replace all ASSERT with DEBUGASSERT to save the code space 2018-08-24 06:58:30 -06:00
Gregory Nutt 8c61c2f31b Remove trailing spaces at the end of lines. 2018-08-13 07:39:38 -06:00
Gregory Nutt 10069067c1 include/nuttx/i2c/i2c_master.h: Rename I2C_M_NORESTART to I2C_M_NOSTART since it may be used in other contexts than a repeated start. Add comments to clarilfy setup for repeated start. 2018-08-03 08:51:55 -06:00
Russ Webber ee21bcfaa8 Merged in russkel/nuttx/russkel/adxl345-remove-comment-references-to-tou-1533231727620 (pull request #702)
adxl345: remove comment references to touchscreens

Approved-by: GregoryN <gnutt@nuttx.org>
2018-08-02 17:59:59 +00:00
Gregory Nutt b8665996d5 Revert 0eff3d530f6a4251a934f26c6d870f7464ae8468: This removes the kx224, bh1749nuc and bh1790glc. These are very nicely written drivers, but they are based on some external sequencer logic which is not available to everyone. Hence, these are inapropriate to carry in the NuttX repository. 2018-07-11 15:36:33 -06:00
Gregory Nutt 235d580984 drivers/sensors/bh1749nuc.c, bh1790glc.c, and x224.c: From review of commit 0eff3d530f, remove dependency on the CXD56_SCU, modify inclusions and some naming for compatibility with other sensor drivers. 2018-07-10 16:16:15 -06:00
Juho Valkama 0eff3d530f Merged in jutava/nuttx (pull request #673)
Master

* drivers/sensors: added drivers for kx224, bh1749nuc and bh1790glc

    They are reliant on the cxd56_scu.

* drivers/sensors: Added drivers for kx224, bh1749nuc and bh1790glc

    They are reliant on the cxd56_scu.

* drivers/sensors: Added drivers for kx224, bh1749nuc and bh1790glc

    They are reliant on the cxd56_scu.

* drivers/sensors: Added drivers for kx224, bh1749nuc and bh1790glc

    They are reliant on the cxd56_scu.

* drivers/sensors: Added drivers for kx224, bh1749nuc and bh1790glc

    They are reliant on the cxd56_scu.

* drivers/sensors: Added drivers for kx224, bh1749nuc and bh1790glc

    They are reliant on the cxd56_scu.

* bh1790glc.h created online with Bitbucket

* bh1790glc.h deleted online with Bitbucket

* drivers/sensors: Added drivers for kx224, bh1749nuc and bh1790glc

    They are reliant on the cxd56_scu.

* drivers/sensors: Added drivers for kx224, bh1749nuc and bh1790glc

    They are reliant on the cxd56_scu.

* README.txt: minor typo fix

* Minor typo fix

Approved-by: GregoryN <gnutt@nuttx.org>
2018-07-10 12:38:25 +00:00
Alan Carvalho de Assis 5fb988bdc8 ~configs/xmc4500-relax: Add support to MAX6675 on XMC4500-Relax board. drivers/sensors/max6675.c: Increases SPI frequency from 400Khz to 4MHz. 2018-06-16 13:48:19 -06:00
Juha Niskanen 5b899b76c4 drivers/sensors: Add support for Telair T6713 carbon dioxide sensor 2018-06-15 06:52:16 -06:00
Gregory Nutt 96b6bf92a3 Cosmetic changes from review of last 2 PRs. 2018-05-02 16:46:12 -06:00
Anthony Merlino b1275abd4b Merged in antmerlino/nuttx/ina3221 (pull request #636)
drivers/sensors: Adds support for INA3221 power sensor. This has a 3 channel bus/shunt voltage pairs.

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-05-02 22:29:59 +00:00
Juha Niskanen 3cf830bd67 Merged in juniskane/nuttx_stm32l4/1wire_sht21_changes_pr (pull request #631)
drivers/1wire: add PM hooks and unlink support to sht21 sensor (allowing hot-swappable I2C bus from 1-wire converter)

* drivers/1wire: add PM hook to 1wire bus

* drivers/1wire/ds28e17.c: i2c instance must be zeroed

* drivers/sht21: add unlink support

    Unlike most other unlink implementations in NuttX drivers, this one
    does not allow any I2C operations after unlink, making it possible to
    deallocate the I2C bus.

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-04-24 13:21:02 +00:00
Alan Carvalho de Assis 2dfea90198 drivers/sensors/apds9960.c: Fix APDS9960 work queue BUG found by Kyle Lei 2018-04-10 06:53:11 -06:00
Tiago Almeida a482867c00 drivers/sensors/max31855: Add multiple max31855 sensors feature and support for bambino-200e and stm32f4discovery 2018-04-09 15:36:27 -06:00
Bob Feratich d893c5b55e This commit adds LSM330 SPI and ADXL372 drivers.
Squashed merge of the following:

Author: Gregory Nutt <gnutt@nuttx.org>
    drivers/sensors:  Fix some minor typos in last commit that cause some compile problems.
    drivers/sensors/:  Clean up some coding standard isses in LM330 and ADXL372 drivers.
    drivers/sensors/README.txt:  Clean up some long lines and odd line breaks.
    include/nuttx/sensors:  Completes coding style review of adxl372.h, cluster_driver.h, and lsm330.h.

Author: Bob Feretich <bob.feretich@rafresearch.com>
    Add LSM330 SPI and ADXL372 drivers along with the cluster driver infrastructure.
2018-04-07 14:47:27 -06:00
Juha Niskanen bcd1f1f774 drivers/sensors/sht21: Change I2C_TRANSFER return value so that it return on zero on success, not the count of bytes transferred. 2018-03-22 06:44:40 -06:00
Jussi Kivilinna 02841a7f55 drivrs/sensors/lis2dh: Clear INT1 at SNIOC_WRITE_INT1THRESHOLD ioctl 2018-03-21 07:28:08 -06:00
Juha Niskanen c268288c17 drivers/sensors: Add support for Sensirion SHT2x humidity sensor 2018-03-13 08:26:15 -06:00
Dmitriy Linikov a8c58607e9 Merged in hardlulz/modem-3.0-nuttx/fix-sem-EINTR (pull request #603)
Added ECANCELED condition to DEBUGASSERT-s checking sem_wait result

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-20 18:24:53 +00:00
Matt Thompson 75f68b9d3a Merged in extent3d/nuttx/lis3dh-fix (pull request #600)
LIS3DH: Fix missing shift when writing output data rate to register

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-14 20:27:48 +00:00
Gregory Nutt e07f12954c Trivial changes from review of last PR. 2018-02-13 13:08:38 -06:00
Matt Thompson e79e2e2d97 Merged in extent3d/nuttx/lis3dh (pull request #598)
Added support for LIS3DH accelerometer sensor.

* Added support for LIS3DH accelerometer sensor.

* Fix line length

* Fix more line lengthts

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-13 19:00:29 +00:00
Gregory Nutt fad70bf90e Update some comments 2018-02-03 09:35:46 -06:00
Gregory Nutt 1567b82429 Make sure that labeling is used consistently in all function headers (part 2). 2018-02-01 12:03:55 -06:00
Juha Niskanen a5cb1129f9 drivers/sensors/lis2dh: use realtime clock if monotonic is not available 2018-01-31 07:41:56 -06:00
Juha Niskanen dafa72edc3 drivers/sensors: add support to MAX44009 ambient light sensor 2018-01-29 07:56:06 -06:00
ussi Kivilinna 5392955ec4 drivers/sensors/hts221.c: Fix sensor reset with BOOT bit 2017-12-20 10:11:52 -06:00
Gregory Nutt 5328e3bafb configs/: CONFIG_QENCODER was renamed to CONFIG_SENSORS_QENCODER: update occurrences in several Kconfig files 2017-11-25 18:46:43 -06:00
Jussi Kivilinna 0ea4d2a11d sensors/lis2dh: fix use of obsolete dbg macro 2017-10-27 06:13:14 -06:00
Jussi Kivilinna e557c3e8d5 drivers/sensors/lis2dh: fixes for self-test 2017-10-26 09:25:20 -06:00
Alan Carvalho de Assis 0be36a6ac1 drivers/sensors/apds9960.c: Use work_queue to read/process data when receive an IRQ 2017-10-20 08:54:44 -06:00
Jussi Kivilinna fe9be72bec drivers/sensors/hts221: power-on sensor for loading calibration data 2017-10-20 08:33:44 -06:00
Alan Carvalho de Assis 3268a6ac5f drivers/sensor: Add driver for the APDS-9960 gesture sensor 2017-10-20 06:37:38 -06:00
Sebastien Lorquet d16d4d5568 The INA219 is a combined voltage and current sensor that can measure up to 26 volts and a current that depends on an external shunt resistor. Connection happens via i2c/smbus and the chip features a power supply rail that is independent from the measured voltage, so it can measure low voltages.
This commit adds a driver for this chip.  Right now it measures bus voltage and current, and does not use the internal calibrated current reading, nor the available power measurement.
2017-10-10 17:03:56 -06:00
Gregory Nutt 4810499d3a Squashed commit of the following:
Replace all calls to sigqueue() in the OS proper with calls to nxsig_queue() to avoid accessing the errno variable.

    sched/signal:  Add nxsig_queue() which is functionally equivalent to sigqueue() except that it does not modify the errno variable.
2017-10-07 10:57:09 -06:00
Gregory Nutt 936df1bcb5 Adds new OS internal functions nxsig_sleep() and nxsig_usleep. These differ from the standard sleep() and usleep() in that (1) they don't cause cancellation points, and (2) don't set the errno variable (if applicable). All calls to sleep() and usleep() changed to calls to nxsig_sleep() and nxsig_usleep().
Squashed commit of the following:

    Change all calls to usleep() in the OS proper to calls to nxsig_usleep()

    sched/signal:  Add a new OS internal function nxsig_usleep() that is functionally equivalent to usleep() but does not cause a cancellaption point and does not modify the errno variable.

    sched/signal:  Add a new OS internal function nxsig_sleep() that is functionally equivalent to sleep() but does not cause a cancellaption point.
2017-10-06 10:15:01 -06:00
Gregory Nutt 29b5b3667f sched/semaphore: sem_timedwait() is a cancellation point and, hence, cannot be called from within the OS. Created nxsem_timedwait() that is equivalent but does not modify the errno and does not cause cancellation. All calls to sem_timedwait() change to calls to nxsem_timedwait() in the OS. 2017-10-05 07:24:54 -06:00
Gregory Nutt 9568600ab1 Squashed commit of the following:
This commit backs out most of commit b4747286b1.  That change was added because sem_wait() would sometimes cause cancellation points inappropriated.  But with these recent changes, nxsem_wait() is used instead and it is not a cancellation point.

    In the OS, all calls to sem_wait() changed to nxsem_wait().  nxsem_wait() does not return errors via errno so each place where nxsem_wait() is now called must not examine the errno variable.

    In all OS functions (not libraries), change sem_wait() to nxsem_wait().  This will prevent the OS from creating bogus cancellation points and from modifying the per-task errno variable.

    sched/semaphore:  Add the function nxsem_wait().  This is a new internal OS interface.  It is functionally equivalent to sem_wait() except that (1) it is not a cancellation point, and (2) it does not set the per-thread errno value on return.
2017-10-04 15:22:27 -06:00
Gregory Nutt 42a0796615 Squashed commit of the following:
sched/semaphore:  Add nxsem_post() which is identical to sem_post() except that it never modifies the errno variable.  Changed all references to sem_post in the OS to nxsem_post().

    sched/semaphore:  Add nxsem_destroy() which is identical to sem_destroy() except that it never modifies the errno variable.  Changed all references to sem_destroy() in the OS to nxsem_destroy().

    libc/semaphore and sched/semaphore:  Add nxsem_getprotocol() and nxsem_setprotocola which are identical to sem_getprotocol() and set_setprotocol() except that they never modifies the errno variable.  Changed all references to sem_setprotocol in the OS to nxsem_setprotocol().  sem_getprotocol() was not used in the OS
2017-10-03 15:35:24 -06:00
Gregory Nutt 83cdb0c552 Squashed commit of the following:
libc/semaphore:  Add nxsem_getvalue() which is identical to sem_getvalue() except that it never modifies the errno variable.  Changed all references to sem_getvalue in the OS to nxsem_getvalue().

    sched/semaphore:  Rename all internal private functions from sem_xyz to nxsem_xyz.  The sem_ prefix is (will be) reserved only for the application semaphore interfaces.

    libc/semaphore:  Add nxsem_init() which is identical to sem_init() except that it never modifies the errno variable.  Changed all references to sem_init in the OS to nxsem_init().

    sched/semaphore:  Rename sem_tickwait() to nxsem_tickwait() so that it is clear this is an internal OS function.

    sched/semaphoate:  Rename sem_reset() to nxsem_reset() so that it is clear this is an internal OS function.
2017-10-03 12:52:31 -06:00
Gregory Nutt 8394f9b60f Squashed commit of the following:
configs/z80sim and xtrs:  Serial driver lower halfs ioctl methods should return a negated errno value, not set the errno variable.

    drivers/wireless:  CC1101 driver not permitted to set errno.

    drivers/sensors:  LIS331DL driver not permitted to set errno.

    drivers/lcd: ILI9341 initialize method not permitted to set errno,

    drivers/serial: 16550 UART driver IOCTL method must not set errno; it must return a negated errno value.
2017-09-30 12:59:33 -06:00
Gregory Nutt 0f04816b37 Trivial changes from review of last PR. 2017-09-14 14:55:50 -06:00
Florian Olbrich 6f57d1d472 lis3dsh.c edited to obey the nuttx coding standard. 2017-09-14 20:29:41 +00:00