Skip to content

Repository files navigation

Build status Crates.io

Tree-sitter grammar for PIO assembly files

About

This repo provides tree-sitter grammar for Rasperry Pi PIO assembly files (3.3. Using PIOASM, the PIO Assembler) files.

In addition to the grammar, the following queries are provided:

Query file Description
highlights.scm Syntax highlighting
injections.scm Injection queries for comments and C/Python code blocks
rainbows.scm Rainbow brackets for expressions
tags.scm Tags for .program, .define statements and labels
textobjects.scm Incremental selection for statements, instructions, labels and code blocks

Usage

Example usage with Helix

Add this to ~/.congig/helix/languages.toml.

[[language]]
comment-tokens = ";"
file-types = ["pio"]
name = "pio"
scope = "source.pio"

[[grammar]]
name = "pio"

[grammar.source]
git = "https://github.com/nmetschke/tree-sitter-pio"
rev = "bc094f6df53f4311468ded14be1c37e8dfdc601c"

and run hx --grammar fetch && hx --grammar build.

Nix + Helix

Some more usage options with Nix and Helix can be found here at my PIO LSP Server.

About

Tree sitter grammar and queries for Raspberrypi Pico pioasm

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages