Please note, this is a STATIC archive of website bitcoinsv.com from July 2022, cach3.com does not collect or store any user information, there is no "phishing" involved.
Home » News » Illustrating Bitcoin’s suitability for smart contracts and tokens

Bitcoin News

Illustrating Bitcoin’s suitability for smart contracts and tokens

Mihael Šinkec (Software developer at sCrypt) illustrates how you can use Bitcoin to build smart contracts and issue tokens.

At the first stage session during the WeAreDevelopers (WAD) World Congress in Berlin showed, Darren Kellenschwiler, Co-Founder & CTO of Elas and Developers Community Manager at Bitcoin Association, lay a theoretical foundation for understanding Bitcoin’s Turing-completeness – and thus, it’s suitability for building smart contracts and issuing tokens

Mihael Šinkec (Software developer at sCrypt) followed Kellenschwiler with an illustration of how you can use Bitcoin to build smart contracts and issue tokens. 

Illustrating Bitcoin as a Turing complete system

After having introduced himself and his company sCrypt, a company that deploys smart contracts on Bitcoin SV, Šinkec reverts the discussion back to the whitepaper. Contrary to what the majority in the blockchain space believes, Satoshi Nakamoto described the smart contract capability of Bitcoin:

‘The design supports a tremendous variety of possible transaction types that I designed years ago. Escrow transactions, bonded contracts, third party arbitration, multi-party signature, etc. If Bitcoin catches on in a big way, these are things we’ll want to explore in the future, but they all had to be designed at the beginning to make sure they would be possible later.’ – Satoshi Nakamoto

Why Bitcoin has been (mis)conceived as not Turing complete

Šinkec points out that these misconceptions arose due to the course that (what later became known as) Bitcoin Core took. As a Bitcoin implementation, Bitcoin Core got rid of all the original OPcodes to realise a user-based and supposedly decentralised version of Bitcoin. A by-product of this choice was that it does not scale and only supports a limited amount of transaction types. Šinkec stresses that this was not the original vision for Bitcoin as Satoshi Nakamoto intended:

‘It turns out that Satoshi was actually a long term thinker, and even before the Genesis block was mined, he actually introduced Bitcoin script. That’s really an expressive language in which you can code locking conditions for any transaction.’

Examples to prove Bitcoin’s Turing completeness

The sCrypt developer then provided practical examples to prove that Bitcoin is Turing complete. Applications that demonstrate Bitcoin’s Turing completeness include Conway’s ‘Game of Life’ and a so-called Rule 110 cellular automaton. Both of these applications are proven to run on Bitcoin SV and thus demonstrate its Turing completeness.

Šinkec then went on to describe sCrypt as a programming language and how it basically works. He did this because the company sCrypt translates core features of other blockchain protocols for the sole purpose of demonstrating sCrypts capabilities. The following softforks are either already implemented on BTC (Schnorr signatures and taproot) or are proposed (Graftroot).

  • Schnorr Signatures
  • Taproot
  • Graftroot

The Software engineer describes that sCrypt was able to run all of them natively on Bitcoin SV:

‘Here’s the contract for Schnorr signatures. So we actually implemented elliptic curve arithmetic inside the script itself. So there’s no need for any oracles or anything else, it runs on the base layer i.e. layer one.’ 

The case of Taproot is even more extreme. Because it was hard to implement on Bitcoin Core, it took Blockstream and other involved parties a lot of resources to develop it. Over the span of four years more than 150 developers were involved. Šinkec describes that with sCrypt, one single Bitcoin SV developer, namely sCrypt’s Founder and CEO, Xiaohui Liu was able to implement Taproot on Bitcoin SV in 20 minutes on the original Bitcoin protocol.

The developer then briefly outlined how via sCrypt Graftroot, ring signatures (Monero) and zK-SNARK – zero knowledge proof (Zcash) can all be implemented on Bitcoin SV as well. Similarly, it would also be no issue to run the entire Ethereum blockchain on Bitcoin SV as well, as the sCrypt engineer explains: 

‘Essentially, that means we could have like the whole Ethereum blockchain running on Bitcoin. On Ethereum they have global state. What that means is they have a single thread of execution. So we could just basically embed like their whole account model into a single line, a chain of UTXOs and that could run the entire Ethereum blockchain.’

Turning Ethereum smart contracts into Bitcoin SV script

As a lot of developers are used to building on Ethereum’s Solidity programming language, the question was now whether there is a quick way to get these smart contracts to sCrypt and Bitcoin SV.

sCrypt have been working on a solution in partnership with Vaionex, a Bitcoin SV Transpiler launched in May 2022. Šinkec demonstrated how this Solidity Transpiler translates any Solidity smart contracts and translates with a high accuracy (though he recommends that developers review the code to correct 5 – 10% of the translated code). 

The transpiler also comes with templates for token contracts (ERC-20, ERC-721), voting contracts and much more.

Join future developers events

This presentation took place at the WeAreDevelopers (WAD) World Congress in Berlin. To make sure you don’t miss out on similar events in future, follow us on Twitter.

Copy link
Powered by Social Snap