mirror of
https://github.com/eclipse/upm.git
synced 2025-07-01 09:21:12 +03:00
lsm303: rename to lsm303dlh
There are a variety of LSM303 devices out there with various incompatibilities and differing capabilities. The current lsm303 driver in UPM only supports the LSM303DLH variant, so it has been renamed to lsm303dlh to avoid confusion and to make it clear which variant is actually supported. All examples and source files have been renamed, including header files. In addition, the class name, LSM303, has been renamed to LSM303DLH. No other functionality or behavior has been changed. Signed-off-by: Jon Trulson <jtrulson@ics.com>
This commit is contained in:
@ -86,7 +86,7 @@ add_example(Itg3200Sample itg3200)
|
||||
add_example(Joystick12Sample joystick12)
|
||||
add_example(LDT0028Sample ldt0028)
|
||||
add_example(LoLSample lol)
|
||||
add_example(LSM303Sample lsm303)
|
||||
add_example(LSM303DLHSample lsm303dlh)
|
||||
add_example(M24LR64ESample m24lr64e)
|
||||
add_example(MAX44000Sample max44000)
|
||||
add_example(MHZ16Sample mhz16)
|
||||
|
@ -23,12 +23,12 @@
|
||||
*/
|
||||
|
||||
//NOT TESTED!!!
|
||||
public class LSM303Sample {
|
||||
public class LSM303DLHSample {
|
||||
|
||||
public static void main(String[] args) throws InterruptedException {
|
||||
// ! [Interesting]
|
||||
// Instantiate LSM303 compass on I2C
|
||||
upm_lsm303.LSM303 sensor = new upm_lsm303.LSM303(0);
|
||||
// Instantiate LSM303DLH compass on I2C
|
||||
upm_lsm303dlh.LSM303DLH sensor = new upm_lsm303dlh.LSM303DLH(0);
|
||||
|
||||
// Get the coordinate data
|
||||
sensor.getCoordinates();
|
||||
@ -56,4 +56,4 @@ public class LSM303Sample {
|
||||
// ! [Interesting]
|
||||
}
|
||||
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user