RX(4) UNIX Programmer's Manual RX(4) NAME rx - dual-density floppy disk DESCRIPTION The files /d_e_v_/*r_x_* access the RX02 double-density floppy drive. R_x_0_l_ is drive 0, at low density; changing l to h switches to high density, swapping 1 for 0 references the other drive. The r_x_* files are traditional UNIX block devices; reads and writes may be of any size and need not be sector-aligned. Raw access is provided by r_r_x_*; reads and writes to these files must be multiples of a UNIX block (512 bytes) and start on a block boundary. Both r_x_* and r_r_x_* use the DEC standard sector mapping algo- rithm. This ignores the first track, and skips roughly six sectors between accesses. See DEC documentation for further info. The `really raw' files r_r_r_x_* bypass the mapping algo- rithm; they treat the disk as a contiguous array of physical sectors. One i_o_c_t_l_ function is available: ioctl(fd, RIOCINI, 0); will initialize a diskette. The density to use is taken from the file opened; eg, to set drive 1 to double-density, do fd = open("/dev/rrx1h", 1); ioctl(fd, RIOCINI, 0); Only one open is allowed on a given drive at a given time. BUGS The restriction to a single open makes it messy to construct a filesystem on a floppy, as many maintenance programs such as m_k_f_s_ and f_s_c_k_ open the device twice. Given the security problems inherent in user-mounted filesystems, and the non- portable nature of the format, this isn't a big problem; we just don't let people do it. Printed 6/15/82 HEP 1