{"version":3,"file":"FuncCard_ReadPowerOperTime_1.mjs","names":[],"sources":["../../generated/api/FuncCard_ReadPowerOperTime_1.ts"],"sourcesContent":["import { Packet, Request, Session } from '@novastar/codec';\nimport AddressMapping from '../AddressMapping';\n\ndeclare module '@novastar/codec' {\n  interface API {\n    FuncCard_ReadPowerOperTime_1(\n      addr: number,\n      portAddr: number,\n      funcCardAddr: number\n    ): Promise<Buffer>;\n    tryFuncCard_ReadPowerOperTime_1(\n      addr: number,\n      portAddr: number,\n      funcCardAddr: number\n    ): Promise<Packet | null>;\n  }\n}\nexport default function createFuncCard_ReadPowerOperTime_1(\n  addr: number,\n  portAddr: number,\n  funcCardAddr: number\n): Request {\n  const req = new Request(\n    AddressMapping.FuncCard_OperPowerOccupancy,\n    'FuncCard_ReadPowerOperTime_1'\n  );\n  req.destination = addr;\n  req.deviceType = 2;\n  req.port = portAddr;\n  req.rcvIndex = funcCardAddr;\n  req.address = AddressMapping.FuncCard_PowerOperTimeAddr;\n  return req;\n}\nSession.prototype.FuncCard_ReadPowerOperTime_1 = async function FuncCard_ReadPowerOperTime_1(\n  this: Session,\n  addr: number,\n  portAddr: number,\n  funcCardAddr: number\n): Promise<Buffer> {\n  const req = createFuncCard_ReadPowerOperTime_1(addr, portAddr, funcCardAddr);\n  return (await this.connection.send(req)).data;\n};\nSession.prototype.tryFuncCard_ReadPowerOperTime_1 = async function tryFuncCard_ReadPowerOperTime_1(\n  this: Session,\n  addr: number,\n  portAddr: number,\n  funcCardAddr: number\n): Promise<Packet | null> {\n  const req = createFuncCard_ReadPowerOperTime_1(addr, portAddr, funcCardAddr);\n  return this.connection.trySend(req);\n};\n"],"mappings":";;;;AAiBA,SAAwB,mCACtB,MACA,UACA,cACS;CACT,MAAM,MAAM,IAAI,YAEd,8BACF;CACA,IAAI,cAAc;CAClB,IAAI,aAAa;CACjB,IAAI,OAAO;CACX,IAAI,WAAW;CACf,IAAI;CACJ,OAAO;AACT;AACA,QAAQ,UAAU,+BAA+B,eAAe,6BAE9D,MACA,UACA,cACiB;CACjB,MAAM,MAAM,mCAAmC,MAAM,UAAU,YAAY;CAC3E,QAAQ,MAAM,KAAK,WAAW,KAAK,GAAG,GAAG;AAC3C;AACA,QAAQ,UAAU,kCAAkC,eAAe,gCAEjE,MACA,UACA,cACwB;CACxB,MAAM,MAAM,mCAAmC,MAAM,UAAU,YAAY;CAC3E,OAAO,KAAK,WAAW,QAAQ,GAAG;AACpC"}