Blame
| 78242c | Peter van Dijk | 2026-02-12 13:08:44 | 1 | # Indoor ROCK PI |
| 2 | ||||
| 3 | [datasheet](https://helium.nebra.com/datasheets/hotspots/rockpi/RockPi-Helium-Miner-Datasheet-v2-1.pdf) |
|||
| 4 | ||||
| 5 | * Rock Pi ?? ?? |
|||
| 6 | * 2GB RAM |
|||
| 7 | * 32GB eMMC |
|||
| 8 | * 40 pin hat with mpcie slot with 1301 concentrator |
|||
| 9 | * |
|||
| 8fdd19 | Peter van Dijk | 2026-02-12 13:27:49 | 10 | |
| 11 | ## Zebra hat pinout |
|||
| 12 | ||||
| 13 | * CS (raspi GPIO24, raspi physical pin 18, rockpi pin `gpioset 4 28=1` (from `gpioinfo | egrep '^g|PIN_18`)) |
|||
| 14 | * RST (raspi GPIO17, raspi physical pin 11, rockpi pin 4 18) |
|||
| 15 | * BUSY (raspi GPIO27, raspi physical pin 13, rockpi pin 4 22) |
|||
| 16 | * IRQ (raspi GPIO22, raspi physical pin 15, rockpi pin 4 21) |
|||
| c41b2d | Peter van Dijk | 2026-02-12 19:30:14 | 17 | |
| c059dd | Peter van Dijk | 2026-02-12 20:42:58 | 18 | pymc_core patch to go with this (the pymc_core "new radios" branch which will hopefully release soon should make this patch obsolete): |
| c41b2d | Peter van Dijk | 2026-02-12 19:30:14 | 19 | |
| 20 | ```diff |
|||
| 21 | diff --git a/examples/common.py b/examples/common.py |
|||
| 22 | index 826b542..0a6436c 100644 |
|||
| 23 | --- a/examples/common.py |
|||
| 24 | +++ b/examples/common.py |
|||
| 25 | @@ -121,6 +121,22 @@ def create_radio(radio_type: str = "waveshare", serial_port: str = "/dev/ttyUSB0 |
|||
| 26 | "coding_rate": 5, |
|||
| 27 | "preamble_length": 17, |
|||
| 28 | }, |
|||
| 29 | + "zebra": { |
|||
| 30 | + "bus_id": 0, |
|||
| 31 | + "cs_id": 0, |
|||
| 32 | + "cs_pin": 28, |
|||
| 33 | + "reset_pin": 18, |
|||
| 34 | + "busy_pin": 22, |
|||
| 35 | + "irq_pin": 21, |
|||
| 36 | + "txen_pin": -1, |
|||
| 37 | + "frequency": int(869.618 * 1000000), # EU: 869.525 MHz, |
|||
| 38 | + "tx_power": 22, |
|||
| 39 | + "spreading_factor": 8, |
|||
| 40 | + "bandwidth": int(62.5 * 1000), |
|||
| 41 | + "coding_rate": 8, |
|||
| 42 | + "preamble_length": 17, |
|||
| 43 | + "use_dio3_tcxo": True |
|||
| 44 | + }, |
|||
| 45 | } |
|||
| 46 | ||||
| 47 | if radio_type not in configs: |
|||
| 48 | diff --git a/examples/discover_nodes.py b/examples/discover_nodes.py |
|||
| 49 | index 097be79..9a62b5b 100644 |
|||
| 50 | --- a/examples/discover_nodes.py |
|||
| 51 | +++ b/examples/discover_nodes.py |
|||
| 52 | @@ -149,7 +149,7 @@ def main(): |
|||
| 53 | parser = argparse.ArgumentParser(description="Discover nearby mesh nodes") |
|||
| 54 | parser.add_argument( |
|||
| 55 | "--radio-type", |
|||
| 56 | - choices=["waveshare", "uconsole", "meshadv-mini", "kiss-tnc"], |
|||
| 57 | + choices=["waveshare", "uconsole", "meshadv-mini", "kiss-tnc", "zebra"], |
|||
| 58 | default="waveshare", |
|||
| 59 | help="Radio hardware type (default: waveshare)", |
|||
| 60 | ) |
|||
| 61 | diff --git a/src/pymc_core/hardware/gpio_manager.py b/src/pymc_core/hardware/gpio_manager.py |
|||
| 62 | index 399a5da..7d1e003 100644 |
|||
| 63 | --- a/src/pymc_core/hardware/gpio_manager.py |
|||
| 64 | +++ b/src/pymc_core/hardware/gpio_manager.py |
|||
| 65 | @@ -44,7 +44,7 @@ logger = logging.getLogger("GPIOPinManager") |
|||
| 66 | class GPIOPinManager: |
|||
| 67 | """Manages GPIO pins abstraction using Linux GPIO character device interface""" |
|||
| 68 | ||||
| 69 | - def __init__(self, gpio_chip: str = "/dev/gpiochip0"): |
|||
| 70 | + def __init__(self, gpio_chip: str = "/dev/gpiochip4"): |
|||
| 71 | """ |
|||
| 72 | Initialize GPIO Pin Manager |
|||
| 73 | ||||
| 74 | @@ -77,7 +77,7 @@ class GPIOPinManager: |
|||
| 75 | return chips[0] |
|||
| 76 | else: |
|||
| 77 | logger.warning("No GPIO chips found, defaulting to /dev/gpiochip0") |
|||
| 78 | - return "/dev/gpiochip0" |
|||
| 79 | + return "/dev/gpiochip4" |
|||
| 80 | return gpio_chip |
|||
| 81 | ||||
| 82 | def setup_output_pin(self, pin_number: int, initial_value: bool = False) -> bool: |
|||
| 83 | ``` |
