Categories
Weekly Update

This Week In TurtleCoin (Jan 21, 2019)

Developer Updates

cryptonote-nodejs-pool – I’ve just finished updating the pool software for the upcoming fork, building on the fine work of the Plenteum developers. Check it out in action at fork-o-clock, over at https://trtl.heigh-ho.funkypenguin.co.nz 🙂 – funkypenguin

https://github.com/funkypenguin/cryptonote-nodejs-pool

Mobile Wallet – Hello, Not sure when I last gave an update. I have done most of the work on the wallet backend, and now I am starting on the mobile app UI. It’s a lot easier to find bugs when you start actually making the wallet. This probably will be the easiest part of making the wallet, but I’m not great at design so it’s a little slow. I’m not sure how tricky it is to get iOS wallet apps onto the App Store these days – I was under the impression they didn’t allow them, but I did recently see another relatively small crypto who had got a wallet on there. Fortunately react native supports iOS, so once the Android is done, I will certainly look into it. Not a massive fan of the license fee you have to pay, nor do I have an iOS device for testing… but at least we won’t have to write much more code. Thanks to iburnmycd for his turtlecoin-utils module – This has taken a decent amount of the hard bits of code to write off my shoulders. I recently also added support for syncing via the TurtlePay blockchain cache API in the backend – (https://docs.turtlepay.io/blockapi/) – currently this isn’t much faster than a daemon, however, I think it will probably have much better uptime, which should help avoid people wondering why their wallets are not syncing. – Zpalm

https://github.com/zpalmtree/ton-chan

TRTLfarm – TRTLfarm is an online virtual farming game build on top of TRTL.services by Boris. People can buy farm animals with TurtleCoin, which return produce based on their programmed production speed. The game started out as a small project, but has blown up quickly. Boris has working hard past few days and just finished implementing a leaderboard where turtles can track their rank. While I will giving the UI a touchup, Boris will be working on a surprise! Join us in the discord to discuss development and provide feedback! https://discord.gg/X7b7GWW – fexra

https://trtlfarm.com

WalletShell – Got help from very nice friends, who was willing to help me debugging and provides a tested macOS build. New macOS build is available here: https://github.com/turtlecoin/turtle-wallet-electron/releases/download/v0.3.7/WalletShell-v0.3.7-mac.dmg It’s confirmed to be working, but was only lightly tested and there may be bugs slips here & there. So if you happened to found one, please file a bug report on github. Thanks to @greywolf & @Messier_45 for your help! – labaylabay

https://github.com/turtlecoin/turtle-wallet-electron

CryptoNode Helper – Since I learned to use Docker for serving my TurtleCoin public node, I decided to script some of the commands I was using a lot. I chose to do it in a way that other people may benefit; and also to improve my coding skills along the way. Six weeks later; I have something that works well enough to share. In the video, I spin up a daemon in less than 5 minutes (excluding compile time and syncing the chain), and start the CPU miner. The repo comes with a few examples you can use yourself or adapt for your own CN coin. Feel free to raise issues on the GitHub or contribute some code yourself. It’s not perfect by any means, but it’s what I use! – Morpheus

https://asciinema.org/a/222640

https://github.com/19morpheus80/helper

TurtlePay – It’s been a busy week but I managed to get the callbacks documented at https://docs.turtlepay.io. This week I’m hoping to find time to build out a few more API calls for advanced developers. – IBurnMyCd

https://turtlepay.io

Nest Multiple Language Support – I added internationalization support to the Nest wallet! Nest now detects your OS locale, and displays in your language if a translation file has been added. – Turtley McTurtleton

https://github.com/jerme404/turtle-nest-fork/blob/i18n/docs/translating-nest.md

Raspberry PI Daemon Guide – I wrote a little guide to get set up with pi64 and running a node on a raspberry pi 3 b to celebrate ARM builds being fixed! Check it out and feel free to suggest improvements. Thanks – ExtraHash

https://github.com/turtlecoin/turtlecoin/wiki/Running-TurtleCoind-on-Pi

TurtleCoind finally runs like a charm on ARM(Pi) – The long wait is over. You can now run your TurtleCoin node on ARM(Pi). Over the past 1 month and many sleepless nights, we’ve finally cracked the segmentation fault problem with the TurtleCoin daemon on the ARM64 architecture. Now your node will run happily on any of your favorite 64-bit SoC board, such as Raspberry Pi 3(+), OrangePI One Plus, Rock64(Pine) and many more. If you are an early adopter and would like to test it, all you need is to clone the development branch of the TurtleCoin repo from github and compile your own binaries. We will release and publish the binaries for you to download for the ARM platform with the next scheduled release. Thank you to @iburnmycd, @thinkpol, @zpalmtree, @rashedmyt, @fexra, as well as to my dear wife @imrealeqra for waking me up from taking a nap on my keyboard every day in the past month around 5am morning 🙂 – LeoCuvée #1481

From The Blog..

Promote Your Bounty!

50,000 TRTL – it is good for the marketing, i think it is perfect – Guang

140,000 TRTL – Make an open-source, easily integratable web miner for turtlecoin and optionally host it on your own website. – Sajo8

Community Advertising

  • Two brand new community projects to check out already this year! Who sent 10 turtle by MrRovot and a custom minecraft server by WarLordN1k. So come any play all the communities amazing games @ games.turtacus.com
  • FREE public node, one of the only free ones left. greywolf Germany turtlenode.co http://turtlenode.co:11898/feeinfo
  • TurtleDice – Bet and try your luck with this new gambling website. You choose your winning chances and we roll the dice for you! No registration, fair and fun playing! https://turtledice.de.cool
  • Free Turtle Coin for cool dudes! Yup thats what we have here. Just click the link, collect your coin, and be excellent to each other!  https://trtl.faucet.llama.horse
  • FREE public node – one of only 3 FREE public nodes remaining. you can connect the CLI or Nest wallets to this FREE public node, based on 4 core Xeon, 200GB SSD, 8GB RAM VPS, located in Germany. http://turtlenode.co/connect/connect-to-node.html

Shoutouts & Thanks

Rogerrobers – Shout out to CapEtn

Captain Jac) – Shoutout to all turtles and welcome to all new ones

DazCat – I want to thank everyone in Discord for the warm welcome and quick answers to my questions 🙂

rock – I may have forgot to erase some of these from last week..

rock – shouts out to the people who leave funny pics and msgs in the roundup form with no descriptions. It always gives me a chuckle 🙂

BobbyBlank – Props to everyone who make TurtleCoin possible – from the humble gang of developers, to the community-at-large. Thanks for doing what you do, everyone – keep up the great work!!!

Sups – Great collaboration, Plasticus and Bazza working together to get the block Explorer working properly, nice work guys!

Specter – No matter how bad things seem to be, be thankful you are alive, that can all end in an instant, so fast, and nothing we can do to stop it. Take a moment to tell a loved one or a friend how much they mean to you. Don’t live with that regret.

LabayLabay – @greywolf for being super nice, wish you all the best!

canti – I met a homeless man on my way home from work today. He was convinced he was Steve Jobs and that the CIA faked his death to benefit capitalism, despite looking like Gary Oldman’s 20 year older brother. I had a morbid curiosity that made me want to hear out his ramblings, so I sat down to listen to his story. He told me he was in his prime and on top of the world until he brought up an idea he had to the overlords at Apple. (“Overlords” was his word not mine, just thought I’d throw that in.) This idea, it turns out, had to do with Apple’s stance on privacy, business, and innovation, and how he wanted to expand it into the monetary world. He told me how this idea, particularly how he wanted to bring it about, didn’t particularly jive with the other higher ups, whom he called “The Suits”; they only saw dollar signs in their eyes. Fast forward a few years now – after replacing him with a frail lookalike for public appearances, they ultimately faked his death, and go on to release Apply Pay back in 2014, which he says was a bastardization of what he wanted to bring to the world. But what about our protagonist? Well, he said by this point he had already been ostracized from the company and rejected by his peers, so he had delved back into the shadows, working in privacy on his true vision. He said he worked on a project with a couple friends for a while that went the wayside, but ultimately led him to where he’s at now, slowly working to make his dream a reality. The man I met? He wasn’t homeless at all as I originally thought, just a bit disheveled and maybe a bit stoned. Today I met RockSteady, the founder of TurtleCoin, and found out the secret behind his true identity.

japakar – http://prntscr.com/m9zfwf

Rock – Shoutout to Teacup for all the art! Thanks to all the release testers!  Big thanks to WZA for the neighborliness! shouts to Alien for the diversified input sizes! big whats up to the turtles we only see during certain times of year.. shout out to that scrawny kid Connie I ran in to on mushrooms at the vegan market!

 

 

 

See you guys next week 🙂 Go teach a friend something!

 

 

 

Categories
Feature Story

Transaction Inputs and Fusion Transactions (or “What is the max amount of TRTL I can send?”)

A large TurtleCoin transaction

A common question we get from users is wondering what the maximum amount of TRTL they can send is, often because they went to send a (relatively) small amount, and got an error ‘Transaction is too big’.

The question seems pretty simple, but the answer is not quite so simple!

To begin with, lets talk about what a transaction is made of.

Transaction Inputs / Outputs

When you send a transaction, lets say, 1000 TRTL, you might think it’s as simple as taking 1000 TRTL from your balance, encrypting it with your recipient’s public keys, and sending it out to the miners, to be included in a block.

However, your 1000 TRTL is actually made up of lots of smaller ‘Inputs’. These inputs come from previous transactions that you have recieved.

To demonstrate what I mean by this, lets start by looking at a coinbase transaction. A coinbase transaction is a special kind of transaction, where there is no sender. These are the rewards a miner gets for finding a block.

A coinbase transaction
The transaction the miner of block 800,000 received

Here’s the transaction that the miner of block 800,000 found. As you can see, they received 29,100.54 TRTL, but, if we look at the outputs section, they did not receive it all in one lump.

The transaction has been split up into several standard sized ‘Outputs’. The reason for doing this links into the privacy elements of TurtleCoin, and other CryptoNote coins. When we send a transaction, we hide one of our inputs alongside many other inputs. The network can verify that we own one of the inputs, but not which one. This allows the sender of a transaction to be hidden.

For this to work, we need there to be other inputs to select from. If we simply sent the exact amount in every transaction, then if you wanted to send an amount that had never been sent before, say, 1337 TRTL, you would not be able to obscure that you were the sender.

To ensure we always have enough inputs to match with, we use some set values, and build our transactions out of these smaller sized building blocks.

If you’re interested, you can view the possible sizes for transaction inputs here.

Hold on, what does it matter if my transaction has lots of inputs?

Well, when we send a transaction, we have to include each of our transactions inputs, along with the decoy inputs from other users, for the privacy features to function. These need to be available so we can verify that a user isn’t spending funds they don’t own, or trying to spend an input that has already been used.

To use a real world example, if you try and pay for a car in pennies, you’d need a pretty large jar to hold them all in. Similarly, when sending a transaction, each input takes up a bit of space in the blockchain. The largest a transaction can be is approximately 140 KB, and if your transaction will be larger than this, your wallet will reject it. This prevents your transaction being too large for a block, and never getting mined.

If your transaction is too large, stop thinking in amount, and start thinking in bytes.

Change

An unoptimized TurtleCoin wallet

Hopefully now you understand that a transaction is comprised of multiple inputs to make up the full amount of your transaction. One question on your mind may be – What if I have an input of 2000 TRTL, but I only want to send 1500 TRTL?

Well, we can do the exact same thing as when you were a kid and wanted to buy a candy bar, but you only had 5 dollars – you give the cashier your 5 dollars, and she gives you back 4 dollars in change.

Here’s an example of a real transaction, to show what I mean.

In this image, I sent 1500 TRTL to someone. You can see I used one input, of 20000 TRTL to do so. 500 TRTL + 1000 TRTL went to the receiver, and the other 18500 TRTL got sent back to my wallet.

You may have noticed when you send a transaction, some of your balance gets ‘Locked’. This is because you have had to send a bit more of your funds than needed, as you cannot make the exact amount, and you are waiting for the change to confirm on the blockchain, and return to you.

Optimization / Fusion Transactions

A TurtleCoin user performing fusion transactions

Now lets talk a bit about fusion transactions. If you haven’t heard of these before, that’s OK, they’re quite simple.

Recall how when we send a transaction, as long as the total value of the inputs/outputs on both sides match up, the amount of inputs/outputs we have doesn’t matter?

A fusion transaction is a special kind of transaction, where you are sending a transaction to yourself. We take all our small inputs on one side, and combine them into a few large outputs.

It’s a bit like those machines where you pour in your loose change, and get out a few dollar bills.

How can I send more TRTL?

So, on to the final section of this article – putting these steps into practice, so you can send more TRTL at one time.

Sending fusion transactions

Our first step we can take is to perform fusion transactions. The manner to do this depends upon what wallet you are using.

If you are using zedwallet, you can type optimize to perform multiple fusion transactions. This will also be done automatically for you, if a transaction fails due to being too large.

Similarly in Nest, if a transaction fails, it will offer you the chance to send a fusion transaction. These are done one at a time, so may take quite a while if you have a very unoptimized wallet!

Splitting up our transactions

If you’ve performed fusion transactions, and still aren’t able to send very large amounts, then unfortunately, the best option you can do is to split your transaction up into multiple smaller transactions.

Again, zedwallet will do this automatically for you (If you agree) upon failing to send a transaction due to it being too large. In Nest however, you will have to do this manually, with trial and error.

Avoiding the issue

Now, you might be wondering why you have so many small inputs. The simple answer is you have recieved a lot of transactions, or more importantly, a lot of small transactions. If you receive 1000 TRTL at a time, then the largest a single input could be, is 1000 TRTL. If you then want to send 100,000 TRTL, you will need to include 100 inputs, which ends up as a pretty large transaction.

If your mining pool has the option, you can increase your payment threshold. This will result in fewer inputs in your wallet, each with a larger amount. 1 payout of 5000 TRTL instead of 5 payouts of 1000 TRTL may make your transactions around 5 times smaller!

Solo miners can often send more TRTL at once

You may also like to consider using a smaller pool, which due to taking a longer time to find blocks, pays you out in larger chunks. Special mention to http://cryptonote.social/ which is a very cool solo mining pool – You get a full block payout everytime.

This is one of the reasons you encounter this issue in TurtleCoin, but don’t in other currencies, such as Monero, or Bitcoin – The payout thresholds for these currencies on mining pools are often very high, so you have very few transactions received. It’s worth noting that most cryptocurrencies use this method of including past payments in your payments, and returning extra change as a transaction to yourself.

If you’d like to read up more on the topic, in Bitcoin, these are called ‘Unspent Transaction Outputs’, or UTXOs.

Thanks

  • Thanks to turtle.land for the transaction screenshots – it’s a very nice looking block explorer, with great uptime!
  • Thanks to Der Wixer for his optimize maymay