17
by Deepak
more Device API's from mindsensors.com |
1 |
I2C device API's |
2 |
||
3 |
NXTServo: |
|
4 |
~getBatteryVoltage() |
|
5 |
-Retrieves the battery voltage |
|
6 |
~storeInitial() |
|
7 |
-Store the initial speed and position properties of a servo |
|
8 |
~reset() |
|
9 |
-Reset servo properties to factory default |
|
10 |
~halfMacro() |
|
11 |
-Re-initializes the macro enviornment |
|
12 |
~resumeMacro() |
|
13 |
-Resumes macro when it was paused in the same enviornment |
|
14 |
~gotoEEPROM() |
|
15 |
-Re-initializes the macro enviornment |
|
16 |
~editMacro() |
|
17 |
-Edit macro |
|
18 |
~pauseMacro() |
|
19 |
-Pauses the macro, and saves for subsequent resumption |
|
20 |
~setSpeed(uint8_t number, uint8_t speed) |
|
21 |
-Set speed of servo |
|
22 |
*number:Servo_1, 2, ..., 8 |
|
23 |
*speed [0, inf] or Servo_Speed_Full |
|
24 |
~setPosition(uint8_t number, uint8_t position) |
|
25 |
-Set position of servo |
|
26 |
*number:Servo_1, 2, ..., 8 |
|
27 |
*position [500, 2500] or Servo_Position_Default |
|
28 |
~runServo(uint8_t number, uint8_t position, uint8_t speed) |
|
29 |
-Run a Servo to a certain position at a certain speed |
|
30 |
*number:Servo_1, 2, ..., 8 |
|
31 |
*speed [500, 2500] or Servo_Position_Default |
|
32 |
*position [500, 2500] or Servo_Position_Default |
|
33 |
||
34 |
||
35 |
PFMate: |
|
36 |
~issueCommand(char command) |
|
37 |
~sendSignal() |
|
38 |
~controlMotor(uint8_t channel, uint8_t contol, uint8_t operation, uint8_t speed) |
|
39 |
-Control the PF Motors |
|
40 |
*channel : PF_Channel_1, 2, 3, or 4 |
|
41 |
*control : PF_Contol_Both, A, or B |
|
42 |
*operation : PF_Operation_Forward, Reverse, Float, or Brake |
|
43 |
*speed : [1, 7] or PF_Speed_Full, Medium, or Slow |
|
44 |
~setChannel(uint8_t channel) |
|
45 |
~setControl(uint8_t contol) |
|
46 |
~setOperationA(uint8_t operation) |
|
47 |
~setOperationB(uint8_t operation) |
|
48 |
~setSpeedA(uint8_t speed) |
|
49 |
~setSpeedB(uint8_t speed) |
|
50 |
||
51 |
||
52 |
NXTHID: |
|
53 |
~transmitData() |
|
54 |
-Transmit data to hsot computer |
|
55 |
~asciiMode() |
|
56 |
-Setup device for ascii data mode |
|
57 |
~directMode() |
|
58 |
-Setup device for direct data mode |
|
59 |
~setModifier(uint8_t mod) |
|
60 |
-Setup the key modifier |
|
61 |
*HID_None, L_Ctrl, L_Shift , L_Alt, L_GUI, R_Ctrl, R_Shift, R_Alt, R_GUI, |
|
62 |
~sendKeyboardData(uint8_t data) |
|
63 |
-Send specific key data |
|
64 |
||
65 |
||
66 |
NXTMMX: |
|
67 |
~getBatteryVoltage() |
|
68 |
~issueCommand(char command) |
|
69 |
~setEncoderTarget(uint8_t which_motor, long target) |
|
70 |
~getEncoderTarget(uint8_t which_motor) |
|
71 |
setSpeed(uint8_t which_motor, int speed) |
|
72 |
~getSpeed(uint8_t which_motor) |
|
73 |
~getTimeToRun(uint8_t which_motor, int seconds) |
|
74 |
~getTimeToRun(uint8_t which_motor) |
|
75 |
~setCommandRegB(uint8_t which_motor, uint8_t value) |
|
76 |
~getCommandRegB(uint8_t which_motor) |
|
77 |
~setCommandRegA(uint8_t which_motor, uint8_t value) |
|
78 |
~getCommandRegA(uint8_t which_motor) |
|
79 |
~getEncoderPosition(uint8_t which_motor) |
|
80 |
~getMotorStatusByte(uint8_t which_motor) |
|
81 |
~getMotorTasksRunningByte(uint8_t which_motor) |
|
82 |
~setEncoderPID(uint16_t Kp, uint16_t Ki, uint16_t Kd) |
|
83 |
~setSpeedPID(uint16_t Kp, uint16_t Ki, uint16_t Kd) |
|
84 |
~setPassCount(uint8_t pass_count) |
|
85 |
~setTolerance(uint8_t tolerance) |
|
86 |
~reset() |
|
87 |
~startMotorsInSync() |
|
88 |
~resetEncoder(uint8_t which_motor) |
|
89 |
~setSpeedTimeAndControl(uint8_t which_motors, int speed, uint8_t duration, uint8_t control) |
|
90 |
setEncoderSpeedTimeAndControl(uint8_t which_motors, long encoder, int speed, uint8_t duration, uint8_t control) |
|
91 |
~isTimeDone(uint8_t which_motors) |
|
92 |
~waitUntilTimeDone(uint8_t which_motors) |
|
93 |
~isTachoDone(uint8_t which_motors) |
|
94 |
~waitUntilTachoDone(uint8_t which_motors) |
|
95 |
~runUnlimited(uint8_t which_motors, uint8_t direction, int speed) |
|
96 |
~runSeconds(uint8_t which_motors, uint8_t direction, int speed, uint8_t duration, uint8_t wait_for_completion, uint8_t next_action) |
|
97 |
~runTachometer(uint8_t which_motors, uint8_t direction, int speed, long tachometer, uint8_t relative, uint8_t wait_for_completion, uint8_t next_action) |
|
98 |
~runDegrees(uint8_t which_motors, uint8_t direction,int speed, long degrees, uint8_t wait_for_completion, uint8_t next_action) |
|
99 |
~void runRotations(uint8_t which_motors, uint8_t direction, int speed, long rotations, uint8_t wait_for_completion, uint8_t next_action)~stop(uint8_t which_motors, uint8_t next_action) |
|
100 |
||
101 |
ACCLNx: |
|
102 |
~issueCommand(char command) |
|
103 |
~aquireXpointCalibration() |
|
104 |
~aquireXpointCalibrationEnd() |
|
105 |
~aquireYpointCalibration() |
|
106 |
~aquireYpointCalibrationEnd() |
|
107 |
~aquireZpointCalibration() |
|
108 |
~aquireZpointCalibrationEnd() |
|
109 |
~resetFactory() |
|
110 |
~setApdaOn() |
|
111 |
~setApdaOff() |
|
112 |
~getXTilt() |
|
113 |
~getYTilt() |
|
114 |
~getZTilt() |
|
115 |
~getXAccl() |
|
116 |
~getYAccl() |
|
117 |
~getZAccl() |
|
118 |
~getSens() |
|
119 |
||
120 |
DISTNx: |
|
121 |
~issueCommand(char command) |
|
122 |
~setModuleGP2D12() |
|
123 |
~setModuleGP2D120() |
|
124 |
~setModuleGP2Y0A21YK() |
|
125 |
~setModuleGP2Y0A02YK() |
|
126 |
~setModuleCustom() |
|
127 |
~energized() |
|
128 |
~deenergized() |
|
129 |
~setApdaOn() |
|
130 |
~setApdaOff() |
|
131 |
~getDist() |
|
132 |
~getVolt() |
|
133 |
~getType() |
|
134 |
||
135 |
PSPNx: |
|
136 |
~issueCommand(char command) |
|
137 |
~energized() |
|
138 |
~deenergized() |
|
139 |
~setDigitalMode() |
|
140 |
~setAnalogMode() |
|
141 |
~setApdaOn() |
|
142 |
~setApdaOff() |
|
143 |
~getXLJoy() |
|
144 |
~getYLJoy() |
|
145 |
~getXRJoy() |
|
146 |
~getYRJoy() |
|
147 |
~getButtons(int *buttons1, int *buttons2); |
|
148 |
||
149 |
LineLeader: |
|
150 |
~issueCommand(char command) |
|
151 |
~calibrateWhite() |
|
152 |
~calibrateBlack() |
|
153 |
~sleep() |
|
154 |
~wakeUp() |
|
155 |
~invertLineColorToWhite() |
|
156 |
~resetColorInversion() |
|
157 |
~takeSnapshot() |
|
158 |
~configureUS() |
|
159 |
~configureEurope() |
|
160 |
~configureUniversal() |
|
161 |
~getSetPoint() |
|
162 |
~setSetPoint(uint8_t spoint) |
|
163 |
~getKp() |
|
164 |
~setKp(uint8_t kp) |
|
165 |
~getKi() |
|
166 |
~setKi(uint8_t ki); |
|
167 |
~getKd() |
|
168 |
~setKd(uint8_t kd) |
|
169 |
~getKpFactor() |
|
170 |
~setKpFactor(uint8_t kpfact) |
|
171 |
~getKiFactor() |
|
172 |
~setKiFactor(uint8_t kifact) |
|
173 |
~getKdFactor() |
|
174 |
~setKdFactor(uint8_t kdfact) |
|
175 |
~getSteering() |
|
176 |
~getAverage() |
|
177 |
~getResult() |
|
178 |
~getRawCalibrated() |
|
179 |
~getRawUncalibrated() |
|
180 |
~getWhiteLimit() |
|
181 |
~getBlackLimit() |
|
182 |
~getWhiteCalibration() |
|
183 |
~getBlackCalibration() |
|
184 |
||
185 |
NXTPowerMeter: |
|
186 |
~issueCommand(char command) |
|
187 |
~resetCounters() |
|
188 |
~readPresentCurrent() |
|
189 |
~readPresentVoltage() |
|
190 |
~readCapacityUsed() |
|
191 |
~readElapsedTime() |
|
192 |
||
193 |
RTC: |
|
194 |
~getSeconds() |
|
195 |
~getMinutes() |
|
196 |
~getHours() |
|
197 |
~getDayWeek() |
|
198 |
~getDayMonth() |
|
199 |
~getMonth() |
|
200 |
~getYear() |
|
201 |
||
202 |
NXTCam: |
|
203 |
~issueCommand(char command) |
|
204 |
~sortSize() |
|
205 |
~selectObjectMode() |
|
206 |
~writeImageRegisters() |
|
207 |
~disableTracking() |
|
208 |
~enableTracking() |
|
209 |
~getColorMap() |
|
210 |
~illuminationOn() |
|
211 |
~readImageRegisters() |
|
212 |
~selectLineMode() |
|
213 |
~adpaOn() |
|
214 |
~adpaOff() |
|
215 |
~pingCam() |
|
216 |
~resetCam() |
|
217 |
~sendColorMap() |
|
218 |
~illuminationOff() |
|
219 |
~sortColor() |
|
220 |
~sortNone() |
|
221 |
~camFirmware() |
|
222 |
~getNumberObjects() |
|
223 |
~getBlobs(int *nblobs, uint8_t *color, uint8_t *left, uint8_t *top, uint8_t *right, uint8_t *bottom) |