From bfc9572b8d2dac7840e759d607f619a55fc123e4 Mon Sep 17 00:00:00 2001 From: "Nikki (wiki profile)" Date: Fri, 9 Oct 2026 08:54:04 +0100 Subject: [PATCH] Ingest Kodak P210R reverse-engineering prompt --- SCHEMA.md | 2 +- ...kodak-p210r-reverse-engineering-project.md | 9 +- index.md | 3 +- log.md | 9 ++ ...r-reverse-engineering-diagnostic-prompt.md | 127 ++++++++++++++++++ 5 files changed, 144 insertions(+), 6 deletions(-) create mode 100644 raw/articles/kodak-p210r-reverse-engineering-diagnostic-prompt.md diff --git a/SCHEMA.md b/SCHEMA.md index c6862e4..23adadb 100644 --- a/SCHEMA.md +++ b/SCHEMA.md @@ -19,7 +19,7 @@ Agent profile: `/opt/data/profiles/wiki/` (isolated — only writes via this pro ## Tag Taxonomy - kb: kb, source, reference, note, summary - domain: personal, workflow, homelab, ai, model, tool, skill, script -- meta: comparison, timeline, open-question, confirmed, contested +- meta: comparison, timeline, open-question, confirmed, contested, project, artifact - layer: raw, entity, concept, comparison, query ## Page Thresholds diff --git a/concepts/kodak-p210r-reverse-engineering-project.md b/concepts/kodak-p210r-reverse-engineering-project.md index cf7fea2..664cb23 100644 --- a/concepts/kodak-p210r-reverse-engineering-project.md +++ b/concepts/kodak-p210r-reverse-engineering-project.md @@ -1,14 +1,14 @@ --- -title: Kodak P210R Reverse-Engineering Project +title: "Project: Kodak P210R Reverse Engineering" created: 2026-10-09 updated: 2026-10-09 type: concept -tags: [kb, concept, tool, workflow, open-question] -sources: [raw/articles/kodak-p210r-computer-compatibility-2026-10-08.md] +tags: [kb, concept, tool, workflow, open-question, project] +sources: [raw/articles/kodak-p210r-computer-compatibility-2026-10-08.md, raw/articles/kodak-p210r-reverse-engineering-diagnostic-prompt.md] confidence: medium contested: false --- -# Kodak P210R Reverse-Engineering Project +# Project: Kodak P210R Reverse Engineering ## Project goal @@ -78,4 +78,5 @@ The practical computer workflow remains computer → phone → Kodak app → pri ## Related - [[raw/articles/kodak-p210r-computer-compatibility-2026-10-08|Full research handoff and source URLs]] +- [[raw/articles/kodak-p210r-reverse-engineering-diagnostic-prompt|Diagnostic reverse-engineering prompt (project artifact)]] - [[index|Wiki index]] diff --git a/index.md b/index.md index fe4fd5b..97cdf86 100644 --- a/index.md +++ b/index.md @@ -15,6 +15,7 @@ - `raw/articles/google-workspace-mobile-account-migration.md` — verified source (Google Workspace cancel + Android account, official docs + Proton Easy Switch) - `raw/articles/best-stationery-uk-2026.md` — Danbury & Lovejoy: Best Stationery UK 2026 — Six Pieces Worth Buying (Jun 2026) - `raw/articles/kodak-p210r-computer-compatibility-2026-10-08.md` — research handoff on computer compatibility, partial protocol analysis, and requirements for reverse-engineering the P210R +- `raw/articles/kodak-p210r-reverse-engineering-diagnostic-prompt.md` — project artifact: diagnostic prompt for phased Bluetooth protocol capture, app analysis, native-client reconstruction, and print validation - `raw/articles/kindle-repair-code-2-jailbreak-recovery-handoff.md` — research handoff on PW5 Repair Code 2, recovery order, warranty, and serial-unbrick caveats - `raw/articles/uk-battery-video-doorbells-without-mandatory-subscriptions-2026-10-08.md` — research handoff comparing Reolink, Tapo, and eufy battery doorbells for UK subscription-free and local-server use @@ -31,9 +32,9 @@ - [[concepts/hermes-config-loader|Hermes Config Loader]] — multi-layered config system; YAML hierarchy, alias resolution, fallback providers, secrets handling; from 2026-10-08 config.yaml investigation - [[how-to-break-up-with-google-a-practical-step-by-step-migration-guide|How to Break Up with Google: A Practical, Step-by-Step Migration Guide]] — layered de-Google strategy: identity → storage → daily tools → mobile; domain-first; self-hosting email warnings; provider comparisons - [[concepts/kindle-repair-code-2-and-jailbreak-recovery|Kindle Repair Code 2 and Jailbreak Recovery]] — PW5 boot-failure triage, safe recovery order, warranty context, and explicit warning that the older serial guide is unverified for PW5 -- [[concepts/kodak-p210r-reverse-engineering-project|Kodak P210R Reverse-Engineering Project]] — potential project to reconstruct the Bluetooth RFCOMM protocol, image format, and computer-side print bridge - [[moving-domain-email-away-from-google-workspace|Moving Domain Email Away from Google Workspace]] — full migration guide: choosing a host, steps, MX records, canceling Workspace - [[mx-records|MX Records]] — DNS records that direct email delivery; key to switching providers +- [[concepts/kodak-p210r-reverse-engineering-project|Project: Kodak P210R Reverse Engineering]] — potential project to reconstruct the Bluetooth RFCOMM protocol, image format, and computer-side print bridge - [[soul-md-introduction|SOUL.md — Introduction, Placement, and Three Approaches]] — agent identity file placement / method / 3 approaches (official + community + persona); raw sources ingested 2026-09-25 - [[stationery|Stationery]] — notebooks, pens, ink, paper, planners (UK market; picks from Danbury & Lovejoy Jun 2026) diff --git a/log.md b/log.md index 5710a93..266a3be 100644 --- a/log.md +++ b/log.md @@ -98,3 +98,12 @@ Appended to log - Validation: new page required frontmatter present, 2 outbound wikilinks valid, raw hash valid, and index completeness 0 missing - Pre-existing lint debt remains: 13 broken active wikilinks and older frontmatter/tag issues elsewhere; neither new file adds a broken link - Files created or updated: `raw/articles/kodak-p210r-computer-compatibility-2026-10-08.md`, `concepts/kodak-p210r-reverse-engineering-project.md`, `index.md`, `log.md` + +## [2026-10-09] ingest | Kodak P210R reverse-engineering diagnostic prompt +- Raw project artifact preserved: `raw/articles/kodak-p210r-reverse-engineering-diagnostic-prompt.md`; body SHA-256 matches the source as `94905e1b23bbef21622ad06fbab61dbe66f3067f82523e984e1677de664ececf` +- Concept updated and titled `Project: Kodak P210R Reverse Engineering`; the diagnostic prompt is linked by minimal reference rather than duplicated +- Tag taxonomy extended with `project` and `artifact`; the raw prompt uses valid `raw`, `source`, `project`, and `artifact` tags +- Index updated with the raw artifact and revised concept title; total remains 14 Layer 2 pages +- Validation: raw body preserved exactly, changed-page frontmatter and tags valid, 3 outbound concept wikilinks resolve, and index completeness has 0 missing Layer 2 pages +- Pre-existing lint debt remains: 13 broken active wikilinks elsewhere in the wiki; this ingest adds none +- Files created or updated: `raw/articles/kodak-p210r-reverse-engineering-diagnostic-prompt.md`, `concepts/kodak-p210r-reverse-engineering-project.md`, `SCHEMA.md`, `index.md`, `log.md` diff --git a/raw/articles/kodak-p210r-reverse-engineering-diagnostic-prompt.md b/raw/articles/kodak-p210r-reverse-engineering-diagnostic-prompt.md new file mode 100644 index 0000000..f7e7694 --- /dev/null +++ b/raw/articles/kodak-p210r-reverse-engineering-diagnostic-prompt.md @@ -0,0 +1,127 @@ +--- +source_type: project_prompt +source_path: /opt/data/kodak-p210r-re-reverse-engineer-prompt.md +ingested: 2026-10-09 +sha256: 94905e1b23bbef21622ad06fbab61dbe66f3067f82523e984e1677de664ececf +tags: [raw, source, project, artifact] +--- +# Agent prompt: reverse engineer the Kodak P210R Bluetooth print protocol + +You are a research agent reverse engineering the Kodak Mini 2 Retro (P210R) Bluetooth portable +photo printer so it can be driven from a standard computer (Linux first). Work methodically, +verify every step, and stop and report before destructive actions (firmware writes, flashing). + +## Starting facts + +- Printer: Kodak Mini 2 Retro (P210R), made by Prinics Co., Ltd (FCC ID PO5C210R, derivative C210R). +- Connection: Bluetooth Classic (BDR/EDR), 79 channels, 2.4 GHz, GFSK/π/4DQPSK, 15.247 compliance. +- No USB data port for printing; PC-only path is over Bluetooth. +- Transport: Bluetooth **Serial Port Profile (SPP)** — a custom binary protocol on RFCOMM, not OBEX. +- Partial prior art: an 8-byte packet header has been identified: + `u8 msg_id | u8 unk | u8 unk | u8 pad(0) | u32be payload_len | u8[] payload`. + Some observed IDs: 0x64 (connect), 0x52 (print?), 0x01, 0x07, 0x54, 0x0B, 0x65, 0x12, 0x09. + One 128-byte message: 0–52 binary, 53–84 ASCII, 85–127 ASCII. Source: gist oldmud0. +- Mobile app: `com.prinics.kodak.photoprinter` (Android) / "KODAK Photo Printer" (iOS). +- Paper format: 2.1 × 3.4 in, 4PASS dye-sublimation, cartridge ICRG-260. + +## Phase 1 — Discover and observe the device + +1. Put on headphones and run the printer through a full print cycle. Note every Bluetooth event. +2. On a Linux PC with Bluetooth 4+ and a CSR/Ubertooth-compatible adapter (or a phone in + BT Classic snoop mode if the host adapter cannot sniff classic traffic): + - `hciconfig hci0 up; btmon` while pairing/triggering a print, and capture to a pcap. + - Identify the printer's BD_ADDR and the RFCOMM channel used by the app. + - If the host adapter cannot sniff its own connection, use a second adapter in snoop mode: + `hcitool con`, then `btmon --write /tmp/printer.pcapng`. +3. On Android, with the app freshly installed: + - Enable Developer Options + USB debugging. + - `adb logcat | grep -i prinics` during a Bluetooth connection + a single print. + - Optionally attach **Objection** or **Frida** to `com.prinics.kodak.photoprinter` and + intercept calls on `android.bluetooth.BluetoothSocket` / `OutputStream.write`. +4. Dump the Bluetooth pairing/bonding records: `bluetoothctl paired-devices`, and record MTU + negotiation and the exact RFCOMM channel number. + +Deliverable: a Wireshark capture (`*.pcapng`) plus a short table of packet boundaries and the +printer BD_ADDR, channel, and MTU. + +## Phase 2 — Extract and minimise the app behaviour + +1. Obtain the Android APK (e.g. via `gplaycli`, `adb shell pm path`, or `apktool`/`jadx` on a + downloaded APK). Verify its integrity. +2. Decompile with **jadx** (GUI or CLI). Focus on: + - The Bluetooth connection code (search: `BluetoothSocket`, `createRfcommSocket`, channel). + - Image-preparation code (search: `Bitmap`, `compress`, JPEG quality, byte order, size 2.1×3.4). + - Any "firmware update" path (firmware URL + the `download`/`download2` endpoints). +3. Identify the **exact message IDs** the app sends and the order for a minimal print job. Map at + least: connect handshake, image upload, print command, status poll. +4. Find the image encoding the printer expects. Is it raw JPEG? A header? A specific resolution/ + orientation? Capture a known test image (e.g. 512×512 solid color) and observe the bytes sent. + +Deliverable: a mapping of message IDs → purpose, the image format/resolution expected, and the +firmware-update endpoint (if present). + +## Phase 3 — Reconstruct a minimal native client + +1. Write a small Python program using `pybluez` (or raw `bluetooth` socket to an RFCOMM channel): + - Open the RFCOMM socket (channel from Phase 1). + - Send the handshake message from Phase 2 verbatim. + - If the printer replies with a session/version, use it to choose subsequent framing. +2. Implement the packet envelope from the known 8-byte header. Make payload length a parameter so + you can send the variable 128-byte status/config message. +3. With a test JPEG (plain, no app filters), send the image-upload message and observe the LED + response and any printer reply. Do **not** yet expect a perfect print — the goal is to confirm + the printer accepts the stream and enters a print-ready state. + +Deliverable: a working minimal Python RFCOMM client that can connect, handshake, and push an +image payload. + +## Phase 4 — Validate end-to-end print + +1. Refine the image payload (resolution, colour order, any printer-internal preprocessing) using + feedback from Phase 3 until the printer ejects a physical print. +2. Compare a print from your client against one from the official app for the same source image. +3. Confirm firmware-update path: capture one update cycle (it usually runs "the printer needs a + firmware update" on first print) and record whether updates block your client. If firmware + matters, document the version handshake so the client can decide whether to proceed. + +Deliverable: a reproducible script that prints an arbitrary image from the command line. + +## Phase 5 — Computer-side bridge + +1. Package the client as a small CLI (`kodak-print FILE.jpg`). +2. Optionally provide a trivial CUPS backend so `lp`/`a2ps`/any desktop app can target the printer. + +## Constraints + +- Legal: stay within fair-use reverse engineering of your own device. Do **not** redistribute the + APK. Do **not** fetch firmware binaries unless the task is explicitly authorised by the owner. +- Safety: never flash unknown firmware. If the printer exposes an update endpoint, observe but do + not trigger an update unless explicitly asked. Treat the 7.4 V Li-ion pack gently; do not + tamper with charging. +- Reporting: after each phase produce a 5–10 line prose summary plus the artefacts (pcap, ID + table, client script) so the owner can review before continuing. Stop immediately on any + "firmware update" requirement and ask before proceeding. + +## Required toolchain + +- Hardware: Linux PC; Bluetooth 4.0+ adapter (CSR 4.0 recommended — it can both connect and + sniff classic); optional second adapter for snoop mode; Android phone + USB-C cable. +- Software: + - Capture: `bluez`, `btmon`, `Wireshark`. + - Mobile: `adb`, `jadx`, `apktool`, Python `frida`/`objection` (optional). + - Analysis: `Ghidra` or `IDA Pro` (for native libs if the protocol is in C/C++). + - Python client: `pybluez` or stdlib `bluetooth` over RFCOMM; `Pillow` for image prep. + +## Success criteria + +- A captured Bluetooth session showing the connect handshake and a one-page print. +- A documented message-ID table. +- A command-line Python client that prints an arbitrary JPEG to the P210R. + +## Notes + +- The 8-byte header and packet IDs from the gist are unverified — treat them as a hypothesis to + test against a live capture. +- If the printer uses a non-standard MTU or L2CAP CoC instead of RFCOMM, document that and adapt. +- Expect the firmware first-print update prompt; that is the most likely point at which to pause + and confirm scope with the owner.