1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
|
Return-Path: <christophera@gmail.com>
Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136])
by lists.linuxfoundation.org (Postfix) with ESMTP id 74CE2C002B
for <bitcoin-dev@lists.linuxfoundation.org>;
Sun, 19 Feb 2023 23:05:28 +0000 (UTC)
Received: from localhost (localhost [127.0.0.1])
by smtp3.osuosl.org (Postfix) with ESMTP id 49AC760DA5
for <bitcoin-dev@lists.linuxfoundation.org>;
Sun, 19 Feb 2023 23:05:28 +0000 (UTC)
DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 49AC760DA5
Authentication-Results: smtp3.osuosl.org;
dkim=pass (2048-bit key) header.d=lifewithalacrity-com.20210112.gappssmtp.com
header.i=@lifewithalacrity-com.20210112.gappssmtp.com header.a=rsa-sha256
header.s=20210112 header.b=NdYfWmS5
X-Virus-Scanned: amavisd-new at osuosl.org
X-Spam-Flag: NO
X-Spam-Score: -1.399
X-Spam-Level:
X-Spam-Status: No, score=-1.399 tagged_above=-999 required=5
tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,
FREEMAIL_FORGED_FROMDOMAIN=0.25, FREEMAIL_FROM=0.001,
HEADER_FROM_DIFFERENT_DOMAINS=0.249, HTML_MESSAGE=0.001,
RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001]
autolearn=no autolearn_force=no
Received: from smtp3.osuosl.org ([127.0.0.1])
by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)
with ESMTP id uMTDDUcwxX-3
for <bitcoin-dev@lists.linuxfoundation.org>;
Sun, 19 Feb 2023 23:05:27 +0000 (UTC)
X-Greylist: whitelisted by SQLgrey-1.8.0
DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org ADB4760C04
Received: from mail-lj1-x22c.google.com (mail-lj1-x22c.google.com
[IPv6:2a00:1450:4864:20::22c])
by smtp3.osuosl.org (Postfix) with ESMTPS id ADB4760C04
for <bitcoin-dev@lists.linuxfoundation.org>;
Sun, 19 Feb 2023 23:05:26 +0000 (UTC)
Received: by mail-lj1-x22c.google.com with SMTP id m22so1469416ljp.0
for <bitcoin-dev@lists.linuxfoundation.org>;
Sun, 19 Feb 2023 15:05:26 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=lifewithalacrity-com.20210112.gappssmtp.com; s=20210112;
h=cc:to:subject:message-id:date:from:in-reply-to:references
:mime-version:from:to:cc:subject:date:message-id:reply-to;
bh=4QNiblDzbXrr30MKxRRZADxW3irTdnjrLLD/9U24IpU=;
b=NdYfWmS5M6adEY48TjW2QRyPGiDk/qi/+QqQ+RfH5pQAmJCUftnOvj4mQgH7KPWDtT
fBpWFCTZrsr8lmQCUZ+uT8/x3yOGK72QJGz3Y07+qD5AEXvmbS2KySF4wAtKvMJoAnJR
fe2RMBs9RuXFMtpAxr1l9V23+T22JFFu5aSDIY1ajKaRZBNhBRfVxQhCu0Gd8Tu+d5Xk
58KqLfjqLAJs6v7EcSRjKVtY9CYZ26rDQS4oKJIjGbPyjWDTiYXozcd0bSFW3hkuiy7M
TzEA81CuiIX23FRy+DQVKGtwuXdJT8uqbqViKVL5buhYadsuy6TO3VYgtYg4dhRWE8PF
/5+w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20210112;
h=cc:to:subject:message-id:date:from:in-reply-to:references
:mime-version:x-gm-message-state:from:to:cc:subject:date:message-id
:reply-to;
bh=4QNiblDzbXrr30MKxRRZADxW3irTdnjrLLD/9U24IpU=;
b=eyyOjSFJcciUjIvV1XzzLUU+PWsCKBl9wtg8s4L5bv6y29IknDsOE7Bgu4NU97iFQ9
hgILuiZkDI/L2+RhUWxQyZJu0Xgt7rOUG2dhTRoMCC3TS/qQSgaYuYMi8HH6l502ySuI
HmJQ8GaTuztT/s1TYsPhJC65tZv7mg0XsoHe7c4AP0T9bxmCEDrmk2zRtR88OyaMkroQ
iPbjlliviiriFIptfwQID7Bc7BpMhEvOo3op/7ifdtJF9cKR4PWn8Xv2cTa8XSIzslDR
JOyjZbUC3QieqZJYvpWnvupS0k8H+QIKkLQc9VHZwDTfZN2/zfb/k8UWMCLB6mHlzV/Z
uM0Q==
X-Gm-Message-State: AO0yUKW1jKEEF36GS7jx8K2yt1uPJUJGJOzFIyyb9TsVbA3CV1NXyYJn
U78cQMOw+Vrf7TjHWnmH/qMiEK2CO0u9XV/IGJ0=
X-Google-Smtp-Source: AK7set+TGeyu3BaactVE3AoJPe83tdtwct/ND+kTb3gmRcIRzBb8Y7PtrnouP/UDWd9TTzpN/otPI1Qnu/2SuO2slwA=
X-Received: by 2002:a2e:bc16:0:b0:294:69ba:6288 with SMTP id
b22-20020a2ebc16000000b0029469ba6288mr466040ljf.4.1676847924041; Sun, 19 Feb
2023 15:05:24 -0800 (PST)
MIME-Version: 1.0
References: <CAMZUoKmiwXW50F2onqNUZO8HXQa4+Z=z3s3WyN7-rAMV=KiSgw@mail.gmail.com>
<CAF90AvmaRYO6HKn9npyfzO6M6FZnN6DRhqopLpeSnHJNK=5i9g@mail.gmail.com>
<Y+40gVnMpj0prfQk@camus> <f19acdabd3fbc0ff389669131acbb79e@dtrt.org>
<Y/Ke4yV7eV/87Kat@camus>
In-Reply-To: <Y/Ke4yV7eV/87Kat@camus>
From: Christopher Allen <ChristopherA@lifewithalacrity.com>
Date: Sun, 19 Feb 2023 15:05:12 -0800
Message-ID: <CACrqygByMiEJNmn33DjOet8m3kjz116y-8y8v7EYrLq1-NG95w@mail.gmail.com>
To: Andrew Poelstra <apoelstra@wpsoftware.net>,
Bitcoin Protocol Discussion <bitcoin-dev@lists.linuxfoundation.org>
Content-Type: multipart/alternative; boundary="000000000000dae1c405f5159414"
X-Mailman-Approved-At: Sun, 19 Feb 2023 23:34:46 +0000
Subject: Re: [bitcoin-dev] Codex32
X-BeenThere: bitcoin-dev@lists.linuxfoundation.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Bitcoin Protocol Discussion <bitcoin-dev.lists.linuxfoundation.org>
List-Unsubscribe: <https://lists.linuxfoundation.org/mailman/options/bitcoin-dev>,
<mailto:bitcoin-dev-request@lists.linuxfoundation.org?subject=unsubscribe>
List-Archive: <http://lists.linuxfoundation.org/pipermail/bitcoin-dev/>
List-Post: <mailto:bitcoin-dev@lists.linuxfoundation.org>
List-Help: <mailto:bitcoin-dev-request@lists.linuxfoundation.org?subject=help>
List-Subscribe: <https://lists.linuxfoundation.org/mailman/listinfo/bitcoin-dev>,
<mailto:bitcoin-dev-request@lists.linuxfoundation.org?subject=subscribe>
X-List-Received-Date: Sun, 19 Feb 2023 23:05:28 -0000
--000000000000dae1c405f5159414
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
An easy but possibly very important tip:
If you use only UPPER CASE alpha and numbers in codex32, and avoid most
punctuation, it makes QR rendering of it significantly smaller. This is
because the QR code to the ISO SPEC, when seeing lowercase, assumes the
value is binary, then converts it to a two byte value. If instead, the
codex32 is all upper, and it uses only the 45 allowed characters (see
https://www.thonky.com/qr-code-tutorial/alphanumeric-table) , it will leave
it single byte and try to compress it. Of course it doesn=E2=80=99t compres=
s well,
but that is OK because it at least didn=E2=80=99t double the size first.
See our research on this topic at
https://github.com/BlockchainCommons/Research/blob/master/papers/bcr-2020-0=
03-uri-binary-compatibility.md
A superior QR codec can do better (see our
https://github.com/BlockchainCommons/QRCodeGenerator or
https://www.nayuki.io/page/qr-code-generator-library) but many platforms
and more basic QR codecs will double the size of the QR if you have any
lower case.
=E2=80=94 Christopher Allen
--000000000000dae1c405f5159414
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
An easy but possibly very important tip:=C2=A0<div dir=3D"auto"><br></div><=
div dir=3D"auto">If you use only UPPER CASE alpha and numbers in codex32, a=
nd avoid most punctuation, it makes QR rendering of it significantly smalle=
r. This is because the QR code to the ISO SPEC, when seeing lowercase, assu=
mes the value is binary, then converts it to a two byte value. If instead, =
the codex32 is all upper, and it uses only the 45 allowed characters (see <=
div dir=3D"auto"><a href=3D"https://www.thonky.com/qr-code-tutorial/alphanu=
meric-table">https://www.thonky.com/qr-code-tutorial/alphanumeric-table</a>=
) , it will leave it single byte and try to compress it. Of course it doesn=
=E2=80=99t compress well, but that is OK because it at least didn=E2=80=99t=
double the size first.=C2=A0</div></div><div dir=3D"auto"><br></div><div d=
ir=3D"auto">See our research on this topic at=C2=A0<div><a href=3D"https://=
github.com/BlockchainCommons/Research/blob/master/papers/bcr-2020-003-uri-b=
inary-compatibility.md">https://github.com/BlockchainCommons/Research/blob/=
master/papers/bcr-2020-003-uri-binary-compatibility.md</a></div><div dir=3D=
"auto"><br></div><div dir=3D"auto">A superior QR codec can do better (see o=
ur=C2=A0<div dir=3D"auto"><a href=3D"https://github.com/BlockchainCommons/Q=
RCodeGenerator">https://github.com/BlockchainCommons/QRCodeGenerator</a> or=
=C2=A0<div dir=3D"auto"><a href=3D"https://www.nayuki.io/page/qr-code-gener=
ator-library">https://www.nayuki.io/page/qr-code-generator-library</a>) but=
many platforms and more basic QR codecs will double the size of the QR if =
you have any lower case.</div></div></div><div dir=3D"auto"><br></div><div =
dir=3D"auto">=E2=80=94 Christopher Allen</div></div><div dir=3D"auto"><br><=
/div>
--000000000000dae1c405f5159414--
|