Make Parse take raw NFC UID and 1K image.

Drop zip/JSON from the root API. dump remains an adapter for the Android app format; inventory and an AMS wand both call Parse(uid, image).
This commit is contained in:
2026-08-23 15:27:11 -05:00
parent b38f7f643b
commit b67b37dc59
7 changed files with 110 additions and 169 deletions
+5 -8
View File
@@ -2,21 +2,18 @@ package bambunfc
import (
"errors"
"os"
"slices"
"testing"
)
func TestMergeFixtures(t *testing.T) {
t.Parallel()
f, err := os.Open("testdata/dumps.zip")
if err != nil {
t.Fatal(err)
uids := []string{
"e27be276", "52d60177", "92a80577", "b2d32177", "92b6fb31", "f28c58ed",
}
defer f.Close()
tags, err := ParseZip(f)
if err != nil {
t.Fatal(err)
tags := make([]Tag, 0, len(uids))
for _, id := range uids {
tags = append(tags, parseFile(t, id))
}
spools, err := Merge(tags)
if err != nil {