Andrew Tridgell
b34d0c9c87
AP_HAL: removed vector based I2C get_device
...
this is unused and prevents building on QURT
2024-07-11 11:20:47 +10:00
Andy Piper
a73945c1b3
AP_HAL: rename QSPIDevice to WSPIDevice
2023-04-28 08:31:15 +10:00
bugobliterator
1934b4a738
AP_HAL: move function definitions to cpp to save flash
2022-05-25 18:14:46 +10:00
bugobliterator
e26ffc4ec5
AP_HAL: add mechanism to set register rw register using device name for SPI
2022-05-25 18:14:46 +10:00
Mirko Denecke
853fd7f8c1
AP_HAL: fix auxiliary typo
2022-05-02 10:55:08 +10:00
Siddharth Purohit
2af3864b61
AP_HAL: add support for entering XIP mode
2021-06-30 19:33:17 +10:00
Siddharth Purohit
a323807644
AP_HAL: add support for QSPIDevice
2021-06-30 19:33:17 +10:00
Andrew Tridgell
7010eae9e8
AP_HAL: remember details of register check fails
...
this allows for logging of register resets
2021-02-24 18:18:37 +11:00
Patrick José Pereira
12cd138030
AP_HAL: Remove pointer check before delete
...
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2021-02-04 09:01:19 +11:00
Patrick José Pereira
6899c0b5af
AP_HAL: Add missing const in member functions
...
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2021-02-03 18:45:14 +11:00
Andrew Tridgell
75c789fc57
AP_Baro: added ExternalAHRS backend
2021-01-05 21:13:12 +11:00
Andrew Tridgell
4b1552eebe
AP_HAL: added BUS_TYPE_MSP
...
for MSP sensors
2020-09-09 06:35:50 +10:00
bugobliterator
57dd0ca9ea
AP_HAL: add support for Bank based addressing
2020-08-06 12:41:35 +10:00
Siddharth Purohit
d31b44fa79
AP_HAL: add methods to extract devid details
2020-07-27 19:48:15 +10:00
Andrew Tridgell
464dc9102f
AP_HAL: added device types for SITL
...
and fixed a stack init bug for make_bus_id
2018-07-13 10:19:01 +10:00
Andrew Tridgell
2b0a3272fd
AP_HAL: support LPS25H on MPU AUX
2018-03-02 12:52:50 +11:00
night-ghost
f8569ac39e
AP_HAL: added F4Light HAL
2018-02-10 09:14:41 +11:00
Lucas De Marchi
a73c1daa2e
AP_HAL: Device: remove unused function to read registers
...
Callers can use be16toh(), be32toh(), etc. There's no need to have a
special function here for each type.
2017-01-26 23:18:27 -08:00
Lucas De Marchi
14519e90ff
AP_HAL: Device: remove trailing whitespaces
2017-01-26 23:18:27 -08:00
Lucas De Marchi
5472bc4de1
Global: change Device::PeriodicCb signature
...
Remove bool return as it's never being used and not supported on PX4.
2017-01-14 10:03:54 +11:00
Randy Mackay
a2f6d7c102
AP_HAL: minor comment fix to Device.h
2016-12-24 13:55:31 +09:00
Andrew Tridgell
c657ad449b
AP_HAL: added get_bus_address()
...
used to report sensor probing results in drivers
2016-12-05 16:51:49 -08:00
Andrew Tridgell
60c29417f1
AP_HAL: added uint16 access functions
2016-12-05 16:51:49 -08:00
Andrew Tridgell
28a318145c
AP_HAL: move set_retries() up to Device class
...
we really need set_retries() high during init for nearly all i2c
devices, and as many are written against the generic device class
moving it to the Device class makes this a lot easier. It is a NOP on
SPI.
2016-12-02 09:47:51 +11:00
Andrew Tridgell
00ccacb2ab
AP_HAL: expose device bus number
2016-11-28 10:18:32 +11:00
Andrew Tridgell
954728c9e9
AP_HAL: added set_chip_select() API
...
for devices with unusual timings
2016-11-25 21:26:27 +11:00
Andrew Tridgell
7100272f14
AP_HAL: default to register checking every 10th call
...
this saves having this in nearly all callers
2016-11-25 20:31:36 +11:00
Andrew Tridgell
bc614de4b3
AP_HAL: added checked registers interface
...
allow drivers to easily monitor and correct critical registers
2016-11-11 08:08:55 +11:00
Andrew Tridgell
1990aa96e1
AP_HAL: added get_bus_id_devtype()
...
used to do versioning on device types
2016-11-09 17:08:06 +11:00
Andrew Tridgell
3d48b6bb3a
AP_HAL: added device id tuples to Device class
...
this allows a bus connection and device type tuple to be identifed as
a 24 bit number for use in user visible device IDs. Every bus
connection has a unique device ID.
2016-11-09 17:08:04 +11:00
Mathieu OTHACEHE
152edf7189
Global: remove mode line from headers
...
Using a global .dir-locals.el file is a better alternative than
reincluding the same emacs header in every file of the project.
2016-10-24 09:42:01 -02:00
Lucas De Marchi
e1ab44f4a3
Global: remove get_fd() from Device API
...
This was there for compatibility with I2CDriver and SPIDriver. We don't
use them anymore so we can remove the compat method.
2016-08-29 10:27:36 -03:00
Lucas De Marchi
590539f674
AP_HAL_Linux: implement threaded I2C
2016-07-30 00:55:27 -03:00
Lucas De Marchi
37de995960
AP_HAL: update Device interface for periodic tasks
...
Replace the previous not-implemented interface with a set of new methods
that can be resonably implemented:
- register_periodic_callback() now receives a functor returning bool
to easily allow "oneshot" timers
- adjust_periodic_callback() allows the caller to change the timer
for a specific handle. This way drivers like MS5611 can adjust the
timer depending on its state machine: the time to sample
temperature is smaller than the time to get a pressure sample
- add unregister_callback(): since we have an opaque pointer, we
can't tell the user to just delete it in order to unregister the
callback
2016-07-30 00:55:27 -03:00
Luiz Ywata
d5449a6f20
AP_HAL: Add read method
...
Provide a more intuitive api for reading an I2CDevice.
2016-07-14 17:32:33 -03:00
Lucas De Marchi
1f96336f7c
Global: rename bus type enum entries
2016-06-27 17:51:41 -03:00
Gustavo Jose de Sousa
66f1ad9ed0
AP_HAL: Device: add support for read flag
...
Many of our SPI and I2C sensors define the protocol of setting the most
significant bit of the register address in order to perform a read operation.
Thus, enable the use of a "read flag" that is ORed with the register's address.
Since this is an abstraction for general devices, it's a good idea to have zero
as the default value for that flag.
While at it, add documentation to read_registers().
2016-06-27 17:18:35 -03:00
Gustavo Jose de Sousa
b6a1d598e3
AP_HAL: Device: document write_register()
2016-06-27 17:18:35 -03:00
Gustavo Jose de Sousa
4693501d9d
AP_HAL: Device: add bus_type field
...
Sometimes it's necessary to know the type of bus to make some decisions where
AP_HAL::Device abstraction is used.
2016-06-27 17:18:35 -03:00
Ricardo de Almeida Gonzaga
eb418f54ee
AP_HAL: Fix typos
2016-05-13 19:20:06 -03:00
Lucas De Marchi
f8e6c5b379
AP_HAL: add helper method to read registers
...
This just forwards to the transfer() method, avoiding the need in driver
code to have a similar method.
2016-02-16 19:49:08 -02:00
Lucas De Marchi
b4ff2d7595
AP_HAL: add helper method to write register
...
This just forwards to the transfer() method, avoiding the need in driver
code to have a similar method.
2016-02-16 19:49:08 -02:00
Lucas De Marchi
0eb450d379
AP_HAL: Add interface for I2C/SPI devices
...
These interfaces are intended to abstract I2C and SPI devices for
drivers.
2016-02-16 19:49:08 -02:00