Skip to main content

lr35902dis

A python disassembler library for the LR35902 CPU (the CPU of the GameBoy, similar to a Z80 processor). This is an adaptation of z80dis. Any errors are probably mine, PRs welcome :).

Use

>>> from lr35902dis import lr35902
>>> lr35902.disasm(b'\xCB\xE7', 0)
'set 4,a'

Or, if you'd like access to the instruction internals, like opcode identifier, length, and operands:

>>> decoded = lr35902.decode(b'\xCB\xE7', 0)
>>> decoded.op
<OP.SET: 58>
>>> decoded.operands[0]
(<OPER_TYPE.IMM: 45>, 4)
>>> decoded.operands[1]
(<OPER_TYPE.REG_A: 1>,)
>>> decoded.len
2

The decoded structure can be supplied to disasm() to make a string:

>>> lr35902.disasm(decoded)
'set 4,a'

Metadata

Release files for lr35902dis 1.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for lr35902dis 1.0.2
File Size Uploaded Provenance Actions
lr35902dis-1.0.2.tar.gz 6.3 kB Without provenance Details for lr35902dis-1.0.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for lr35902dis 1.0.2
File Interpreter ABI Platform Actions
lr35902dis-1.0.2-py3-none-any.whl Python 3 none any Details for lr35902dis-1.0.2-py3-none-any.whl

Total release size: 13.2 kB

Release files / lr35902dis-1.0.2.tar.gz

Download URL lr35902dis-1.0.2.tar.gz
Size 6.3 kB
Tags Source
SHA-256 checksum
How to use checksums
c85ea2e97007554e8a6e5f375fd12146e7219e9bfd5f40e69a041c6812a1876e
BLAKE2b-256 checksum
How to use checksums
fd0c1b1f27008ffe319d85678850bdd6d7d845b9952177b9317852defc1a4de7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.1 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.10

Release files / lr35902dis-1.0.2-py3-none-any.whl

Download URL lr35902dis-1.0.2-py3-none-any.whl
Size 6.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
aad348ca28a71b9081b53ece37e10f6489ec51514587e0e26cd2f2629f570527
BLAKE2b-256 checksum
How to use checksums
b68f796f341d6dd6ddf307cc89bb6e7e45633a4682e43092365906333b9c0f3b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.1 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.10

Security for lr35902dis 1.0.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page