Analog I/O

Analog inputs allow the PLC to read variable values from sensors, such as temperature, pressure, or flow, by converting physical measurements into electrical signals, typically in the form of voltage (e.g., 0-10V) or current (e.g., 4-20mA). Conversely, analog outputs enable the PLC to control devices like motors, valves, or actuators by sending continuous electrical signals to adjust their operation with precision. These I/O channels are crucial for processes that require more than simple on/off control, providing fine-tuned adjustments to optimize performance in dynamic environments. Analog I/O API provides interface for controlling all analog inputs and outputs on your controller.

API Reference

List All Analog Inputs

get
Responses
200
Successful Response
application/json
get
GET /controller/ai HTTP/1.1
Host: robopipe-1.local
Accept: */*
200

Successful Response

[
  {
    "dev": "text",
    "circuit": "text",
    "modes": {
      "ANY_ADDITIONAL_PROPERTY": {
        "value": 1,
        "unit": "text",
        "range": []
      }
    },
    "mode": "Voltage"
  }
]

Get Analog Input

get
Path parameters
circuitstringRequired
Responses
200
Successful Response
application/json
get
GET /controller/ai/{circuit} HTTP/1.1
Host: robopipe-1.local
Accept: */*
{
  "dev": "text",
  "circuit": "text",
  "modes": {
    "ANY_ADDITIONAL_PROPERTY": {
      "value": 1,
      "unit": "text",
      "range": []
    }
  },
  "mode": "Voltage"
}

Set Analog Input

post
Path parameters
circuitstringRequired
Body
modestring · enumOptionalDefault: VoltagePossible values:
Responses
200
Successful Response
application/json
post
POST /controller/ai/{circuit} HTTP/1.1
Host: robopipe-1.local
Content-Type: application/json
Accept: */*
Content-Length: 18

{
  "mode": "Voltage"
}
{
  "dev": "text",
  "circuit": "text",
  "modes": {
    "ANY_ADDITIONAL_PROPERTY": {
      "value": 1,
      "unit": "text",
      "range": []
    }
  },
  "mode": "Voltage"
}

Set All Analog Inputs

post
Body
modestring · enumOptionalDefault: VoltagePossible values:
Responses
200
Successful Response
application/json
post
POST /controller/ai HTTP/1.1
Host: robopipe-1.local
Content-Type: application/json
Accept: */*
Content-Length: 18

{
  "mode": "Voltage"
}
[
  {
    "dev": "text",
    "circuit": "text",
    "modes": {
      "ANY_ADDITIONAL_PROPERTY": {
        "value": 1,
        "unit": "text",
        "range": []
      }
    },
    "mode": "Voltage"
  }
]

List All Analog Outputs

get
Responses
200
Successful Response
application/json
get
GET /controller/ao HTTP/1.1
Host: robopipe-1.local
Accept: */*
200

Successful Response

[
  {
    "dev": "text",
    "circuit": "text",
    "modes": {
      "ANY_ADDITIONAL_PROPERTY": {
        "value": 1,
        "unit": "text",
        "range": []
      }
    },
    "value": 1,
    "mode": "Voltage"
  }
]

Get Analog Output

get
Path parameters
circuitstringRequired
Responses
200
Successful Response
application/json
get
GET /controller/ao/{circuit} HTTP/1.1
Host: robopipe-1.local
Accept: */*
{
  "dev": "text",
  "circuit": "text",
  "modes": {
    "ANY_ADDITIONAL_PROPERTY": {
      "value": 1,
      "unit": "text",
      "range": []
    }
  },
  "value": 1,
  "mode": "Voltage"
}

Set Analog Output

post
Path parameters
circuitstringRequired
Body
valuenumberRequired
modestring · enumOptionalDefault: VoltagePossible values:
Responses
200
Successful Response
application/json
post
POST /controller/ao/{circuit} HTTP/1.1
Host: robopipe-1.local
Content-Type: application/json
Accept: */*
Content-Length: 28

{
  "value": 1,
  "mode": "Voltage"
}
{
  "dev": "text",
  "circuit": "text",
  "modes": {
    "ANY_ADDITIONAL_PROPERTY": {
      "value": 1,
      "unit": "text",
      "range": []
    }
  },
  "value": 1,
  "mode": "Voltage"
}

Set All Analog Outputs

post
Body
valuenumberRequired
modestring · enumOptionalDefault: VoltagePossible values:
Responses
200
Successful Response
application/json
post
POST /controller/ao HTTP/1.1
Host: robopipe-1.local
Content-Type: application/json
Accept: */*
Content-Length: 28

{
  "value": 1,
  "mode": "Voltage"
}
[
  {
    "dev": "text",
    "circuit": "text",
    "modes": {
      "ANY_ADDITIONAL_PROPERTY": {
        "value": 1,
        "unit": "text",
        "range": []
      }
    },
    "value": 1,
    "mode": "Voltage"
  }
]

Last updated