mirror of
https://github.com/eclipse/upm.git
synced 2025-03-14 20:47:30 +03:00
max31723: added bus parameter to constructor
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
This commit is contained in:
parent
d004aa68b7
commit
7e5f6e9856
@ -156,6 +156,9 @@ compatibility between releases:
|
||||
a SPI bus number. This is now the first parameter, the number of LEDs on the
|
||||
strip is now the last (3rd) parameter instead.
|
||||
|
||||
* **max31723** The constructor for this driver was updated to allow specifying
|
||||
a SPI bus number. This is now the first parameter, CS pin second.
|
||||
|
||||
# v1.1.0
|
||||
|
||||
* **i2clcd/jhd1313m1/lcm1602** LCD devices supported by the i2clcd module are
|
||||
|
@ -44,7 +44,7 @@ int
|
||||
main(int argc, char **argv)
|
||||
{
|
||||
//! [Interesting]
|
||||
sensor = new upm::MAX31723(7);
|
||||
sensor = new upm::MAX31723(0, 7);
|
||||
usleep (1000000);
|
||||
|
||||
while (!doWork) {
|
||||
|
@ -31,7 +31,7 @@
|
||||
|
||||
using namespace upm;
|
||||
|
||||
MAX31723::MAX31723 (int csn) : m_spi(0), m_csnPinCtx(csn) {
|
||||
MAX31723::MAX31723 (int bus, int csn) : m_spi(bus), m_csnPinCtx(csn) {
|
||||
mraa::Result error = mraa::SUCCESS;
|
||||
m_name = "MAX31723";
|
||||
|
||||
|
@ -72,10 +72,10 @@ class MAX31723 {
|
||||
/**
|
||||
* Instantiates an MAX31723 object
|
||||
*
|
||||
* @param bus Number of the used bus
|
||||
* @param bus Number of the SPI bus used
|
||||
* @param csn Chip select (slave select) pin to use
|
||||
*/
|
||||
MAX31723 (int csn);
|
||||
MAX31723 (int bus, int csn);
|
||||
|
||||
/**
|
||||
* MAXDS3231M object destructor; basically, it closes the I2C connection.
|
||||
|
Loading…
x
Reference in New Issue
Block a user