Keyence KV (Upper Link / Host Link)
Collects data from Keyence KV series PLCs such as KV-7500 / KV-8000 using the Upper Link (上位リンク) ASCII protocol. Because plain-text commands are exchanged over the built-in Ethernet port, no separate communication unit is required.
Both reading and writing are supported.
The communication format of this driver was implemented based on public specifications and has not been verified against actual KV equipment. On first integration, start with a few tags and confirm that the values are correct. If the format differs, only the command assembly section of the driver needs to be modified, so a fix can be made quickly.
Registration form entries
| Input field | What to enter | Example |
|---|---|---|
| IP address | Built-in Ethernet IP of the KV-7500/8000 | 192.168.0.10 |
| Port | Upper Link port | 8501 (default) |
The form's default port value is shared with other protocols and is not the KV default (8501). Be sure to enter 8501 (or the port configured on the equipment).
Advanced options
| Option key | Default | Description |
|---|---|---|
connect-timeout | 3000 | Connection timeout (ms) |
read-timeout | 3000 | Response timeout (ms) |
line-ending | cr | Terminator character. If the equipment is set to CRLF, use crlf |
PLC address notation for tags
The format is <device><number>[.<suffix>].
| Notation | Meaning |
|---|---|
DM100 | Data memory No. 100 |
DM100.U | Read as unsigned 16-bit |
DM200.L | Read as signed 32-bit |
R500 | Bit (relay) |
TC10 | Timer current value |
Devices
| Category | Device |
|---|---|
| Word | DM EM FM ZF W TC (timer current value) TS (set value) CTH CTC C T |
| Bit | R MR LR CR B |
Data format suffixes
| Suffix | Meaning |
|---|---|
.U | Unsigned 16-bit |
.S | Signed 16-bit |
.D | Unsigned 32-bit |
.L | Signed 32-bit |
.H | 16-bit hexadecimal |
If the suffix is omitted, the width of the data type specified on the tag is used.
Writing
- Word: the value is written as-is.
- Bit: a value of
1/true/onturns the bit ON; anything else turns it OFF.
If the PLC is in program mode or write-protected, writes are rejected (E4). The driver does not switch the operating mode automatically — a collector changing the PLC mode could stop the equipment. Leave the PLC in a write-enabled state on the PLC side.
Troubleshooting
| Symptom | Possible cause | Check |
|---|---|---|
| Cannot connect | Port is not 8501 | Check the port field on the form |
| Connects but values are empty | Address notation error (E0) | Check the device name/number and look for read rejected messages in the log |
| Values look wrong | Suffix does not match the tag data type | Match .U/.S/.D/.L to the tag type |
| Cannot write | PLC in program mode / write-protected (E4) | Set the PLC to RUN + write-enabled |
| Collection drops intermittently | Delayed responses | Try increasing read-timeout |
This protocol has no checksum for error detection. Therefore, if a response is delayed and a timeout occurs, the connection is discarded and a new one is established — this prevents a late-arriving response from being misread as the value of the next tag. Reconnection is handled automatically by the gateway.