Index of values


A
a [Mindstorm_NXT.Motor]
The motor port A.
all [Mindstorm_NXT.Motor]
Special value representing all 3 ports.

B
b [Mindstorm_NXT.Motor]
The motor port B.
battery_level [Mindstorm_NXT]
battery_level conn return the voltages in millivolts of the battery on the brick.
bluetooth_reset [Mindstorm_NXT]
bluetooth_reset conn performs a factory reset of the brick.
boot [Mindstorm_NXT]
bricks [Mindstorm_NXT.USB]
bricks() returns the list of LEGO NXT bricks on the USB bus.

C
c [Mindstorm_NXT.Motor]
The motor port C.
close [Mindstorm_EV3]
close conn closes the connection conn to the brick.
close [Mindstorm_NXT.Find]
close_iterator i closes the iterator i.
close [Mindstorm_NXT]
close conn closes the connection conn to the brick.
close_in [Mindstorm_NXT]
close_in ch closes the channel ch.
close_out [Mindstorm_NXT]
close_out ch closes the channel ch.
color_of_data [Mindstorm_NXT.Sensor]
Returns the color seen by the color sensor from its reading.
connect [Mindstorm_NXT.USB]
connect dev connect through USB to the brick device dev (given by Mindstorm.NXT.USB.bricks).
connect_bluetooth [Mindstorm_EV3]
connect_bluetooth bdaddr connects through bluetooth to the brick with bluetooth address bdaddr.
connect_bluetooth [Mindstorm_NXT]
connect_bluetooth bdaddr connects through bluetooth to the brick with bluetooth address bdaddr.
current [Mindstorm_NXT.Find]
Find.current i returns the current filename.
current_size [Mindstorm_NXT.Find]
Find.current_size i returns the current filename size (number of bytes).

D
delete_user_flash [Mindstorm_NXT]

F
firmware_version [Mindstorm_NXT]
firmware_version conn returns a tuple (p1, p0, f1, f0) where p1 is the major version of the protocol, p0 is the minor version of the protocol, f1 is the major version of the firmware, f0 is the minor version of the firmware,
fold [Mindstorm_NXT.Find]
fold f fpatt a0 folds f on all the filenames matching the pattern fpatt (see Mindstorm.NXT.Find.patt for the accepted patterns).

G
get [Mindstorm_NXT.Sensor.Ultrasonic]
Ultrasonic.get us var returns the content of the variable var on the sensor (detailed underneath).
get [Mindstorm_NXT.Sensor]
get conn p returns the data read on port p.
get [Mindstorm_NXT.Motor]
get conn p returns (state, tach_count, block_tach_count, rotation_count) where state is the current state of the motors;, tach_count is the number of counts since the last reset of the motor counter (the reset occurs when Mindstorm.NXT.Motor.set is issued);, block_tach_count is the current position relative to the last programmed movement., rotation_count is the program-relative position counter relative to the last reset of the rotation sensor for motorĀ p.
get_device_info [Mindstorm_NXT]
get_device_info conn returns some informations about the brick connected through conn.
get_state [Mindstorm_NXT.Sensor.Ultrasonic]
get_state us get the current state of the ultrasonic sensor us.
get_status [Mindstorm_NXT.Sensor]
get_status conn port returns the number of bytes ready to be read.

I
in_channel_length [Mindstorm_NXT]
in_channel_length ch returns the length of the channel ch.
input [Mindstorm_NXT]
input ch buf ofs len reads a block of data of length len from the channel ch and write it to buf starting at position ofs.
iter [Mindstorm_NXT.Find]
iter f fpatt iterates f name size on all the filenames matching the pattern fpatt (see Mindstorm.NXT.Find.patt for the accepted patterns).

K
keep_alive [Mindstorm_NXT]
keep_alive conn returns the current sleep time limit in milliseconds.

M
make [Mindstorm_NXT.Sensor.Ultrasonic]
make conn port initialize the sensor on port port as being an ultrasonic one.
map [Mindstorm_NXT.Find]
map f fpatt maps f name size on all the filenames matching the pattern fpatt and return the list formed of those.

N
name [Mindstorm_NXT.Program]
Return the name of the current program or raise Mindstorm.NXT.Error(No_program) if no program is running.
next [Mindstorm_NXT.Find]
Execute a new request to the brick to retrieve the next filename matching the pattern.

O
open_in [Mindstorm_NXT]
open_in conn fname opens the file named fname on the brick for reading.
open_out [Mindstorm_NXT]
open_out conn flag fname opens the file fname for writing.
output [Mindstorm_NXT]
output ch buf ofs len ouputs the substring buf.[ofs .. ofs+len-1] to the channel fd.

P
patt [Mindstorm_NXT.Find]
Find.patt conn fpatt returns an iterator listing the filenames mathing the pattern fpatt.
play [Mindstorm_NXT.Sound]
play_soundfile conn file plays the sound file named file.
play_tone [Mindstorm_NXT.Sound]
play_tone conn freq duration play a tone with freq Hz lasting duration miliseconds.
poll_command [Mindstorm_NXT]
Reads bytes from the low-speed or high-speed buffer.
poll_length [Mindstorm_NXT]
Returns the number of bytes for a command in the low-speed buffer or the high-speed buffer (0 = no command is ready).

R
read [Mindstorm_NXT.Message]
read conn box returns the message from the inbox box on the NXT.
read [Mindstorm_NXT.Sensor]
Read data from from lowspeed I2C port (e.g.
remove [Mindstorm_NXT]
remove conn fname remove the file fname from the brick.
reset_pos [Mindstorm_NXT.Motor]
reset_pos conn p resets the rotation count (given by the rotation_count field of Mindstorm.NXT.Motor.get) of the motor connected to port p.
reset_scaled [Mindstorm_NXT.Sensor]
reset_scaled conn port

S
set [Mindstorm_NXT.Sensor.Ultrasonic]
Ultrasonic.set us cmd set the state or parameters for the ultrasonic sensor us.
set [Mindstorm_NXT.Sensor]
set conn p ty m set the sensor connected to port p to type ty and mode m.
set [Mindstorm_NXT.Motor]
set conn p st sets the state of the motor connected to the port p to st.
set_brick_name [Mindstorm_NXT]
set_brick_name conn name change the name to which one is connected through conn to name.
speed [Mindstorm_NXT.Motor]
speed s returns a state where speed is s, motor_on is true if and only if s <> 0, and run_state = `Running.
start [Mindstorm_NXT.Program]
start_program conn pgm starts the program named pgm.
stop [Mindstorm_NXT.Sound]
Stop the current playback.
stop [Mindstorm_NXT.Program]
stop_program conn stops the currently running program if any.

T
tone [Mindstorm_EV3.Sound]
tone conn vol freq dur plays a sound with volume vol (in 0 .. 100), frequency freq (in 250 .. 10000) for the duration of ms miliseconds (in 0 .. 32767.

W
write [Mindstorm_NXT.Message]
write conn box msg writes the message msg to the inbox box on the NXT.
write [Mindstorm_NXT.Sensor]
write conn port yx_data writes tx_data to lowspeed I2C sensor connected to the port.