mirror of
https://github.com/eclipse/upm.git
synced 2025-03-26 10:20:01 +03:00
adis16448: updated header and example with new tags
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
This commit is contained in:
parent
9544b7789d
commit
02147dfe4b
@ -47,6 +47,7 @@ main(int argc, char **argv)
|
|||||||
{
|
{
|
||||||
while(true)
|
while(true)
|
||||||
{
|
{
|
||||||
|
//! [Interesting]
|
||||||
upm::ADIS16448* imu = new upm::ADIS16448(0,3); //upm::ADIS16448(SPI,RST)
|
upm::ADIS16448* imu = new upm::ADIS16448(0,3); //upm::ADIS16448(SPI,RST)
|
||||||
|
|
||||||
//Read the specified register, scale it, and display it on the screen
|
//Read the specified register, scale it, and display it on the screen
|
||||||
@ -58,7 +59,7 @@ main(int argc, char **argv)
|
|||||||
std::cout << "YACCL_OUT:" << imu->accelScale(imu->regRead(YACCL_OUT)) << std::endl;
|
std::cout << "YACCL_OUT:" << imu->accelScale(imu->regRead(YACCL_OUT)) << std::endl;
|
||||||
std::cout << "ZACCL_OUT:" << imu->accelScale(imu->regRead(ZACCL_OUT)) << std::endl;
|
std::cout << "ZACCL_OUT:" << imu->accelScale(imu->regRead(ZACCL_OUT)) << std::endl;
|
||||||
std::cout << " " << std::endl;
|
std::cout << " " << std::endl;
|
||||||
|
//! [Interesting]
|
||||||
sleep(1);
|
sleep(1);
|
||||||
}
|
}
|
||||||
return (0);
|
return (0);
|
||||||
|
@ -83,8 +83,27 @@
|
|||||||
#define SERIAL_NUM 0x58 //Lot-specific serial number
|
#define SERIAL_NUM 0x58 //Lot-specific serial number
|
||||||
|
|
||||||
namespace upm {
|
namespace upm {
|
||||||
|
/**
|
||||||
|
* @brief Adis16448
|
||||||
|
* @defgroup adis16448 libupm-adis16488
|
||||||
|
* @ingroup generic spi accelerometer
|
||||||
|
*/
|
||||||
|
|
||||||
// ADIS16448 class definition
|
/**
|
||||||
|
* @library adis16448
|
||||||
|
* @sensor adis16448
|
||||||
|
* @comname ADIS16448 Accelerometer
|
||||||
|
* @type accelerometer
|
||||||
|
* @man generic
|
||||||
|
* @web http://www.analog.com/en/products/sensors/isensor-mems-inertial-measurement-units/adis16448.html
|
||||||
|
* @con spi
|
||||||
|
*
|
||||||
|
* @brief C++ API for Analog Devices ADIS16448
|
||||||
|
*
|
||||||
|
* This is an industrial grade accelerometer by Analog Devices.
|
||||||
|
*
|
||||||
|
* @snippet adis16448.cxx Interesting
|
||||||
|
*/
|
||||||
class ADIS16448{
|
class ADIS16448{
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user