skyeye-sdk-js 1.4.7 → 1.4.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. package/dist/src/RequestFactory.d.ts +1 -1
  2. package/dist/src/RequestFactory.js +2 -1
  3. package/dist/src/SkyEyeClient.d.ts +2 -2
  4. package/dist/src/SkyEyeClient.js +4 -4
  5. package/dist/src/proto/protoc.sh +32 -32
  6. package/dist/src/proto/skyeye_rpc_grpc_pb.js +88 -88
  7. package/dist/src/proto/skyeye_rpc_pb.js +328 -328
  8. package/package.json +1 -1
  9. package/src/RequestFactory.ts +3 -2
  10. package/src/SkyEyeClient.ts +4 -4
  11. package/src/exception/SkyEyeSDKException.js +31 -31
  12. package/src/models/Board.js +18 -18
  13. package/src/models/Cpu.js +66 -66
  14. package/src/models/CpuInterface.js +2 -2
  15. package/src/models/Device.js +27 -27
  16. package/src/models/DeviceInterface.js +2 -2
  17. package/src/models/DeviceState.js +8 -8
  18. package/src/models/FaultInjectItem.js +17 -17
  19. package/src/models/FaultInjectItemInterface.js +2 -2
  20. package/src/models/FaultInjectType.js +25 -25
  21. package/src/models/GlobalVarType.js +9 -9
  22. package/src/models/InstructionItem.js +9 -9
  23. package/src/models/Node.js +2 -2
  24. package/src/models/Register.js +33 -33
  25. package/src/models/RegisterInterface.js +2 -2
  26. package/src/proto/protoc.sh +32 -32
  27. package/src/proto/skyeye_rpc_grpc_pb.js +88 -88
  28. package/src/proto/skyeye_rpc_pb.js +328 -328
  29. package/src/proto bc_240328/protoc.sh +32 -32
  30. package/src/proto bc_240328/skyeye_rpc_grpc_pb.js +77 -77
  31. package/src/proto bc_240328/skyeye_rpc_pb.js +328 -328
  32. package/src/requests/BaseRequest.js +19 -19
  33. package/src/requests/GetRunningStatusRequest.js +10 -10
  34. package/src/response/BaseResponse.js +27 -27
  35. package/src/response/GetAllDeviceInfoResponse.js +29 -29
  36. package/src/response/GetCpuListResponse.js +36 -36
  37. package/src/response/GetCpuRegisterInfoResponse.js +29 -29
  38. package/src/response/GetCurrentPCResponse.js +7 -7
  39. package/src/response/GetDeviceListResponse.js +29 -29
  40. package/src/response/GetDeviceTreeResponse.js +29 -29
  41. package/src/response/GetDisassembleInfoResponse.js +27 -27
  42. package/src/response/GetFaultInjectListResponse.js +40 -40
  43. package/src/response/GetRamAddrInfoResponse.js +27 -27
  44. package/src/response/GetRunningStateResponse.js +43 -43
  45. package/src/utils/ParseBoardUtils.js +111 -111
  46. package/dist/GrpcUtil.d.ts +0 -9
  47. package/dist/GrpcUtil.js +0 -55
  48. package/dist/JsonRequest.d.ts +0 -10
  49. package/dist/JsonRequest.js +0 -29
  50. package/dist/JsonResponse.d.ts +0 -12
  51. package/dist/JsonResponse.js +0 -36
  52. package/dist/RequestFactory.d.ts +0 -35
  53. package/dist/RequestFactory.js +0 -257
  54. package/dist/exception/SkyEyeSDKException.d.ts +0 -3
  55. package/dist/exception/SkyEyeSDKException.js +0 -13
  56. package/dist/models/Board.d.ts +0 -9
  57. package/dist/models/Board.js +0 -15
  58. package/dist/models/Cpu.d.ts +0 -14
  59. package/dist/models/Cpu.js +0 -47
  60. package/dist/models/CpuInterface.d.ts +0 -13
  61. package/dist/models/CpuInterface.js +0 -2
  62. package/dist/models/Device.d.ts +0 -38
  63. package/dist/models/Device.js +0 -26
  64. package/dist/models/DeviceInterface.d.ts +0 -12
  65. package/dist/models/DeviceInterface.js +0 -2
  66. package/dist/models/DeviceState.d.ts +0 -4
  67. package/dist/models/DeviceState.js +0 -8
  68. package/dist/models/FaultInjectItem.d.ts +0 -11
  69. package/dist/models/FaultInjectItem.js +0 -16
  70. package/dist/models/FaultInjectItemInterface.d.ts +0 -9
  71. package/dist/models/FaultInjectItemInterface.js +0 -2
  72. package/dist/models/FaultInjectType.d.ts +0 -11
  73. package/dist/models/FaultInjectType.js +0 -25
  74. package/dist/models/GlobalVarType.d.ts +0 -5
  75. package/dist/models/GlobalVarType.js +0 -9
  76. package/dist/models/InstructionItem.d.ts +0 -5
  77. package/dist/models/InstructionItem.js +0 -6
  78. package/dist/models/Node.d.ts +0 -4
  79. package/dist/models/Node.js +0 -2
  80. package/dist/models/Register.d.ts +0 -38
  81. package/dist/models/Register.js +0 -32
  82. package/dist/models/RegisterInterface.d.ts +0 -10
  83. package/dist/models/RegisterInterface.js +0 -2
  84. package/dist/src/proto copy/skyeye_rpc.proto +0 -11
  85. package/dist/src/proto copy/skyeye_rpc_grpc_pb.d.ts +0 -40
  86. package/dist/src/proto copy/skyeye_rpc_grpc_pb.js +0 -44
  87. package/dist/src/proto copy/skyeye_rpc_pb.d.ts +0 -47
  88. package/dist/src/proto copy/skyeye_rpc_pb.js +0 -322
  89. package/dist/utils/ParseBoardUtils.d.ts +0 -6
  90. package/dist/utils/ParseBoardUtils.js +0 -108
@@ -531,19 +531,19 @@ export class SkyEyeClient extends JSONTransmissionClient {
531
531
  }
532
532
  }
533
533
 
534
- public async setMemoryValue(cpuName: string, baseAddr: string, value: string, length: string) {
534
+ public async setMemoryValue(cpuName: string, baseAddr: string, value: string, length: string, addressWidth?: number) {
535
535
  try {
536
- return await this.call(RequestFactory.getInstance().setMemoryValue(cpuName, baseAddr, value, length));
536
+ return await this.call(RequestFactory.getInstance().setMemoryValue(cpuName, baseAddr, value, length, addressWidth));
537
537
  } catch (error) {
538
538
  console.error("Error during getAddressingSpaceDefault:", error);
539
539
  throw error;
540
540
  }
541
541
  }
542
- public async setMemoryValueDefault(baseAddr: string, value: string, length: string) {
542
+ public async setMemoryValueDefault(baseAddr: string, value: string, length: string, addressWidth?: number) {
543
543
  const cpuList = (await this.getCpuList()).getCpuList();
544
544
  if (cpuList != null && cpuList.length > 0) {
545
545
  try {
546
- return await this.setMemoryValue(cpuList[0].getName(), baseAddr, value, length)
546
+ return await this.setMemoryValue(cpuList[0].getName(), baseAddr, value, length, addressWidth)
547
547
  } catch (error) {
548
548
  console.error("Error during getAddressingSpaceDefault:", error);
549
549
  throw error;
@@ -1,31 +1,31 @@
1
- "use strict";
2
- var __extends = (this && this.__extends) || (function () {
3
- var extendStatics = function (d, b) {
4
- extendStatics = Object.setPrototypeOf ||
5
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
- return extendStatics(d, b);
8
- };
9
- return function (d, b) {
10
- if (typeof b !== "function" && b !== null)
11
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
- extendStatics(d, b);
13
- function __() { this.constructor = d; }
14
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
- };
16
- })();
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- exports.SkyEyeSDKException = void 0;
19
- // 定义 SkyEyeSDKException 类
20
- var SkyEyeSDKException = /** @class */ (function (_super) {
21
- __extends(SkyEyeSDKException, _super);
22
- function SkyEyeSDKException(message) {
23
- // 调用父类的构造函数
24
- var _this = _super.call(this, message) || this;
25
- // 设置类名
26
- _this.name = 'SkyEyeSDKException';
27
- return _this;
28
- }
29
- return SkyEyeSDKException;
30
- }(Error));
31
- exports.SkyEyeSDKException = SkyEyeSDKException;
1
+ "use strict";
2
+ var __extends = (this && this.__extends) || (function () {
3
+ var extendStatics = function (d, b) {
4
+ extendStatics = Object.setPrototypeOf ||
5
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
+ return extendStatics(d, b);
8
+ };
9
+ return function (d, b) {
10
+ if (typeof b !== "function" && b !== null)
11
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
+ extendStatics(d, b);
13
+ function __() { this.constructor = d; }
14
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
+ };
16
+ })();
17
+ Object.defineProperty(exports, "__esModule", { value: true });
18
+ exports.SkyEyeSDKException = void 0;
19
+ // 定义 SkyEyeSDKException 类
20
+ var SkyEyeSDKException = /** @class */ (function (_super) {
21
+ __extends(SkyEyeSDKException, _super);
22
+ function SkyEyeSDKException(message) {
23
+ // 调用父类的构造函数
24
+ var _this = _super.call(this, message) || this;
25
+ // 设置类名
26
+ _this.name = 'SkyEyeSDKException';
27
+ return _this;
28
+ }
29
+ return SkyEyeSDKException;
30
+ }(Error));
31
+ exports.SkyEyeSDKException = SkyEyeSDKException;
@@ -1,18 +1,18 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Board = void 0;
4
- var Board = /** @class */ (function () {
5
- function Board() {
6
- }
7
- Board.prototype.getName = function () {
8
- return this.name;
9
- };
10
- Board.prototype.getParent = function () {
11
- return null;
12
- };
13
- Board.prototype.toString = function () {
14
- return "Board{name='".concat(this.name, "', deviceMap=").concat(this.deviceMap, "}");
15
- };
16
- return Board;
17
- }());
18
- exports.Board = Board;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Board = void 0;
4
+ var Board = /** @class */ (function () {
5
+ function Board() {
6
+ }
7
+ Board.prototype.getName = function () {
8
+ return this.name;
9
+ };
10
+ Board.prototype.getParent = function () {
11
+ return null;
12
+ };
13
+ Board.prototype.toString = function () {
14
+ return "Board{name='".concat(this.name, "', deviceMap=").concat(this.deviceMap, "}");
15
+ };
16
+ return Board;
17
+ }());
18
+ exports.Board = Board;
package/src/models/Cpu.js CHANGED
@@ -1,66 +1,66 @@
1
- "use strict";
2
- var __extends = (this && this.__extends) || (function () {
3
- var extendStatics = function (d, b) {
4
- extendStatics = Object.setPrototypeOf ||
5
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
- return extendStatics(d, b);
8
- };
9
- return function (d, b) {
10
- if (typeof b !== "function" && b !== null)
11
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
- extendStatics(d, b);
13
- function __() { this.constructor = d; }
14
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
- };
16
- })();
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- exports.Cpu = void 0;
19
- var Device_1 = require("./Device");
20
- var Cpu = /** @class */ (function (_super) {
21
- __extends(Cpu, _super);
22
- function Cpu(info) {
23
- var _this = this;
24
- if (info) {
25
- _this = _super.call(this, info) || this;
26
- _this.className = info.className;
27
- }
28
- else {
29
- _this = _super.call(this, null) || this;
30
- }
31
- return _this;
32
- }
33
- /**
34
- * CPU类型
35
- */
36
- // private className: string;
37
- Cpu.prototype.getClassName = function () {
38
- return this.className;
39
- };
40
- Cpu.prototype.setClassName = function (className) {
41
- this.className = className;
42
- };
43
- Cpu.prototype.setName = function (name) {
44
- this.name = name;
45
- };
46
- Cpu.prototype.setParent = function (parent) {
47
- this.parent = parent;
48
- };
49
- // constructor(
50
- // className: string,
51
- // name: string,
52
- // parent: Node | null,
53
- // registerMap: Map<string, Register>,
54
- // baseAddr: number | null,
55
- // length: number | null,
56
- // state: DeviceState
57
- // ) {
58
- // super(name, parent, registerMap, baseAddr, length, 'Cpu', state);
59
- // this.className = className;
60
- // }
61
- Cpu.prototype.toString = function () {
62
- return "Cpu{className='".concat(this.className, "', name='").concat(this.name, "', parent=").concat(this.parent != null ? this.parent.getName() : null, ", registerMap=").concat(this.registerMap, ", state=").concat(this.state, "}");
63
- };
64
- return Cpu;
65
- }(Device_1.Device));
66
- exports.Cpu = Cpu;
1
+ "use strict";
2
+ var __extends = (this && this.__extends) || (function () {
3
+ var extendStatics = function (d, b) {
4
+ extendStatics = Object.setPrototypeOf ||
5
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
+ return extendStatics(d, b);
8
+ };
9
+ return function (d, b) {
10
+ if (typeof b !== "function" && b !== null)
11
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
+ extendStatics(d, b);
13
+ function __() { this.constructor = d; }
14
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
+ };
16
+ })();
17
+ Object.defineProperty(exports, "__esModule", { value: true });
18
+ exports.Cpu = void 0;
19
+ var Device_1 = require("./Device");
20
+ var Cpu = /** @class */ (function (_super) {
21
+ __extends(Cpu, _super);
22
+ function Cpu(info) {
23
+ var _this = this;
24
+ if (info) {
25
+ _this = _super.call(this, info) || this;
26
+ _this.className = info.className;
27
+ }
28
+ else {
29
+ _this = _super.call(this, null) || this;
30
+ }
31
+ return _this;
32
+ }
33
+ /**
34
+ * CPU类型
35
+ */
36
+ // private className: string;
37
+ Cpu.prototype.getClassName = function () {
38
+ return this.className;
39
+ };
40
+ Cpu.prototype.setClassName = function (className) {
41
+ this.className = className;
42
+ };
43
+ Cpu.prototype.setName = function (name) {
44
+ this.name = name;
45
+ };
46
+ Cpu.prototype.setParent = function (parent) {
47
+ this.parent = parent;
48
+ };
49
+ // constructor(
50
+ // className: string,
51
+ // name: string,
52
+ // parent: Node | null,
53
+ // registerMap: Map<string, Register>,
54
+ // baseAddr: number | null,
55
+ // length: number | null,
56
+ // state: DeviceState
57
+ // ) {
58
+ // super(name, parent, registerMap, baseAddr, length, 'Cpu', state);
59
+ // this.className = className;
60
+ // }
61
+ Cpu.prototype.toString = function () {
62
+ return "Cpu{className='".concat(this.className, "', name='").concat(this.name, "', parent=").concat(this.parent != null ? this.parent.getName() : null, ", registerMap=").concat(this.registerMap, ", state=").concat(this.state, "}");
63
+ };
64
+ return Cpu;
65
+ }(Device_1.Device));
66
+ exports.Cpu = Cpu;
@@ -1,2 +1,2 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,27 +1,27 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Device = void 0;
4
- var Device = /** @class */ (function () {
5
- function Device(info) {
6
- if (info) {
7
- this.name = info.name;
8
- this.parent = info.parent;
9
- this.registerMap = info.registerMap;
10
- this.baseAddr = info.baseAddr;
11
- this.length = info.length;
12
- this.className = info.className;
13
- this.state = info.state;
14
- }
15
- }
16
- Device.prototype.getName = function () {
17
- return this.name;
18
- };
19
- Device.prototype.getParent = function () {
20
- return this.parent;
21
- };
22
- Device.prototype.toString = function () {
23
- return "Device{name='".concat(this.name, "', parent=").concat(this.parent != null ? this.parent.getName() : null, ", registerMap=").concat(this.registerMap, ", baseAddr=").concat(this.baseAddr, ", length=").concat(this.length, ", className='").concat(this.className, "', state=").concat(this.state, "}");
24
- };
25
- return Device;
26
- }());
27
- exports.Device = Device;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Device = void 0;
4
+ var Device = /** @class */ (function () {
5
+ function Device(info) {
6
+ if (info) {
7
+ this.name = info.name;
8
+ this.parent = info.parent;
9
+ this.registerMap = info.registerMap;
10
+ this.baseAddr = info.baseAddr;
11
+ this.length = info.length;
12
+ this.className = info.className;
13
+ this.state = info.state;
14
+ }
15
+ }
16
+ Device.prototype.getName = function () {
17
+ return this.name;
18
+ };
19
+ Device.prototype.getParent = function () {
20
+ return this.parent;
21
+ };
22
+ Device.prototype.toString = function () {
23
+ return "Device{name='".concat(this.name, "', parent=").concat(this.parent != null ? this.parent.getName() : null, ", registerMap=").concat(this.registerMap, ", baseAddr=").concat(this.baseAddr, ", length=").concat(this.length, ", className='").concat(this.className, "', state=").concat(this.state, "}");
24
+ };
25
+ return Device;
26
+ }());
27
+ exports.Device = Device;
@@ -1,2 +1,2 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,8 +1,8 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.DeviceState = void 0;
4
- var DeviceState;
5
- (function (DeviceState) {
6
- DeviceState[DeviceState["ENABLE"] = 1] = "ENABLE";
7
- DeviceState[DeviceState["DISABLE"] = 0] = "DISABLE";
8
- })(DeviceState || (exports.DeviceState = DeviceState = {}));
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DeviceState = void 0;
4
+ var DeviceState;
5
+ (function (DeviceState) {
6
+ DeviceState[DeviceState["ENABLE"] = 1] = "ENABLE";
7
+ DeviceState[DeviceState["DISABLE"] = 0] = "DISABLE";
8
+ })(DeviceState || (exports.DeviceState = DeviceState = {}));
@@ -1,17 +1,17 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.FaultInjectItem = void 0;
4
- var FaultInjectItem = /** @class */ (function () {
5
- function FaultInjectItem(info) {
6
- if (info) {
7
- this.boardName = info.boardName;
8
- this.deviceName = info.deviceName;
9
- this.registerName = info.registerName;
10
- this.addr = info.addr;
11
- this.bit = info.bit;
12
- this.type = info.type;
13
- }
14
- }
15
- return FaultInjectItem;
16
- }());
17
- exports.FaultInjectItem = FaultInjectItem;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.FaultInjectItem = void 0;
4
+ var FaultInjectItem = /** @class */ (function () {
5
+ function FaultInjectItem(info) {
6
+ if (info) {
7
+ this.boardName = info.boardName;
8
+ this.deviceName = info.deviceName;
9
+ this.registerName = info.registerName;
10
+ this.addr = info.addr;
11
+ this.bit = info.bit;
12
+ this.type = info.type;
13
+ }
14
+ }
15
+ return FaultInjectItem;
16
+ }());
17
+ exports.FaultInjectItem = FaultInjectItem;
@@ -1,2 +1,2 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,25 +1,25 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getFaultInjectTypeByValue = exports.FaultInjectTypeDescription = exports.FaultInjectType = void 0;
4
- var FaultInjectType;
5
- (function (FaultInjectType) {
6
- FaultInjectType["SET_ZERO"] = "0";
7
- FaultInjectType["SET_ONE"] = "1";
8
- FaultInjectType["SET_REVE"] = "2";
9
- })(FaultInjectType || (exports.FaultInjectType = FaultInjectType = {}));
10
- // 可选的描述信息
11
- exports.FaultInjectTypeDescription = {
12
- "0": "置零",
13
- "1": "置一",
14
- "2": "取反"
15
- };
16
- // 通过值获取故障注入类型
17
- function getFaultInjectTypeByValue(value) {
18
- for (var key in FaultInjectType) {
19
- if (FaultInjectType[key] === value) {
20
- return key;
21
- }
22
- }
23
- return null;
24
- }
25
- exports.getFaultInjectTypeByValue = getFaultInjectTypeByValue;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getFaultInjectTypeByValue = exports.FaultInjectTypeDescription = exports.FaultInjectType = void 0;
4
+ var FaultInjectType;
5
+ (function (FaultInjectType) {
6
+ FaultInjectType["SET_ZERO"] = "0";
7
+ FaultInjectType["SET_ONE"] = "1";
8
+ FaultInjectType["SET_REVE"] = "2";
9
+ })(FaultInjectType || (exports.FaultInjectType = FaultInjectType = {}));
10
+ // 可选的描述信息
11
+ exports.FaultInjectTypeDescription = {
12
+ "0": "置零",
13
+ "1": "置一",
14
+ "2": "取反"
15
+ };
16
+ // 通过值获取故障注入类型
17
+ function getFaultInjectTypeByValue(value) {
18
+ for (var key in FaultInjectType) {
19
+ if (FaultInjectType[key] === value) {
20
+ return key;
21
+ }
22
+ }
23
+ return null;
24
+ }
25
+ exports.getFaultInjectTypeByValue = getFaultInjectTypeByValue;
@@ -1,9 +1,9 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.GlobalVarType = void 0;
4
- var GlobalVarType;
5
- (function (GlobalVarType) {
6
- GlobalVarType["INT"] = "int";
7
- GlobalVarType["DOUBLE"] = "double";
8
- GlobalVarType["FLOAT"] = "float";
9
- })(GlobalVarType || (exports.GlobalVarType = GlobalVarType = {}));
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GlobalVarType = void 0;
4
+ var GlobalVarType;
5
+ (function (GlobalVarType) {
6
+ GlobalVarType["INT"] = "int";
7
+ GlobalVarType["DOUBLE"] = "double";
8
+ GlobalVarType["FLOAT"] = "float";
9
+ })(GlobalVarType || (exports.GlobalVarType = GlobalVarType = {}));
@@ -1,9 +1,9 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.InstructionItem = void 0;
4
- var InstructionItem = /** @class */ (function () {
5
- function InstructionItem() {
6
- }
7
- return InstructionItem;
8
- }());
9
- exports.InstructionItem = InstructionItem;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.InstructionItem = void 0;
4
+ var InstructionItem = /** @class */ (function () {
5
+ function InstructionItem() {
6
+ }
7
+ return InstructionItem;
8
+ }());
9
+ exports.InstructionItem = InstructionItem;
@@ -1,2 +1,2 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,33 +1,33 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Register = void 0;
4
- var Register = /** @class */ (function () {
5
- function Register(info) {
6
- if (info) {
7
- this.name = info.name;
8
- this.parent = info.parent;
9
- this.baseAddr = info.baseAddr;
10
- this.bits = info.bits;
11
- this.value = info.value;
12
- this.offset = info.offset;
13
- this.description = info.description;
14
- }
15
- }
16
- Register.prototype.getName = function () {
17
- return this.name;
18
- };
19
- Register.prototype.setName = function (name) {
20
- this.name = name;
21
- };
22
- Register.prototype.getParent = function () {
23
- return this.parent;
24
- };
25
- Register.prototype.setParent = function (node) {
26
- this.parent = node;
27
- };
28
- Register.prototype.toString = function () {
29
- return "Register{name='".concat(this.name, "', parent=").concat(this.parent != null ? this.parent.getName() : null, ", baseAddr=").concat(this.baseAddr, ", offset=").concat(this.offset, ", bits=").concat(this.bits, ", value=").concat(this.value, ", description='").concat(this.description, "'}");
30
- };
31
- return Register;
32
- }());
33
- exports.Register = Register;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Register = void 0;
4
+ var Register = /** @class */ (function () {
5
+ function Register(info) {
6
+ if (info) {
7
+ this.name = info.name;
8
+ this.parent = info.parent;
9
+ this.baseAddr = info.baseAddr;
10
+ this.bits = info.bits;
11
+ this.value = info.value;
12
+ this.offset = info.offset;
13
+ this.description = info.description;
14
+ }
15
+ }
16
+ Register.prototype.getName = function () {
17
+ return this.name;
18
+ };
19
+ Register.prototype.setName = function (name) {
20
+ this.name = name;
21
+ };
22
+ Register.prototype.getParent = function () {
23
+ return this.parent;
24
+ };
25
+ Register.prototype.setParent = function (node) {
26
+ this.parent = node;
27
+ };
28
+ Register.prototype.toString = function () {
29
+ return "Register{name='".concat(this.name, "', parent=").concat(this.parent != null ? this.parent.getName() : null, ", baseAddr=").concat(this.baseAddr, ", offset=").concat(this.offset, ", bits=").concat(this.bits, ", value=").concat(this.value, ", description='").concat(this.description, "'}");
30
+ };
31
+ return Register;
32
+ }());
33
+ exports.Register = Register;
@@ -1,2 +1,2 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,32 +1,32 @@
1
- #!/usr/bin/env bash
2
-
3
- BASEDIR=$(dirname "$0")
4
- cd "${BASEDIR}"/../
5
-
6
- PROTOC_GEN_TS_PATH="./node_modules/.bin/protoc-gen-ts"
7
- GRPC_TOOLS_NODE_PROTOC_PLUGIN="./node_modules/.bin/grpc_tools_node_protoc_plugin"
8
- GRPC_TOOLS_NODE_PROTOC="./node_modules/.bin/grpc_tools_node_protoc"
9
-
10
- for f in ./src/proto/*; do
11
-
12
- # skip the non proto files
13
- if [ "$(basename "$f")" == "index.ts" ]; then
14
- continue
15
- fi
16
-
17
- # loop over all the available proto files and compile them into respective dir
18
- # JavaScript code generating
19
- ${GRPC_TOOLS_NODE_PROTOC} \
20
- --js_out=import_style=commonjs,binary:"${f}" \
21
- --grpc_out="${f}" \
22
- --plugin=protoc-gen-grpc="${GRPC_TOOLS_NODE_PROTOC_PLUGIN}" \
23
- -I "${f}" \
24
- "${f}"/*.proto
25
-
26
- ${GRPC_TOOLS_NODE_PROTOC} \
27
- --plugin=protoc-gen-ts="${PROTOC_GEN_TS_PATH}" \
28
- --ts_out="${f}" \
29
- -I "${f}" \
30
- "${f}"/*.proto
31
-
32
- done
1
+ #!/usr/bin/env bash
2
+
3
+ BASEDIR=$(dirname "$0")
4
+ cd "${BASEDIR}"/../
5
+
6
+ PROTOC_GEN_TS_PATH="./node_modules/.bin/protoc-gen-ts"
7
+ GRPC_TOOLS_NODE_PROTOC_PLUGIN="./node_modules/.bin/grpc_tools_node_protoc_plugin"
8
+ GRPC_TOOLS_NODE_PROTOC="./node_modules/.bin/grpc_tools_node_protoc"
9
+
10
+ for f in ./src/proto/*; do
11
+
12
+ # skip the non proto files
13
+ if [ "$(basename "$f")" == "index.ts" ]; then
14
+ continue
15
+ fi
16
+
17
+ # loop over all the available proto files and compile them into respective dir
18
+ # JavaScript code generating
19
+ ${GRPC_TOOLS_NODE_PROTOC} \
20
+ --js_out=import_style=commonjs,binary:"${f}" \
21
+ --grpc_out="${f}" \
22
+ --plugin=protoc-gen-grpc="${GRPC_TOOLS_NODE_PROTOC_PLUGIN}" \
23
+ -I "${f}" \
24
+ "${f}"/*.proto
25
+
26
+ ${GRPC_TOOLS_NODE_PROTOC} \
27
+ --plugin=protoc-gen-ts="${PROTOC_GEN_TS_PATH}" \
28
+ --ts_out="${f}" \
29
+ -I "${f}" \
30
+ "${f}"/*.proto
31
+
32
+ done