{"id":19535620,"url":"https://github.com/miyako/4d-plugin-direct-print","last_synced_at":"2026-02-05T18:32:21.263Z","repository":{"id":147172331,"uuid":"66802283","full_name":"miyako/4d-plugin-direct-print","owner":"miyako","description":"Send raw data to printer","archived":false,"fork":false,"pushed_at":"2024-04-11T14:41:49.000Z","size":17926,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-13T01:21:50.092Z","etag":null,"topics":["4d-plugin"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/miyako.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2016-08-29T01:52:09.000Z","updated_at":"2024-08-27T05:05:22.000Z","dependencies_parsed_at":null,"dependency_job_id":"827f09fb-778a-4f7b-8b50-93ef4a6b33a7","html_url":"https://github.com/miyako/4d-plugin-direct-print","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/miyako/4d-plugin-direct-print","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/miyako%2F4d-plugin-direct-print","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/miyako%2F4d-plugin-direct-print/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/miyako%2F4d-plugin-direct-print/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/miyako%2F4d-plugin-direct-print/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/miyako","download_url":"https://codeload.github.com/miyako/4d-plugin-direct-print/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/miyako%2F4d-plugin-direct-print/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29128711,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-05T18:31:02.507Z","status":"ssl_error","status_checked_at":"2026-02-05T18:29:43.962Z","response_time":65,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["4d-plugin"],"created_at":"2024-11-11T02:19:21.025Z","updated_at":"2026-02-05T18:32:21.247Z","avatar_url":"https://github.com/miyako.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"![version](https://img.shields.io/badge/version-17%2B-3E8B93)\n![platform](https://img.shields.io/static/v1?label=platform\u0026message=mac-intel%20|%20mac-arm20|%20win-64\u0026color=blue)\n[![license](https://img.shields.io/github/license/miyako/4d-plugin-direct-print)](LICENSE)\n![downloads](https://img.shields.io/github/downloads/miyako/4d-plugin-direct-print/total)\n\n# 4d-plugin-direct-print\nSend raw data to printer\n\nbased on \n\nhttp://stackoverflow.com/questions/2044676/net-code-to-send-zpl-to-zebra-printers\nhttp://stackoverflow.com/questions/4442122/send-raw-zpl-to-zebra-printer-via-usb\n\n## Syntax\n\n```4d\nPRINT BLOB(printer;data;error{;type})\n```\n\nParameter|Type|Description\n------------|------------|----\nprinter|TEXT|\ndata|BLOB|\nerror|LONGINT|\ntype|TEXT|\n\n```4d\nPRINT BLOB ARRAY(printer;data;error{;type})\n```\n\nParameter|Type|Description\n------------|------------|----\nprinter|TEXT|\ndata|ARRAY BLOB|\nerror|LONGINT|\ntype|TEXT|\n\n## Examples\n\n```4d\n$printerName:=\"ZEBRA GK420D\"\nC_BLOB($ZPL)\n\n  // Command to be sent to the printer\n$code:=\"^XA^FO10,10,^AO,30,20^FDFDTesting^FS^FO10,30^BY3^BCN,100,Y,N,N^FDTesting^FS^XZ\"\n\nCONVERT FROM TEXT($code;\"us-ascii\";$ZPL)\n\nC_LONGINT($ERR)\n  //ERR_OPEN_PRINTER: -1\n  //ERR_START_DOC_PRINTER: -2\n  //ERR_WRITE_PRINTER: -3\n  //ERR_END_DOC_PRINTER: -4\n\nPRINT BLOB ($printerName;$ZPL;$ERR)\n\nARRAY BLOB($ZPLs;3)\n$ZPLs{1}:=$ZPL\n$ZPLs{2}:=$ZPL\n$ZPLs{3}:=$ZPL\n\nPRINT BLOB ARRAY ($printerName;$ZPLs;$ERR)\n```\n\nBoth commands accept an optional ``$4``, which is a MIME type on Mac (passed to [PMPrinterPrintWithProvider](https://developer.apple.com/reference/applicationservices/1461110-pmprinterprintwithprovider?language=objc)), or ``pDatatype`` of the [DOC_INFO_1](https://msdn.microsoft.com/en-us/library/windows/desktop/dd162471(v=vs.85).aspx) structure on Windows.\n\nBy default, the value is ``application/vnd.cups-raw `` on Mac, ``RAW`` on Windows.\n\nTo print PDF direcrtly on Mac\n\n```4d\nPRINT BLOB(Get current printer;$PDF;$ERR;\"application/pdf\")\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmiyako%2F4d-plugin-direct-print","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmiyako%2F4d-plugin-direct-print","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmiyako%2F4d-plugin-direct-print/lists"}