device(), n_device()

$ret = device( $i);
Returns the name of the i-th device. i starts at 0.

$ret = n_device();
Returns the number of devices.