Caveat: This is just for fun! There is no sysadmin. Make sure you only use low amounts. There are no guarantees that this works. You are using this at your own risk. But it is fun 😃 and may even be useful.
An ATM has been set up so Smileycoin and Litecoin users can do the following:
- Send Smileycoin to a predefined SMLY address and get back Litecoin
- Get a pair of (SMLY,LTC) addresses so that sending to either one will convert to the other currency and send back to the user
This is a call for testers. If you enjoy messing around and trying stuff, do give this a shot and let us know what fails. Do remember though, that you may lose your SMLY or LTC and when you do, you're on your own!
Part A: Converting Smileycoin to Litecoin
Step 1: Backup your wallet.dat file and stop your wallet.
Step 2: Get a development version of the Smilecyoin wallet from github. For this you need to know how to compile a wallet for Linux, Windows or OSX. Follow the download directions at tutor-web.info/smileycoin but make sure you set git to use the sendwithmessage
thread.
Step 3: Start the wallet.
Step 4: If you have not done so already, get to know the command line options to smileycoin-cli
. Under Linux these are usually given on the shell command (to smileycoin-cli
) but under Windows and OSX you may want to give them in the debug console window. Start by using the command “getinfo” just to see that it works. Make sure your wallet is connected and up-to-date by checking the height (block count). Your screen should look something like this
Step 5: Make sure you have some SMLY in your wallet. You will need a bit.
Step 6: Open the Litecoin wallet, get an address and copy it to the clipboard.
Step 7: In the Smileycoin wallet, type the following command into the command window using your own LTC address:
Note that the message has to be of the form
sendwithmessage BLca5pTafbgH7p4ZF3ZzrPSrx6swafXAYf 2000 "Buy LTC <yourLTCaddress>"
and all other messages will be ignored. Only this SMLY address will work.
The magic: If everything has been done correctly, the ATM will see this SMLY transaction in the blockchain, read the message, convert the SMLY to LTC equivalents and send the LTC to your LTC address.
You can now repeat Step 7 as often as you like, to automagically convert SMLY to LTC.
Part B: Converting Litecoin to Smileycoin
Step 1: Get some SMLY to be able to communicate
- A Steemit tutorial (https://steemit.com/blockchain/@gstefans/more-messing-around-with-the-blockchain-an-atm-for-smly) has been set up to do this by sending a SMLY address encoded in a LTC transaction. If you have no means of obtaining SMLY, this is a way to get the first batch of SMLY.
- Alternatively, just buy SMLY on an exchange
- or donate to Education in a Suitcase who will give you some SMLY as perks.
If you are comfortable with the technical details of the Steemit tutorial, then you need go no further. This demonstrates how you can convert Litecoin to Smileycoin. It does get very technical though and the following is much easier, once you have some SMLY.
Step 2: Get the ATM to send you a LTC address for deposits.
You need to own 4000 SMLY to start this process.
Go into the SMLY command window and type the following command into the command window using your own LTC address:
Note that the message has to be of the form
sendwithmessage BLca5pTafbgH7p4ZF3ZzrPSrx6swafXAYf 4000 "Send LTC SMLY addresses <yourLTCaddress>"
The amount is important: It needs to cover the retransmission of two deposit addresses! There will be no response from the ATM if the amount is less than 4000 SMLY.
Now wait until you see an incoming transaction.
Step 3: Read the messages coming from the ATM. If the request for SMLY addresses has been sent correctly, the ATM will send a transaction back.
Once you see an incoming transaction, make a note of it and ask to see the transaction using the gettransaction
command, something like this (replace with your transaction ID):
gettransaction 36dae66ca57bc8923ff8d5baddd2327bc65edd851600618f1b76afa0ff98bef7
The result will include a lot of gibberish, but the important part is in a line labelled “rawmessage” as in the following example:
{
"amount" : -3500.00000000,
"fee" : -3.00000000,
"confirmations" : 517,
"blockhash" : "e2218e6ae8373cedb541fd111fa26f3d98a1f5161996dbbbb59c4923f2206048",
"blockindex" : 2,
"blocktime" : 1517573843,
"txid" : "36dae66ca57bc8923ff8d5baddd2327bc65edd851600618f1b76afa0ff98bef7",
"walletconflicts" : [
],
"time" : 1517573490,
"timereceived" : 1517573490,
"rawmessage" : "deposit address, LTC: LfivT1EQQcwhnL9ab3jwYaFEzqtHkW2RXL and SMLY: BNgLMJ8wdzLeTULnKx2dXYdzGj5yn35JDq ",
"details" : [
{
The message gives two deposit addresses. In this case, the user has been allocated LfivT1EQQcwhnL9ab3jwYaFEzqtHkW2RXL
as a Litecoin deposit address and BNgLMJ8wdzLeTULnKx2dXYdzGj5yn35JDq
as a SMLY deposit address.
If Smileycoins are sent to BNgLMJ8wdzLeTULnKx2dXYdzGj5yn35JDq
the ATM will return Litecoin to the address specified in the original request for addresses (LKHh2ug4vX9V6SAyY1Fo9gv7sMEnjAG3mc
above).
Similarly, if Litecoin are sent to LfivT1EQQcwhnL9ab3jwYaFEzqtHkW2RXL
the ATM will return Smileycoin to the SMLY address which was originally used to send the request for addresses.
Finally
The ATM looks up the rate on coinmarketcap and inserts a small spread so as not to lose money. This is fine for low amounts.
Eventually a scheme will be implemented whereby the exchange rate will be changed in a nonlinear manner for high deposits/withdrawals so as to ensure that the ATM wallet does not go empty for either coin. The details have yet to be worked out.
Just stick to low amounts!
Note that you can also use sendwithmessage
to get the exchange rate. Just send "get rate buy LTC from SMLY" with 1000 SMLY to BLca5pTafbgH7p4ZF3ZzrPSrx6swafXAYf
and the ATM will happily send back the exchange rate.
This sounds awesome. I'm going to try this when I get some more time! Hopefully sometime in March.
Congratulations @gstefans! You have received a personal award!
2 Years on Steemit
Click on the badge to view your Board of Honor.