Skip to content

1. Sensor Overview

Model catalog

Search for these models in ThinkLink by name or ID.

Model typeNameid_namePlatform model ID
RPC[CZ580 GET] paracz580_get_2210698886806983938053
RPC[CZ580 SET] paracz580_set_22106103495861979320325
TemplateCZ58098890586718736390
Thing Model[CZ580]cz580_2210698662809595809797
Thing Model[CZ-22106-CZ580资产] 区域聚合cz580_asset_22106119677174411063305
Parameter Thing Model[CZ580-PARA]cz580_para_22106103496386170851335

CZ580 is a rotational speed transmitter manufactured by Shanghai Chuanzhen Electronic Technology Co., Ltd. It performs non-contact rotational speed measurement based on the laser reflective-strip sensing principle, and can output either a 4–20 mA signal or an RS485 (Modbus-RTU) signal. It is suitable for rotational speed monitoring of various rotating machines.

The measurement range of the device is 0 to 10,000 rpm, making it suitable for low-speed applications and also capable of zero-speed detection.

In this integration solution, the device model is CZ580, the business code is 22106, and the template name is CZ580.


2. Product Features

According to the manufacturer’s documentation, the CZ580 has the following features:

  • Strong output signal
  • High anti-interference capability
  • Non-contact measurement
  • Wide operating range, suitable for low-speed measurement
  • Can be used in harsh environments such as smoke, oil vapor, and water mist

3. Application Scope

CZ580 can be widely used in the following scenarios:

  • Speed measurement of large rotating machinery in the power industry
  • Rotational equipment speed monitoring in the metallurgical industry
  • Speed measurement of compressors, motors, fans, pumps, and other equipment in the petrochemical industry
  • Speed measurement of large rotating machinery in the paper industry
  • Workpiece processing speed monitoring
  • Steel pipe coating line speed monitoring
  • Gear rotational speed measurement

4. Collector Information

4.1 Hardware Information

The data acquisition device used in this solution is KC21.

  • Device model: KC21
  • Interface: RS-485
  • Power supply: 220V / 12V

4.2 Wiring Information

Power Supply and Communication Interface

The RS485 output wiring definition of CZ580 is as follows:

  • Red wire: 9–30 VDC
  • Green wire: GND
  • Yellow wire: RS485-A
  • Blue wire: RS485-B

Sensor Interface

In this solution, the CZ580 has a built-in RS485 output interface and can be directly connected to the RS485 interface of KC21.

The power supply range of the sensor itself is 9–30 VDC.


5. Data Acquisition

In this solution, the following registers are read through Modbus:

  • 102: Number of sensing points per revolution
  • 2048–2049: Processed speed value, float, high word first
  • 2052–2053: Raw speed value, float, high word first

At the platform side, the following parameter addresses are defined:

  • Upload period parameter address: 70
  • Collection period parameter address: 74

And it is required that:

  • Collection period < Upload period

5.1 Register Definitions

According to the manufacturer’s Modbus register table, the main register definitions are as follows:

Address (Decimal)Item DescriptionData TypeDescription
0IN1 speed valueUShortSpeed value processed by sensing point count and scaling factor
1IN1 display decimal placesUShortRead-only, write invalid
5–6IN1 speed valueULongRaw speed = input frequency × 60
100IN1 measurement speed selectionUShort0: high speed, 1: medium speed, 2: low speed
101IN1 display decimal placesUShortRange 0–3
102IN1 sensing points per revolutionUShortRange 1–9999
103IN1 scaling decimal placesUShortRange 0–6
104IN1 scaling factorUShortRange 1–65535
2048–2049IN1 speed valuefloatProcessed speed value
2052–2053IN1 speed valuefloatRaw speed value = input frequency × 60
7166Communication parameter modification enable registerShortWrite 0xCCAA to enable communication parameter modification
7167RS485 addressShortRange 1–247
7168RS485 baud rateShort0–6, corresponding to 2400–115200
7169RS485 data formatShortRange 0–3

Supported Modbus function codes:

  • 03H, 04H: Read parameters
  • 06H, 10H: Modify parameters

6. EdgeBus Model

6.1 EB Configuration Parameters

The main configuration parameters are as follows:

  • name: "CZ580"
  • port: 22
  • version: "0x86"
  • dataType: "0x06"
  • upPeriodIndex: 70
  • Default Modbus serial parameters:
    • BaudRate: 9600
    • StopBits: 1
    • DataBits: 8
    • Checkbit: NONE
  • BzType: 22106
  • BzVersion: 11
  • SwVersion: 31

6.2 EB Code

typescript
import {Buffer} from "buffer";
import {buildOtaFile} from "@EBSDK/run";
import {LoraUpEvent} from "@EBSDK/EBCompiler/all_variable";
import {EBModel} from "@EBSDK/EBCompiler/EBModel/EBModel";
import {EventInfoItem} from "@EBSDK/EBCompiler/plugins/EBHelper";
import type {UserConfUPItem} from "@EBSDK/EBCompiler/plugins/EBHelper";
import {CheckbitEnum, getOtaConfig, HwTypeEnum} from "@EBSDK/otaConfig";
////////////////////////////////////////////////////////////////////////////////////////
const eventInfo:UserConfUPItem[]=[
    {
        name:"CZ580",port:22, version:"0x86",dataType:"0x06",upPeriodIndex:70,
        quInfo:[
            {
                protocol:"modbus",code:"0x03", periodIndex:74,//addr:"0x01",
                indexAPP:150, indexCMD:0, copySize:1,isLast:false,//period:"900s",payIndex:3,ackAddrIndex:0,
                listVal:[
                    { start: "102", end: "102"},
                ]
            },
            {
                protocol:"modbus",code:"0x03", periodIndex:74,//addr:"0x01",
                indexAPP:150, indexCMD:0, copySize:1,isLast:false,//period:"900s",payIndex:3,ackAddrIndex:0,
                listVal:[
                    { start: "2048", end: "2049",covType:"FloatBE",covAppIndex:110},  //
                    { start: "2052", end: "2053" ,covType:"FloatBE",covAppIndex:114}
                ]
            }
        ]
    }
]
let otaConfig = getOtaConfig({
    SwVersion:31,
    BaudRate: 9600,
    StopBits: 1,
    DataBits: 8,
    Checkbit: CheckbitEnum.NONE,
    Battery: true,
    ConfirmDuty: 60,
    BzType: 22106,
    BzVersion: 11
})
const MODBUS_TT = (ebModel: EBModel) => {
    for (let i=0; i<eventInfo.length; i++){
        let event=new EventInfoItem(eventInfo[i]);
        event.upEventSetup()
        event.eventInstall()
    }
    return JSON.stringify(ebModel, null, 2)
}
buildOtaFile(import.meta.url, otaConfig, MODBUS_TT)

6.3 Description

Current EB logic description:

  • EdgeBus reports business data through Port 22.
  • It first reads register 102 to obtain the number of sensing points per revolution.
  • Then it reads registers 2048–2049 and 2052–2053 to obtain the processed speed value and raw speed value respectively.
  • Upload period and collection period are separated:
    • 70 = upload period
    • 74 = collection period
  • The Modbus address is managed through APP parameter 150.
  • Floating-point registers use FloatBE / IEEE754 high word first format.

7. Thing Model

7.1 Basic Information of the Thing Model

Telemetry Thing Model

  • Name: [CZ580]
  • id Name: cz580_22106

Parameter Thing Model

  • Name: [CZ580-PARA]
  • id Name: cz580_para_22106

The uplink data frame structure is as follows:

javascript
let frameInfo={
    port:22, dataLen:16,rssi:true,battery:4,
    tagList:[{ index:0, tag:0x86 }, { index:1, tag:0x06 }]
}

Field definitions are as follows:

  • index 6: ratio, uint16BE
  • index 8: INI1Speed1, floatBE
  • index 12: INI1RawSpeed1, floatBE

7.3 Thing Model Scripts

7.3.1 Telemetry Thing Model Script

javascript
let port=msg?.userdata?.port || null;
if(port!=22) return null
let frameInfo={
    port:22, dataLen:16,rssi:true,battery:4,
    tagList:[{ index:0, tag:0x86 }, { index:1, tag:0x06 }]
}
let appInfo = [
    { name: "ratio", field_name: "ratio", unit:"", index: 6, type: "uint16BE",decimal:1},
    { name: "INI1Speed1", field_name: "INI1Speed1", unit:"", index: 8, type: "floatBE",decimal:1},
    { name: "INI1RawSpeed1", field_name: "INI1RawSpeed1", unit:"", index: 12, type: "floatBE",decimal:1},
]
let payParser=new PayloadParser({
    device:device,
    msg:msg,
    frameInfo:frameInfo,
    appInfo:appInfo,
})
let tdata= payParser.telemetry()
return {
    telemetry_data: tdata,
    server_attrs: null,
    shared_attrs: null
}

7.3.2 Parameter Thing Model Script

javascript
let port=msg?.userdata?.port || null;
const rpcName="cz580_set_para_22106"
let paraInfo= {
    app_38: { name: "pwron_delay", field_name: "pwron_delay", unit: "ms", index: 38, type: "uint16le" },
    app_70: {name: "period_up", field_name: "period_up", unit: "s",  type: "uint32LE"},
    app_74: {name: "period_read", field_name: "period_read", unit: "s", type: "uint32LE"},
    app_110: {name: "cov_INI1Speed1", field_name: "cov_INI1Speed1", unit: "", type: "floatBE",decimal:1},
    app_150: {name: "addr_modbus", field_name: "addr_modbus", unit: "", type: "uint8"}
}
if (port!==214) {
    let checkData=Utils.paraCheck(rpcName,device.server_attrs,device.shared_attrs)
    return {
        server_attrs: checkData.sdata,
        action:checkData.action,
    }
}
let pdata=(new PayloadParser({
    device:device,
    msg:msg,
    paraInfo:paraDef,
})).paras()
let checkData= Utils.paraCheck(rpcName,pdata)
return {
    telemetry_data: pdata,
    server_attrs: checkData.sdata,
    shared_attrs: pdata,
    action: checkData.action,
}

8. Third-Party Platform Data Subscription

8.1 MQTT Topic

/v32/{Organization Account}/tkl/up/telemetry/{eui}

8.2 Example Reported Data

According to the fields defined in this template’s thing model, the sample formatted data is as follows:

json
{
    "eui": "6353012af10a9331",
    "active_time": "2026-02-05T08:35:48.000Z",
    "thingModelId": "22106",
    "thingModelIdName": "cz580_22106",
    "telemetry_data": {
        "snr": 13.5,
        "rssi": -51,
        "battery": 3.37,
        "ratio": 1,
        "INI1Speed1": 3000.0,
        "INI1RawSpeed1": 3000.0
    }
}

Description:

  • thingModelId should actually follow the platform-generated value; here, business code 22106 is used only as an example.
  • thingModelIdName corresponds to the telemetry thing model cz580_22106.
  • ratio corresponds to the parameter related to sensing points per revolution collected by the device.
  • INI1Speed1 is the processed speed value.
  • INI1RawSpeed1 is the raw, unprocessed speed value.

9. RPC

9.1 RPC Names

Parameter Configuration RPC

  • Name: [CZ580 SET] para
  • id Name: cz580_set_para_22106

Parameter Read RPC

  • Name: [CZ580 GET] para
  • id Name: cz580_get_22106

9.2 Parameter Definitions

Parameter AddressNamefield_nameUnitTypeDescription
app_38pwron_delaypwron_delaymsuint16lePower-on delay
app_70period_upperiod_upsuint32LEUpload period
app_74period_readperiod_readsuint32LECollection period
app_110cov_INI1Speed1cov_INI1Speed1floatBESpeed change threshold
app_150addr_modbusaddr_modbusuint8Modbus address

9.3 RPC Code

Parameter Configuration RPC

javascript
let classMode = (device && device.shared_attrs && device.shared_attrs.class_mode) || "ClassA";
let intervalms = classMode === "ClassA" ? 0 : 2000;
const rpcName="cz580_22106_set"
let paraDef= {
    app_38: { name: "pwron_delay", field_name: "pwron_delay", unit: "ms", index: 38, type: "uint16le" },
    app_70: {name: "period_up", field_name: "period_up", unit: "s",  type: "uint32LE"},
    app_74: {name: "period_read", field_name: "period_read", unit: "s", type: "uint32LE"},
    app_110: {name: "cov_INI1Speed1", field_name: "cov_INI1Speed1", unit: "", type: "floatBE",decimal:1},
    app_150: {name: "addr_modbus", field_name: "addr_modbus", unit: "", type: "uint8"}
}
let frames=RPCHelper.buildFrame({
    paraDef:paraDef,
    params:params});
let redoBuffer=RPCHelper.redo()
let dnBuffer=Buffer.alloc(frames.writeBuffer.length+frames.readBuffer.length);
frames.writeBuffer.copy(dnBuffer,0)
frames.readBuffer.copy(dnBuffer,frames.writeBuffer.length)
logger.info("set para")
let msgQue=Utils.makeParaSetMSG({
    device:device,
    classMode:classMode,
    rpcName:rpcName,
    params:params,
    paraDownBuffer:dnBuffer,
    extraAppBuffer:redoBuffer
})
if (msgQue.length==0)  return null
return msgQue

Parameter Read RPC

javascript
let classMode = (device && device.shared_attrs && device.shared_attrs.class_mode) || "ClassA";
let sleepMs = classMode === "ClassA" ? 500 : 5000;
let paraDef= {
    app_38: { name: "pwron_delay", field_name: "pwron_delay", unit: "ms", index: 38, type: "uint16le" },
    app_70: {name: "periodUP", field_name: "periodUP", unit: "s",  type: "uint32LE"},
    app_74: {name: "periodRead", field_name: "periodRead", unit: "s", type: "uint32LE"},
    app_110: {name: "cov_INI1Speed1", field_name: "cov_INI1Speed1", unit: "℃", type: "floatBE",decimal:1},
    app_150: {name: "addr", field_name: "addr", unit: "", type: "uint8"},
}
let frames=RPCHelper.buildFrame({
    paraDef:paraDef,
    params:params});
let msg=RPCHelper.makeMSG({
    msgType:Utils.msgType.paras,
    device:device,
    dnBuffer:frames.readBuffer,
    sleepTime:sleepMs,
})
return [msg]

10. Template Selection

In the ThinkLink platform, search for the template:

  • CZ580

Or search by business type:

  • 22106 / Speed Transmitter / RS485 Modbus Speed Acquisition

Supplementary Notes

  1. The manufacturer’s default Modbus parameters are:

These parameters can be modified through the host computer tool.

- Address: **1**
- Baud rate: **9600**
- Data bits: **8**
- Parity: **None**
  1. If RS485 communication parameters need to be modified, register 7166 must first be written with 0xCCAA to enable modification, and then parameters such as address, baud rate, and data format can be written.
  2. The manufacturer’s documentation provides the following Modbus frame examples:
    • Read speed: 01 03 00 00 00 01 84 0A
    • Write sensing points per revolution: 01 10 00 66 00 01 02 00 0C AF 93