CURRENT: this class provides functions for NXTCurrentMeter from mindsensors.com for read and write operations.
More...
|
tuple | CURRENT_ADDRESS = (0x28) |
| Default CurrentMeter I2C Address.
|
|
int | COMMAND = 0x41 |
| Command Register.
|
|
int | CAL = 0x43 |
| Absolute Calibrated Current value Register. More...
|
|
int | REL = 0x45 |
| Relative Current value Register. More...
|
|
int | REF = 0x47 |
| Reference Current value Register. More...
|
|
CURRENT: this class provides functions for NXTCurrentMeter from mindsensors.com for read and write operations.
def mindsensors.CURRENT.__init__ |
( |
|
self, |
|
|
|
current_address = CURRENT_ADDRESS |
|
) |
| |
Initialize the class with the i2c address of your NXTCurrentMeter.
- Parameters
-
self | The object pointer. |
current_address | Address of your NXTCurrentMeter. |
def mindsensors.CURRENT.command |
( |
|
self, |
|
|
|
cmd |
|
) |
| |
Writes a value to the command register.
- Parameters
-
self | The object pointer. |
cmd | Value to write to the command register. |
def mindsensors.CURRENT.get_calibrated |
( |
|
self | ) |
|
Reads the absolute current value in milliAmps.
- Parameters
-
def mindsensors.CURRENT.get_reference |
( |
|
self | ) |
|
Reads the reference current value in milliAmps.
- Parameters
-
def mindsensors.CURRENT.get_relative |
( |
|
self | ) |
|
Reads the relative current value in milliAmps.
- Parameters
-
def mindsensors.CURRENT.set_reference |
( |
|
self | ) |
|
Sets the reference current equal to the absolute current value.
- Parameters
-
int mindsensors.CURRENT.CAL = 0x43 |
|
static |
Absolute Calibrated Current value Register.
Will Return a signed integer value
int mindsensors.CURRENT.REF = 0x47 |
|
static |
Reference Current value Register.
Will Return a signed integer value
int mindsensors.CURRENT.REL = 0x45 |
|
static |
Relative Current value Register.
Will Return a signed integer value
The documentation for this class was generated from the following file:
- PiStorms/sys/mindsensors.py