Metadata-Version: 2.1
Name: bitcoin-qr-tools
Version: 1.2.0
Summary: Python bitcoin qr reader and generator
Home-page: https://github.com/andreasgriffin/bitcoin-qrreader
License: GPL-3.0
Author: andreasgriffin
Author-email: andreasgriffin@proton.me
Requires-Python: >=3.9,<3.13
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Dist: base58 (>=2.1.1,<3.0.0)
Requires-Dist: bdkpython (>=0.32.0,<0.33.0)
Requires-Dist: hwi (>=3.0.0,<4.0.0)
Requires-Dist: mss (>=9.0.1,<10.0.0)
Requires-Dist: numpy (>=2.0.1,<3.0.0)
Requires-Dist: opencv-python-headless (>=4.10.0.84,<5.0.0.0)
Requires-Dist: pillow (>=10.4.0,<11.0.0)
Requires-Dist: pygame (>=2.6.1,<3.0.0)
Requires-Dist: pyqrcode (>=1.2.1,<2.0.0)
Requires-Dist: pyqt6 (>=6.7.0,<7.0.0)
Requires-Dist: pyzbar (>=0.1.9,<0.2.0)
Requires-Dist: segno (==1.6.1)
Description-Content-Type: text/markdown

# Bitcoin qr tools

* `BitcoinVideoWidget` recognizes (and classifies)  **blazingly fast**  
  * Addresses  (also BIP21 with amount)
  * Transactions (also base43 electrum encoding)
  * PSBT
  * Xpub
  * Descriptor
  * Multipath Descriptor (like Sparrow)
  * Partial descriptors (Specter DIY) (finger print , derivation, xpub)
  * TxId
  * SignerInfo(s) for Hardware Signer Exports (Wallet Export)
  * Animated QR Codes (BBQR), used by Coldcard
  * Animated QR Codes ([UR](https://github.com/BlockchainCommons/Research/blob/master/papers/bcr-2020-005-ur.md)), used by Foundation Passport, Keystone
  * Animated QR Codes used by Specter DIY
* Recognizes (and classifies)  **blazingly fast**  
* Animated QR Code generation via  `UnifiedEncoder.generate_fragments_for_qr()`
  * For BBQR, UR, and Specter DIY
* QR Code Widgets, via the widgets `QRCodeWidget`,  `QRCodeWidgetSVG`

### Demo

Run the demo with

```
python demo_reader.py
```

### Detection even in bad light contitions and bad camera

![screenshot](docs/bad-light.png)

### Automatic image enhancement for bright hardware signer screens

![screenshot](docs/enhanced.png)

# Install package

### From pypi

```shell
pip install bitcoin_qr_tools
```

### From git

* Setup poetry and install dependencies 
  
  ```sh
  curl -sSL https://install.python-poetry.org | python3 -  # see https://python-poetry.org/docs/master/#installing-with-the-official-installer
  poetry config virtualenvs.in-project true
  poetry install
  ```

* Run  
  
  ```sh
  poetry shell
  python -m bitcoin_qr_tools
  ```

# Licences

The python files in *bitcoin_qr_tools*  are under the [GPL3](LICENSE).

The folder *bitcoin_qr_tools/ur* is from https://github.com/Foundation-Devices/foundation-ur-py  and under   [BSD-2-Clause Plus Patent License](ur/LICENSE).

The folder *bitcoin_qr_tools/urtypes* from https://github.com/selfcustody/urtypes  is under  [MIT](urtypes/LICENSE.md).

