ba63 1.1.0 → 1.1.1

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.
@@ -1,5 +1,5 @@
1
1
  import HID from "node-hid";
2
- import type { Charset } from "~/constants/charset";
2
+ import type { Charset } from "../constants/charset";
3
3
  type RenderOptions = Partial<{
4
4
  /** If the message reaches the end of the top line, start printing on the bottom line.*/
5
5
  wrap: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"BA63.d.ts","sourceRoot":"","sources":["../../src/classes/BA63.ts"],"names":[],"mappings":"AAAA,OAAO,GAAG,MAAM,UAAU,CAAC;AAC3B,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAKnD,KAAK,aAAa,GAAG,OAAO,CAAC;IAC3B,wFAAwF;IACxF,IAAI,EAAE,OAAO,CAAC;CACf,CAAC,CAAC;AAEH,qBAAa,IAAI;IACf,OAAO,CAAC,MAAM,CAAe;IAE7B,sDAAsD;IACtD,SAAS,CAAC,SAAS,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAU;IAE/C;;OAEG;gBACS,MAAM,EAAE,GAAG,CAAC,QAAQ;WAInB,MAAM,IAAI,OAAO,CAAC,IAAI,CAAC;YAsCtB,GAAG;IAUX,MAAM,CACV,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE,EAC1B,OAAO,CAAC,EAAE,aAAa,GACtB,OAAO,CAAC,IAAI,CAAC;IAgCV,cAAc,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAQ9C,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC;IAO3B,cAAc,IAAI,OAAO,CAAC,IAAI,CAAC;IAM/B,QAAQ,IAAI,OAAO,CAAC,IAAI,CAAC;IAMzB,SAAS,IAAI,OAAO,CAAC,IAAI,CAAC;IAM1B,UAAU,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC;IAK3C,WAAW,I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AAI,CAAC;IAM/B,QAAQ,IAAI,OAAO,CAAC,IAAI,CAAC;IAMzB,SAAS,IAAI,OAAO,CAAC,IAAI,CAAC;IAM1B,UAAU,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC;IAK3C,WAAW,IAAI,OAAO,CAAC,IAAI,CAAC;IAK5B,iBAAiB,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAc7D,eAAe,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAI9C,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAIxC,YAAY,IAAI,OAAO,CAAC,IAAI,CAAC;IAKnC,IAAI,WAAW,IAAI,MAAM,CAExB;IAED,IAAI,GAAG,IAAI,KAAK,GAAG,QAAQ,CAE1B;IAED,IAAI,UAAU,IAAI,MAAM,CAEvB;IAED,IAAI,aAAa,IAAI,MAAM,CAE1B;CACF"}
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export { BA63 } from "~/classes/BA63";
2
- export { charset } from "~/constants/charset";
3
- export type { Charset } from "~/constants/charset";
1
+ export { BA63 } from "./classes/BA63";
2
+ export { charset } from "./constants/charset";
3
+ export type { Charset } from "./constants/charset";
4
4
  //# sourceMappingURL=index.d.ts.map
package/dist/index.js.map CHANGED
@@ -2,7 +2,7 @@
2
2
  "version": 3,
3
3
  "sources": ["../src/classes/BA63.ts", "../src/constants/charset.ts"],
4
4
  "sourcesContent": [
5
- "import HID from \"node-hid\";\nimport type { Charset } from \"~/constants/charset\";\n\nconst vendorId = 2727;\nconst productId = 512;\n\ntype RenderOptions = Partial<{\n /** If the message reaches the end of the top line, start printing on the bottom line.*/\n wrap: boolean;\n}>;\n\nexport class BA63 {\n private device: HID.HIDAsync;\n\n /** Current cursor position in [row, column] format */\n protected cursorPos: [number, number] = [0, 0];\n\n /**\n * **NOTE**: This constructor should only be used if you already have an open HID device to interface with.\n */\n constructor(device: HID.HIDAsync) {\n this.device = device;\n }\n\n static async create(): Promise<BA63> {\n const devices = HID.devices();\n const ba63Devices = devices.filter(\n (device) => device.vendorId === vendorId && device.productId === productId\n );\n\n if (ba63Devices.length === 0) {\n throw new Error(\"BA63 device not found\");\n }\n\n /*\n * When connecting to a BA63, you'll find that there are two different interfaces\n * to connect to. Interface 0 is for updating the BA63's firmware whereas interface 1\n * is for communicating with the display itself.\n */\n const displayInterface = ba63Devices.find((d) => d.interface === 1);\n\n if (!displayInterface) {\n throw new Error(\"BA63 display interface (Interface 1) not found!\");\n }\n\n const device = await HID.HIDAsync.open(displayInterface.path!);\n\n // device.on(\"data\", (data) => {\n // console.log(\"Data received:\", data);\n // });\n\n // device.on(\"error\", (err) => {\n // console.error(\"Error:\", err);\n // });\n\n const ba63 = new BA63(device);\n await ba63.clearDisplay();\n await ba63.setCharset(0); // Set to USA charset\n\n return ba63;\n }\n\n private async run(command: number[]): Promise<void> {\n // Pad to 32 bytes (HID report size)\n const writeCommand = [0x02, 0x00, command.length, ...command];\n while (writeCommand.length < 32) {\n writeCommand.push(0x00);\n }\n\n await this.device.write(writeCommand);\n }\n\n async render(\n message: string | number[],\n options?: RenderOptions\n ): Promise<void> {\n const trimmedMessage = message.slice(0, this.lengthToEnd);\n\n const arr =\n typeof trimmedMessage === \"string\"\n ? Array.from(Buffer.from(trimmedMessage, \"ascii\"))\n : trimmedMessage;\n\n await this.run(arr);\n this.setCursorColumn(this.currentColumn + arr.length);\n\n // If wrapping is enabled, we're on the top line, and there's more message to render, continue rendering on next line\n if (\n options?.wrap &&\n this.row === \"top\" &&\n message.length > trimmedMessage.length\n ) {\n const excessMessage = message.slice(trimmedMessage.length);\n\n await this.setCursorPosition(1, 0);\n\n const excessArr =\n typeof excessMessage === \"string\"\n ? Array.from(Buffer.from(excessMessage, \"ascii\"))\n : excessMessage;\n\n await this.run(excessArr);\n this.setCursorColumn(this.currentColumn + excessArr.length);\n return;\n }\n }\n\n async renderInCenter(message: string): Promise<void> {\n const trimmedMessage = message.slice(0, 20);\n const padding = Math.floor((20 - trimmedMessage.length) / 2);\n this.setCursorPosition(this.cursorPos[0], padding);\n\n await this.render(trimmedMessage);\n }\n\n async testRender(): Promise<void> {\n const testMessage = \"Hello from BA63!\";\n await this.renderInCenter(testMessage);\n await this.setCursorRow(1);\n await this.renderInCenter(\"- Caleb\");\n }\n\n async carriageReturn(): Promise<void> {\n const command = [0x0d];\n await this.run(command);\n this.setCursorColumn(0);\n }\n\n async lineFeed(): Promise<void> {\n const command = [0x0a];\n await this.run(command);\n this.setCursorRow(Math.min(1, this.currentRow + 1));\n }\n\n async backspace(): Promise<void> {\n const command = [0x08];\n await this.run(command);\n this.setCursorColumn(Math.max(0, this.currentColumn - 1));\n }\n\n async setCharset(charset: Charset): Promise<void> {\n const command = [0x1b, 0x52, charset];\n await this.run(command);\n }\n\n async deleteToEOL(): Promise<void> {\n const command = [0x1b, 0x5b, 0x30, 0x4b];\n await this.run(command);\n }\n\n async setCursorPosition(row: number, column: number): Promise<void> {\n this.cursorPos = [row, column];\n\n const asciiRow = (row + 1).toString().charCodeAt(0);\n // asciiColumn can be more than one digit\n const asciiColumn = (column + 1)\n .toString()\n .split(\"\")\n .map((char) => char.charCodeAt(0));\n\n const command = [0x1b, 0x5b, asciiRow, 0x3b, ...asciiColumn, 0x48];\n await this.run(command);\n }\n\n async setCursorColumn(column: number): Promise<void> {\n this.setCursorPosition(this.cursorPos[0], column);\n }\n\n async setCursorRow(row: number): Promise<void> {\n this.setCursorPosition(row, this.cursorPos[1]);\n }\n\n async clearDisplay(): Promise<void> {\n const command = [0x1b, 0x5b, 0x32, 0x4a];\n await this.run(command);\n }\n\n get lengthToEnd(): number {\n return 20 - this.cursorPos[1];\n }\n\n get row(): \"top\" | \"bottom\" {\n return this.cursorPos[0] === 0 ? \"top\" : \"bottom\";\n }\n\n get currentRow(): number {\n return this.cursorPos[0];\n }\n\n get currentColumn(): number {\n return this.cursorPos[1];\n }\n}\n",
5
+ "import HID from \"node-hid\";\nimport type { Charset } from \"../constants/charset\";\n\nconst vendorId = 2727;\nconst productId = 512;\n\ntype RenderOptions = Partial<{\n /** If the message reaches the end of the top line, start printing on the bottom line.*/\n wrap: boolean;\n}>;\n\nexport class BA63 {\n private device: HID.HIDAsync;\n\n /** Current cursor position in [row, column] format */\n protected cursorPos: [number, number] = [0, 0];\n\n /**\n * **NOTE**: This constructor should only be used if you already have an open HID device to interface with.\n */\n constructor(device: HID.HIDAsync) {\n this.device = device;\n }\n\n static async create(): Promise<BA63> {\n const devices = HID.devices();\n const ba63Devices = devices.filter(\n (device) => device.vendorId === vendorId && device.productId === productId\n );\n\n if (ba63Devices.length === 0) {\n throw new Error(\"BA63 device not found\");\n }\n\n /*\n * When connecting to a BA63, you'll find that there are two different interfaces\n * to connect to. Interface 0 is for updating the BA63's firmware whereas interface 1\n * is for communicating with the display itself.\n */\n const displayInterface = ba63Devices.find((d) => d.interface === 1);\n\n if (!displayInterface) {\n throw new Error(\"BA63 display interface (Interface 1) not found!\");\n }\n\n const device = await HID.HIDAsync.open(displayInterface.path!);\n\n // device.on(\"data\", (data) => {\n // console.log(\"Data received:\", data);\n // });\n\n // device.on(\"error\", (err) => {\n // console.error(\"Error:\", err);\n // });\n\n const ba63 = new BA63(device);\n await ba63.clearDisplay();\n await ba63.setCharset(0); // Set to USA charset\n\n return ba63;\n }\n\n private async run(command: number[]): Promise<void> {\n // Pad to 32 bytes (HID report size)\n const writeCommand = [0x02, 0x00, command.length, ...command];\n while (writeCommand.length < 32) {\n writeCommand.push(0x00);\n }\n\n await this.device.write(writeCommand);\n }\n\n async render(\n message: string | number[],\n options?: RenderOptions\n ): Promise<void> {\n const trimmedMessage = message.slice(0, this.lengthToEnd);\n\n const arr =\n typeof trimmedMessage === \"string\"\n ? Array.from(Buffer.from(trimmedMessage, \"ascii\"))\n : trimmedMessage;\n\n await this.run(arr);\n this.setCursorColumn(this.currentColumn + arr.length);\n\n // If wrapping is enabled, we're on the top line, and there's more message to render, continue rendering on next line\n if (\n options?.wrap &&\n this.row === \"top\" &&\n message.length > trimmedMessage.length\n ) {\n const excessMessage = message.slice(trimmedMessage.length);\n\n await this.setCursorPosition(1, 0);\n\n const excessArr =\n typeof excessMessage === \"string\"\n ? Array.from(Buffer.from(excessMessage, \"ascii\"))\n : excessMessage;\n\n await this.run(excessArr);\n this.setCursorColumn(this.currentColumn + excessArr.length);\n return;\n }\n }\n\n async renderInCenter(message: string): Promise<void> {\n const trimmedMessage = message.slice(0, 20);\n const padding = Math.floor((20 - trimmedMessage.length) / 2);\n this.setCursorPosition(this.cursorPos[0], padding);\n\n await this.render(trimmedMessage);\n }\n\n async testRender(): Promise<void> {\n const testMessage = \"Hello from BA63!\";\n await this.renderInCenter(testMessage);\n await this.setCursorRow(1);\n await this.renderInCenter(\"- Caleb\");\n }\n\n async carriageReturn(): Promise<void> {\n const command = [0x0d];\n await this.run(command);\n this.setCursorColumn(0);\n }\n\n async lineFeed(): Promise<void> {\n const command = [0x0a];\n await this.run(command);\n this.setCursorRow(Math.min(1, this.currentRow + 1));\n }\n\n async backspace(): Promise<void> {\n const command = [0x08];\n await this.run(command);\n this.setCursorColumn(Math.max(0, this.currentColumn - 1));\n }\n\n async setCharset(charset: Charset): Promise<void> {\n const command = [0x1b, 0x52, charset];\n await this.run(command);\n }\n\n async deleteToEOL(): Promise<void> {\n const command = [0x1b, 0x5b, 0x30, 0x4b];\n await this.run(command);\n }\n\n async setCursorPosition(row: number, column: number): Promise<void> {\n this.cursorPos = [row, column];\n\n const asciiRow = (row + 1).toString().charCodeAt(0);\n // asciiColumn can be more than one digit\n const asciiColumn = (column + 1)\n .toString()\n .split(\"\")\n .map((char) => char.charCodeAt(0));\n\n const command = [0x1b, 0x5b, asciiRow, 0x3b, ...asciiColumn, 0x48];\n await this.run(command);\n }\n\n async setCursorColumn(column: number): Promise<void> {\n this.setCursorPosition(this.cursorPos[0], column);\n }\n\n async setCursorRow(row: number): Promise<void> {\n this.setCursorPosition(row, this.cursorPos[1]);\n }\n\n async clearDisplay(): Promise<void> {\n const command = [0x1b, 0x5b, 0x32, 0x4a];\n await this.run(command);\n }\n\n get lengthToEnd(): number {\n return 20 - this.cursorPos[1];\n }\n\n get row(): \"top\" | \"bottom\" {\n return this.cursorPos[0] === 0 ? \"top\" : \"bottom\";\n }\n\n get currentRow(): number {\n return this.cursorPos[0];\n }\n\n get currentColumn(): number {\n return this.cursorPos[1];\n }\n}\n",
6
6
  "export const charset = {\n USA: 0,\n France: 1,\n Germany: 2,\n UK: 3,\n Denmark1: 4,\n Sweden: 5,\n Italy: 6,\n Spain1: 7,\n Japan: 8,\n Norway: 9,\n Denmark2: 10,\n Spain2: 11,\n LatinAmerica: 12,\n Standard: 30,\n Latin1: 31,\n Latin2: 32,\n Latin5_Turkey: 33,\n LatinInternational: 34,\n Cyrillic: 35,\n Hebrew: 37,\n Greek2: 36,\n Katakana: 63,\n SpacePage: 73,\n} as const;\n\nexport type Charset = (typeof charset)[keyof typeof charset];\n"
7
7
  ],
8
8
  "mappings": ";AAAA;AAGA,IAAM,WAAW;AACjB,IAAM,YAAY;AAAA;AAOX,MAAM,KAAK;AAAA,EACR;AAAA,EAGE,YAA8B,CAAC,GAAG,CAAC;AAAA,EAK7C,WAAW,CAAC,QAAsB;AAAA,IAChC,KAAK,SAAS;AAAA;AAAA,cAGH,OAAM,GAAkB;AAAA,IACnC,MAAM,UAAU,IAAI,QAAQ;AAAA,IAC5B,MAAM,cAAc,QAAQ,OAC1B,CAAC,YAAW,QAAO,aAAa,YAAY,QAAO,cAAc,SACnE;AAAA,IAEA,IAAI,YAAY,WAAW,GAAG;AAAA,MAC5B,MAAM,IAAI,MAAM,uBAAuB;AAAA,IACzC;AAAA,IAOA,MAAM,mBAAmB,YAAY,KAAK,CAAC,MAAM,EAAE,cAAc,CAAC;AAAA,IAElE,IAAI,CAAC,kBAAkB;AAAA,MACrB,MAAM,IAAI,MAA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1.0",
3
+ "version": "1.1.1",
4
4
  "author": {
5
5
  "name": "Caleb Perry",
6
6
  "url": "https://github.com/foxtrotperry",
@@ -11,13 +11,11 @@
11
11
  "files": [
12
12
  "dist"
13
13
  ],
14
- "main": "./dist/index.cjs",
15
14
  "module": "./dist/index.js",
16
15
  "types": "./dist/index.d.ts",
17
16
  "exports": {
18
17
  "types": "./dist/index.d.ts",
19
- "import": "./dist/index.js",
20
- "require": "./dist/index.cjs"
18
+ "import": "./dist/index.js"
21
19
  },
22
20
  "scripts": {
23
21
  "build:js": "bun run build.ts",
@@ -46,5 +44,6 @@
46
44
  },
47
45
  "dependencies": {
48
46
  "node-hid": "^3.2.0"
49
- }
47
+ },
48
+ "sideEffects": false
50
49
  }