Presentation is loading. Please wait.

Presentation is loading. Please wait.

Swagatika (Jazz) Sarangi

Similar presentations


Presentation on theme: "Swagatika (Jazz) Sarangi"— Presentation transcript:

1 Swagatika (Jazz) Sarangi
Why Solidity is Solid – Basic of Ethereum, Smart Contracts, and Blockchain Swagatika (Jazz) Sarangi

2 Don’t get intimidated by words like…
Byzantine Fault Tolerance Off-Chain Governance On-Chain Governance Distributed Byzantine Fault Tolerance (NEO) Smart Contract Proof of Work Practical Byzantine Fault Tolerance (Tendermint) Proof of Stake Hyperledger Planning to self-teach? Don’t go to Reddit at first.

3 Evolution of Blockchain(Digital Ledger)
1st generation: Store and transfer of value (e.g. Bitcoin, Ripple, Dash) 2nd generation: Programmable via smart contracts (E.g. Ethereum) 3rd generation: Enterprise blockchains (E.g. Hyperledger, R3 Corda & Ethereum Quorum) Next gen: Highly scalable with high concurrency (E.g. RChain)

4 What is Ethereum Ethereum is a network or operating system which contains ‘smart contracts’. Ethereum networks are used to transfer money and store data. There are many different ethereum networks. Networks are formed by one or more nodes. Each node is a machine running an ethereum client. Anyone can run a node. Each node can contain a full copy of the blockchain.

5 Interfacing with Ethereum Network:
In this demo, we will work on web3.js (Ethereum client library). This library will allow us to send money, store data, deploy contracts etc. It is used by developers to create application. People who do not want to program but consume, there are 2 great solutions available in the market. Consumers/Front-end Users can use: MetaMask – this is a browser extension that allows people to interact (You can install MetaMask google chrome extension) Mist Browser – It is in an early phase.

6 What is MetaMask MetaMask is an Ethereum browser and a wallet. MetaMask allows one to interact ‘Smart Contracts’ without downloading any blockchain software. By creating MetaMask account, you will create your own wallet, where you can deposit and send Ether to other people. Download it here: befgpgknn?hl=en

7 DEMO Let’s create an Ether account by using MetaMask and get some ‘fake’ ether deposited to our account To request some ether, visit: faucet.com/send?address=0xD96A28097a01047dac02a184dc5908Ba6FbB01Ee Get your 12 word Mnemonic phrase and go to the tool to understand Account sequence in action:

8 Working with MetaMask/Rinkeby Test Network

9 What is a Smart Contract?
Smart contracts are what we use to build interesting application on the blockchain. Smart Contract – An account controlled by code. It is going to be authored by a developer. Instead of being controlled by a human just like the account at the metamask was controlled by you, a smart contract account is going to be controlled by a developer. It is executed on Ethereum Virtual Machine (EVM). We are using “Remix” online coding platform to write ‘Smart Contract’ in this demo.

10 DEMO Let’s create a Smart Contract

11 Creating our first ‘smart contract’

12 Difference between ‘MetaMask’ and ‘Smart Contract’ account
MetaMask Account Smart Contract Account Created at the front-end with a business user. Created at the back-end with a developer. Can be accessed across all networks, such as Ropsten, Koven or Rinkeby etc. Have to deploy the code individually across all networks for this account to be accessed. It is network specific. External account Internal account. Needs google chrome extension Does not need any UI extension. And can be created inside visual studio.

13 Bits and pieces of a Smart Contract
nonce How many times the sender has sent a transaction To (This blank means we are creating a new contract. This blank field creates a new contract.) data Compiled bytecode of the contract value Amount of ‘Wei’ to send to the target audience gasPrice Amount of ‘Wei’ to send to the target address startGas/gasLimit Unit of gas that this transaction can consume v Cryptographic pieces of data that can be used to generate the senders account address. Generated from the sender’s private key. r s

14 How many times the sender has sent a transaction
Bits and pieces of a MetaMask nonce How many times the sender has sent a transaction to Address of the account this money is going to data Compiled bytecode of the contract value Amount of ‘Wei’ to send to the target audience gasPrice Amount of ‘Wei’ to send to the target address startGas/gasLimit Unit of gas that this transaction can consume v Cryptographic pieces of data that can be used to generate the senders account address. Generated from the sender’s private key. r s

15 How much Gas it would cost me to run operations on Ethereum network:

16 More ‘gas’ terms gasPrice
Amount of Wei the sender is willing to pay per unit gas to get this transaction processed startGas/gasLimit Unit of gas that this transaction can consume We also have to spend some amount of gas to ‘store the data on Blockchain’.

17 Requesting additional Free Ether:

18 References Rinkeby-Faucet: Anders Blockchain: Solidity coding platform: Ethereum converter: Udemy course: Gas price: Mnemonic Code Converter: Get more Ether than what Rinkeby provides? - Faucet.rinkeby.io (Can request upto ether.) Off-chain vs On chain Governance:


Download ppt "Swagatika (Jazz) Sarangi"

Similar presentations


Ads by Google