Decentralized Mining Pools
  • Main Page
  • Flow diagrams
  • Sandbox BTCDEB
  • Bitcoin version, RPC, explorer
    • Run clarinet integrate with bitcoin regtest v24.0
    • Custom docker image regtest 24.0.1
    • RPC Browser and transactions legacy
  • Block commit
  • Multiple miners interacting in the same network
  • Rust Taproot Transactions
    • Dependencies
  • Smart Contract
    • Overall explanations
    • Election System
      • Add new miner
      • Remove Miner
      • Update Notifier
    • Funds System
  • Front End
    • Overall
    • UI display usecases
    • How to link it to the sc
    • Github Repository
Powered by GitBook
On this page
  • All details and explanations are in the following files:
  • To check transactions in the end

Sandbox BTCDEB

PreviousFlow diagramsNextBitcoin version, RPC, explorer

Last updated 10 months ago

The most direct approach to creating bitcoin transactions is using a regtest and a tool that simulates the process step by step.

Bitcoin Debugger is an excellent tool in this regard, it also is convenient for creating taproot leaves, branches, and trees.

By following the updated version of the BTCDEB you should be able to create a tree that contains that 2 script paths. The script flow is also very similar to the one wanted.

  1. Alice path is close to the reclaim path as the user who sent the funds can reclaim them from the script after X blocks.

  2. Bob path is similar to paying to PoX address as in the example

    1. it creates a transaction that uses the script path as UTXO and the output is another address

    2. it gets signed

    3. it gets broadcasted and the address receives the funds

All details and explanations are in the following files:

  1. A more straightforward example to just getting the transaction simulated can be found here

  1. A more detailed version which explains in detail how things are combined and how to obtain the values wanted is here

To check transactions in the end

  1. Get all transactions from the regtest. The list of transactions contains all of them, including the blocks mined.

  2. Save them in a variable locally on a browser console.

  3. Filter transactions by amount < 6 or by address to be the wanted address.

x = the whole list
x.filter(x => x.address === 'bcrt1qez0gdlpk50p0cxpgaf0gm3udtcjeujrfghydle')
x.filter(x => x.amount < 6)sc
GitHub - bitcoin-core/btcdeb: Bitcoin Script DebuggerGitHub
btcdeb/tapscript-example-with-tap.md at master · bitcoin-core/btcdebGitHub
btcdeb/tapscript-example.md at master · bitcoin-core/btcdebGitHub
Logo
Logo
Logo