# IO - OSC
[OSC]

Control any pin's direction and output from OSC. More...

Control any pin's direction and output from OSC.

The IO system allows for the manual manipulation of individual signal lines on the Make Controller. Proceed with care if you're using these at the same time as any of the other subsystems, as most other subsystems rely on the IO system internally to maintain control of the appropriate signal lines.

## Devices

There are 64 IO's on the Make Controller, numbered 0 - 63.

- IOs 0 - 31 correspond to PortA
- IOs 32 - 63 correspond to PortB.

## Properties

Each IO has four properties:

- output
- value
- pullup
- active

Output
  The output property sets whether the IO is an output. A value of 1 makes it an output, and a value of 0 makes it an input. For example, to make pin 4 an output, send a message like

      /io/4/output 1

  Send the message

      /io/4/output 0

  to make it an input.

Pullup
  The pullup property determines whether a given IOs pullup resistor is enabled. To enable it on IO 2, send the message

      /io/2/pullup 1

  and to disable it, send the message

      /io/2/pullup 0

Value
  Writing the value property sets the on/off value of a given IO. The IO system only permits digital IO so, we only want to send ones and zeros as values. For example, to activate pin 4, send a message like

      /io/4/value 1

  Change the argument 1 to a 0 to turn it off. Reading the value property returns the value of a given IO. For example, to read pin 4, send a message like

      /io/4/value

Active
  The active property corresponds to the active state of an IO. Read whether IO 0 is active by sending the message

      /io/0/active

  You can set the active flag by sending

      /io/0/active 1