Skip to content

About

DePIN Oracle that issues payouts via custom Token on Solana by consuming submissions via MQTT

Resources

Stars

0 stars

Watchers

1 watching

Forks

Latest commit

 

History

15 Commits

Folders and files

Repository files navigation

Description

This was a DePIN Oracle that consumed miner submissions via miner software, which I named Trebuchet. The miner software is in another repository that I'm debating on open-sourcing for personal reasons. However, the miner essentially scanned over Bluetooth LTE Announcements and WiFi Beacon signals and ingested packets that matched the Remote ID / Open DroneID protocol, implemented by the FAA. It would then submit these payloads via an MQTT host with TLSv1.3 encryption, where this Oracle would consume those submissions, do some math on payouts, and handle the economy accordingly.

Regarding the TLSv1.3 encryption, the plan was that certificates for the individual machines would be issued via this Oracle and assigned a "Wallet" -- although, the certs don't care about a wallet for now, just that they match up.

I'm not an economist, I'm a programmer - so the crypto economy in this Oracle may not be the best design ever.

Flow

flowchart TD
    A[Drone Scanner] -->|Drone Found| B(Publish to MQTT Broker over TLSv1.3)
    B --> C{MQTT}
    C -->|Consume| D[Payout Queue]
    D -->|Number of Payouts > 10| E[Submit Bulk Payouts]
Loading

An example bulk payout can be seen here on Solana's devnet: https://explorer.solana.com/tx/3K2gFZMCiv4GFqBNz8P8GfqoAhw2P9Rkp8VaNSnUJAdHgo9rJJw8EVEtEYXZgrbQqQsmfgZdFgTswJKWUB54R5P6?cluster=devnet

Getting Started

  1. Generate certs (openssl required)
  • make bootstrap_ca to generate the Certificate Authority
  • make bootstrap_server to generate the server certificate and key, signed with the CA -- this is for the MQTT broker
  • make bootstrap_client to generate the client certificate and key, signed with the CA -- this is for the Oracle
  1. Run the stack with docker compose up -d
  2. Send a test message with make send_message

Setting up with Solana's Devnet

  1. make solana_devnet
  2. make solana_create_wallet
  3. make solana_fund_wallet or go to https://faucet.solana.com and do this for devnet manually; sometimes the CLI doesn't work
  4. make solana_create_token
  5. make solana_create_token_account
  6. make solana_mint_token -- optional

You'll modify oracle.yml with the proper mint_address

About

DePIN Oracle that issues payouts via custom Token on Solana by consuming submissions via MQTT

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages