Bitcoin Forum
January 15, 2021, 08:19:01 PM *
News: Latest Bitcoin Core release: 0.20.1 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 ... 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 [1153] 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 ... 2098 »
  Print  
Author Topic: [XMR] Monero - A secure, private, untraceable cryptocurrency  (Read 4641257 times)
Miki
Member
**
Offline Offline

Activity: 70
Merit: 10


View Profile
April 16, 2015, 12:49:48 PM
 #23041


I have noticed that too. Apparently there are wrong calculations...Which pool do you guys consider to be the best one right now?

Best pool by far is monero.crypto-pool.fr.

No one denies that's the largest pool, but largest doesn't mean best. On smaller pools your payments will be less frequent, but bigger. On the long run you should be getting more or less the same amount of XMR from each pool (it's also been said that you would be getting a little more from smaller pools, but I don't have the theory to back it up). But most importantly, if you avoid largest pools you will be helping to the decentralization by spreading the network's hash power.

You should look for a good pool with low latency in your location. Just make sure to ping the mining server address and not the web server, as they may not be in the same location. Also, if your mining software supports it, you should add a backup pool just in case your main pool becomes unavailable.

Avoid small pools , difficulty oscillates by 10-30% during the day, if you mine at a small pool and it hits no blocks during the low diff period than you are at a loss.

And if it does hit a block during a low-dificulty period you get a bit extra. Over several days it largely balances out.

Quote
Mine at a pool that hits a block every 10-15mins

A few blocks per day is plenty imo. The most important factor for a pool is reliability and that you have low latency. Bigger payouts is helpful because it will reduce your transaction fees when you try to spend.

One suggestion I remember from a while back that was pretty good is to mine in such a way that you get part of at least 50 blocks. That depends not only on the pool hash rate (or your own hash rate if solo mining) but also your time horizon.



Wrong. The difficulty keeps increasing, you don't get a second chance when you don't hit a block during the low-diff period.
1610741941
Hero Member
*
Offline Offline

Posts: 1610741941

View Profile Personal Message (Offline)

Ignore
1610741941
Reply with quote  #2

1610741941
Report to moderator
1610741941
Hero Member
*
Offline Offline

Posts: 1610741941

View Profile Personal Message (Offline)

Ignore
1610741941
Reply with quote  #2

1610741941
Report to moderator
1610741941
Hero Member
*
Offline Offline

Posts: 1610741941

View Profile Personal Message (Offline)

Ignore
1610741941
Reply with quote  #2

1610741941
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1610741941
Hero Member
*
Offline Offline

Posts: 1610741941

View Profile Personal Message (Offline)

Ignore
1610741941
Reply with quote  #2

1610741941
Report to moderator
1610741941
Hero Member
*
Offline Offline

Posts: 1610741941

View Profile Personal Message (Offline)

Ignore
1610741941
Reply with quote  #2

1610741941
Report to moderator
elrippo
Legendary
*
Offline Offline

Activity: 1008
Merit: 1001


View Profile
April 16, 2015, 01:15:40 PM
 #23042

Hy guys  Cheesy

now one can read the thread again without any DASH/DRK involved  Grin
Thank you guys, keep on going, i am counting on you  Shocked Cool

For Advertisement. PM me to discuss.
GreekBitcoin
Legendary
*
Offline Offline

Activity: 1428
Merit: 1001


getmonero.org


View Profile WWW
April 16, 2015, 02:39:17 PM
 #23043

Monero Status
A friend of mine made an android widget and app.





App and Widget for the Monero cryptocurrency, with stats from all exchanges.
Google Store: https://play.google.com/store/apps/details?id=tr.monerostatus

----------------------------------------------------------------

Simple widget and app for the Monero(XMR) cryptocurrency

----------------------------------------------------------------

Supported exchanges: poloniex.com, bittrex.com, bter.com, hitbtc.com, melotic.com, shapeshift.io
Supported fiat currencies: AUD, BRL, CAD, CHF, CNY, EUR, GBP, IDR, ILS, MXN, NOK, NZD, PLN, RON, RUB, SEK, SGD, USD and ZAR

Monero Widget features (both in 2x1 and 2x2 formats):
•30 minute fixed refresh rate, tap refresh sign to instantly refresh
•Tap Monero logo to launch App in the chosen currency
•Price in BTC from chosen exchange, color coded for recent change
•Price in chosed currency from coinmarketcap.com
•24 hour total volume  in chosed currency from coinmarketcap.com
•Approximate hashrate in Mh/s from moneroblocks.eu

Monero Widget features (only in 2x2):
•Calculated price for your XMR assets
•Calculated mined value per day from your hashrate
•Market capitalization in the chosen currency
 
App features:
•All the widget information and capabilities
•Left side drawer for navigation (Swipe right from the side or press app icon to open)
•Trial fullscreen button, please report bugs
•Tap the refresh icon to refresh, long press to enter continuous refresh mode; exit by tapping again
•Exchange specific 24 hour volume from chosen exchange
•Total market capitalization, 24 hour percentage change and ranking from coinmarketcap.com
•Total coins in existence, block height and difficulty from moneroblocks.eu
•Calculate prices for your amount of XMR
•Calculate XMR mined per day and their value for your hashrate
•Market-Order Depth graph drawing data from all enabled exchanges, plus their total (combined) market depth
•XMR markets for other cryptocurrencies by exchanges that offer them
•Enable the exchanges you want in the graph by tapping on their names in the drawer
•Change the graph's viewed range with pinch in/pinch out gestures

Coinmarketcap data retrieved through http://coinmarketcap.northpole.ro/ JSON API

Using the GraphView library from http://android-graphview.org/ , licenced under the LGPL

Donations welcome Smiley Many thanks to those that have already donated!
Code:
41pUDMUG956cAc8DAkMekSZ9ThrKbicVTRZbnjs7K2zjTf4ue1UrGcN7D9BLX39uh2RPVeQaZEP2H91XBvqRJJJYUmQKXjM
----------------------------------------------------------------

Updates
•Changed to moneroblocks.eu from chainradar.com (chainradar has a pretty restrictive api usage limit)
•Added Shapeshift.io as an exchange (one can see it that way Tongue)
•Added Ramer–Douglas–Peucker smoothing to the market depth graph, dependant on zoom level
•Unexpected bug fixes!

And please make feature requests or tell us about bugs! It really helps!
(This update should have fixed some user's problems. If not please contact us!)
GingerAle
Legendary
*
Offline Offline

Activity: 1246
Merit: 1008


View Profile WWW
April 16, 2015, 04:05:52 PM
 #23044

So once the database is released for all to enjoy (which is so soon its about to fall off the branch - fruit/github pun!!!) what're we going to start clamoring for / working on next?

(And don't say GUI)

And also, I'm wondering what everyone's take is on the following - and I preface this by saying that by no means am I critical of anything that people do - indeed, this is all volunteer and free time open source yada yada yada. This is just an observation, and I wonder what it means, and whether we should facilitate some type of change.

In the recent past, there have been 2 successful community fundraising efforts - significant amount of money raised in both.
Both efforts are for great developments - obviously the monero space will be better when these things are created.
In the meanwhile, however, core development is needed and there is a laundry list of items that need attention - some are advances in the core, whereas some are even just bug fixes.

Why can't we just raise funds for these items, in a similar way that funds were raised for the above 2 items?

But in the meantime, whats stopping us from fundraising for any item on the Monero core's todo list?

As far as I can tell here are the current issues, but if a core-dev can point to a better list, by all means:
https://github.com/monero-project/bitmonero/issues

and here are the design and development goals:
http://getmonero.org/design-goals/


So anyone could be like "I'm going to fix issue #240 if I raise 150 XMR"

or "I'm going to get smartmining working if I raise 500 XMR"

I realized the design and development goals should be numbered (itemized) for easy reference, but my lunch break is over.... so must get back to USD-paying work.

But yeah - here's the monero forums "funding needed" section. https://forum.getmonero.org/8/funding-required


< Track your bitcoins! > < Track them again! > <<< [url=https://www.reddit.com/r/Bitcoin/comments/1qomqt/what_a_landmark_legal_case_from_mid1700s_scotland/] What is fungibility? >>> 46P88uZ4edEgsk7iKQUGu2FUDYcdHm2HtLFiGLp1inG4e4f9PTb4mbHWYWFZGYUeQidJ8hFym2WUmWc p34X8HHmFS2LXJkf <<< Free subdomains at moneroworld.com!! >>> <<< If you don't want to run your own node, point your wallet to node.moneroworld.com, and get connected to a random node! @@@@ FUCK ALL THE PROFITEERS! PROOF OF WORK OR ITS A SCAM !!! @@@@
nakaone
Hero Member
*****
Offline Offline

Activity: 742
Merit: 500


View Profile
April 16, 2015, 04:23:47 PM
 #23045


Why can't we just raise funds for these items, in a similar way that funds were raised for the above 2 items?


well partly due to some game-theoretic problems and freeridinng and partly due to the reason that someone has to step up and organize the stuff.

If you manage to organize all the stuff let me know and I send you 20xmr Wink
dEBRUYNE
Legendary
*
Offline Offline

Activity: 2212
Merit: 1139


View Profile
April 16, 2015, 04:39:17 PM
 #23046


Why can't we just raise funds for these items, in a similar way that funds were raised for the above 2 items?


well partly due to some game-theoretic problems and freeridinng and partly due to the reason that someone has to step up and organize the stuff.

If you manage to organize all the stuff let me know and I send you 20xmr Wink

I would be happy to donate as well and it seems like a great incentive. Aligning it with Monero's birthday would be great too. However, there are some implications, some design goals have lot of interdependency (or are worked on together), so it's hard to set them out apart (I guess fluffypony could give a more extensive argument on this one).

PS: There is already a system in place for this. I don't know when it's going live though, but it will probably be after all the DB work is finished.

you guys are always pointing out how the project is basically unfunded and you do great work under those conditions no doubt. but i just want to do what i can to help with this situation for 2 reasons, for the good of monero, but also because you guys should be compensated for the work you do. and the thing is, i just dont think that panhandling is ever going to get you the sort of consistent and appropriate compensation you should be getting, and monero should be getting.

We've been working on adding some needed functionality to the forum, and our next major task we're going to tackle is the funding system. The idea is:

1. Users / developers / anyone will pitch an idea in the Ideas section of the forum. This is already happening.

2. After some discussion it will be moved by one of the administrators (currently the Core Team only, but that would change in future) to the Open Tasks section of the forum. No tasks have been moved as yet.

3. Developers (including the core team, and initially probably only the core team for simplicity) will pitch against each of these open tasks. Later on I would expect that there would be more people / teams pitching against tasks, and the most competent / available / reasonably priced will be the one the community will veer towards.

4. Once the developer / team has been selected to complete the task it moves to the Funding Required section of the forum, and it is opened for funding.

5. Funding will be to a core team controlled address with a payment ID for that particular project/task, and there will be a funding progress bar. This information will be mirrored over to a funding page on the website that shows the funding progress per project/task.

6. When funding reaches 70% (for smaller tasks) or 30% (for larger and longer tasks) it goes into the Work in Progress section and work begins.

7. Funds are dispensed by the core team on a regular basis and only if there is actual progress / commits / whatever, so it doesn't go into a black hole.

Advantages of this approach:

- the core team's oversight role can eventually be replaced by a group selected from the community at large, so as not to have a stranglehold over things

- the core team's escrow role can eventually be replaced by a multi-sig system (2-of-3) where the signatories are the core team, the oversight group, and the recipient, so the recipient can't spend those raised funds without the involvement of one of the other 2 signatories

- this isn't limited to dev tasks, and things like "fly David Latapie to speak at a conference" or lobbying or PR or advertising can all have tasks created and funded

- funding is direct and specific to tasks instead of going into a big black hole and hoping for the best

We expect this system will still take us another short while before we can put it live, but we're already crunching away at the functionality for it (and this also further emphasises why the forum couldn't just be SMF with a theme;) )

I personally hope this will be the way to go in the future, since it just gives so much more incentive to donate if you can donate to a specific "thing" you would like to see developed. Most people hesitate to donate, because it's currently more or less a blackbox to which you donate (no offence to the devs, but I think a system described above (by fluffypony and by GingerAle) would have a much bigger utility).

Privacy matters, use Monero - A true untraceable cryptocurrency
Why Monero matters? http://weuse.cash/2016/03/05/bitcoiners-hedge-your-position/
GingerAle
Legendary
*
Offline Offline

Activity: 1246
Merit: 1008


View Profile WWW
April 16, 2015, 04:45:27 PM
 #23047


Why can't we just raise funds for these items, in a similar way that funds were raised for the above 2 items?


well partly due to some game-theoretic problems and freeridinng and partly due to the reason that someone has to step up and organize the stuff.

If you manage to organize all the stuff let me know and I send you 20xmr Wink

I would be happy to donate as well and it seems like a great incentive. Aligning it with Monero's birthday would be great too. However, there are some implications, some design goals have lot of interdependency (or are worked on together), so it's hard to set them out apart (I guess fluffypony could give a more extensive argument on this one).

PS: There is already a system in place for this. I don't know when it's going live though, but it will probably be after all the DB work is finished.

you guys are always pointing out how the project is basically unfunded and you do great work under those conditions no doubt. but i just want to do what i can to help with this situation for 2 reasons, for the good of monero, but also because you guys should be compensated for the work you do. and the thing is, i just dont think that panhandling is ever going to get you the sort of consistent and appropriate compensation you should be getting, and monero should be getting.

We've been working on adding some needed functionality to the forum, and our next major task we're going to tackle is the funding system. The idea is:

1. Users / developers / anyone will pitch an idea in the Ideas section of the forum. This is already happening.

2. After some discussion it will be moved by one of the administrators (currently the Core Team only, but that would change in future) to the Open Tasks section of the forum. No tasks have been moved as yet.

3. Developers (including the core team, and initially probably only the core team for simplicity) will pitch against each of these open tasks. Later on I would expect that there would be more people / teams pitching against tasks, and the most competent / available / reasonably priced will be the one the community will veer towards.

4. Once the developer / team has been selected to complete the task it moves to the Funding Required section of the forum, and it is opened for funding.

5. Funding will be to a core team controlled address with a payment ID for that particular project/task, and there will be a funding progress bar. This information will be mirrored over to a funding page on the website that shows the funding progress per project/task.

6. When funding reaches 70% (for smaller tasks) or 30% (for larger and longer tasks) it goes into the Work in Progress section and work begins.

7. Funds are dispensed by the core team on a regular basis and only if there is actual progress / commits / whatever, so it doesn't go into a black hole.

Advantages of this approach:

- the core team's oversight role can eventually be replaced by a group selected from the community at large, so as not to have a stranglehold over things

- the core team's escrow role can eventually be replaced by a multi-sig system (2-of-3) where the signatories are the core team, the oversight group, and the recipient, so the recipient can't spend those raised funds without the involvement of one of the other 2 signatories

- this isn't limited to dev tasks, and things like "fly David Latapie to speak at a conference" or lobbying or PR or advertising can all have tasks created and funded

- funding is direct and specific to tasks instead of going into a big black hole and hoping for the best

We expect this system will still take us another short while before we can put it live, but we're already crunching away at the functionality for it (and this also further emphasises why the forum couldn't just be SMF with a theme;) )

I personally hope this will be the way to go in the future, since it just gives so much more incentive to donate if you can donate to a specific "thing" you would like to see developed. Most people hesitate to donate, because it's currently more or less a blackbox to which you donate (no offence to the devs, but I think a system described above (by fluffypony and by GingerAle) would have a much bigger utility).

Yeah, I realized after posting that there is something in the works for this - I just didn't know if what currently on the monero forum (there are 3 threads - funding required, something, and something) is the actual implementation of this or not. If so - it already exists, and we can start DOING THIS. There's no need to wait. Itshappening.gif

< Track your bitcoins! > < Track them again! > <<< [url=https://www.reddit.com/r/Bitcoin/comments/1qomqt/what_a_landmark_legal_case_from_mid1700s_scotland/] What is fungibility? >>> 46P88uZ4edEgsk7iKQUGu2FUDYcdHm2HtLFiGLp1inG4e4f9PTb4mbHWYWFZGYUeQidJ8hFym2WUmWc p34X8HHmFS2LXJkf <<< Free subdomains at moneroworld.com!! >>> <<< If you don't want to run your own node, point your wallet to node.moneroworld.com, and get connected to a random node! @@@@ FUCK ALL THE PROFITEERS! PROOF OF WORK OR ITS A SCAM !!! @@@@
papa_lazzarou
Hero Member
*****
Offline Offline

Activity: 650
Merit: 500


moneroblocks.info


View Profile
April 16, 2015, 05:01:36 PM
 #23048

So once the database is released for all to enjoy (which is so soon its about to fall off the branch - fruit/github pun!!!) what're we going to start clamoring for / working on next?


As dEBRUYNE mentioned, I think the task/bounty system on the forum should be next in our clamoring list.

it's the GUI Tongue

We are the knights who say GUI!

|| Monero Blocks - The Monero Block Explorerdonate.moneroblocks.info ||
TheKoziTwo
Legendary
*
Offline Offline

Activity: 1551
Merit: 1029



View Profile
April 16, 2015, 07:40:08 PM
 #23049

XMR Integration / DEMO

Finally done with this script. Grin The idea is to make it easier for people to setup their own monero accepting website. A working demo can help with that!

This is a complete PHP integration of monero. Once setup you will have a working membership site with:

  • Login/Registration
  • Generation of payment id
  • Deposit of funds (automatically added to account after X confirmations)
  • Withdraw of funds (added to processing queue and processed automatically)
  • Admin Panel displaying current balances and other useful info (e.g status of daemon and wallet)
  • With some minor changes, you can add multiple cryptonote types of currencies/assets
  • The script comes with cron.php, which is the processing script. It can be setup to run forever in the background, or even as a cron job. Read the comment in cron.php for more info.

For install instructions simply open install.php

Download here: https://github.com/TheKoziTwo/xmr-integration

Step by step install (install.php):


Login/Registration:


Account area:


Admin area:


There is no guide for how to setup daemon and simplewallet in "server mode". I have been working on a guide as well, but it's not posted anywhere yet, so I'll put some quick guidelines below:
Quote
Introduction

With bitcoin, transactions are identified with a unique address. Monero uses payment id instead to identify transactions. This means that your XMR receiving address will be the same for all users, but payment_id will be unique. Users transferring money to your site need to specify both address and payment id

Setting up server

Bitcoin has both wallet and daemon in one and the same software. Monero has split these into two separate applications. You have bitmonerod which is the daemon and simplewallet which is the wallet. This requires us to connect to two different services.

Daemon (localhost:18081/rpc/)

You need to launch daemon in server mode, to do so run it with:
Code:
./bitmonerod --rpc-bind-ip 127.0.0.1 --rpc-bind-port 18081

Thats all. Once you have a daemon running, you can connect to it from one or even multiple wallets.

Wallet (localhost:18082/rpc/)
First of all create a wallet as usual (if you have not already done so):

Code:
simplewallet --generate-new-wallet mywallet.dat

Enter a password (demo123), you don’t need to write down the seed, but you may.

exit the wallet.

In order to perform operations usings the API, the wallet must run in rpc server mode, to do so, run it with the following param (make sure the daemon is already running first):

Code:
./simplewallet --wallet-file mywallet.dat --password demo123 --rpc-bind-port 18082

Another example, if you have bound the daemon to an IP/PORT and also wants to bind the simplewallet, this example below shows how:
Code:
./simplewallet --daemon-host 192.168.10.54 --daemon-port 18081 --wallet-file mywallet.dat --rpc-bind-ip 192.168.10.54 --rpc-bind-port 18082 --password demo123

Now you should be able to access the wallet outside of your localhost also.

IMPORTANT: When wallet is running in RPC mode it’s technically possible for hackers to empty your wallet if your port is open. You don’t want that, so make sure 18082 is closed.

cryptonight.net
Newbie
*
Offline Offline

Activity: 28
Merit: 0


View Profile WWW
April 16, 2015, 07:44:11 PM
 #23050

XMR Integration / DEMO

Finally done with this script. Grin The idea is to make it easier for people to setup their own monero accepting website. A working demo can help with that!

This is a complete PHP integration of monero. Once setup you will have a working membership site with:


This is very important step! Thank you!
Worthy of dedicated topic.

Is this suitable to create a Monero-accepting shop?
TheKoziTwo
Legendary
*
Offline Offline

Activity: 1551
Merit: 1029



View Profile
April 16, 2015, 07:46:23 PM
 #23051

XMR Integration / DEMO

Finally done with this script. Grin The idea is to make it easier for people to setup their own monero accepting website. A working demo can help with that!

This is a complete PHP integration of monero. Once setup you will have a working membership site with:


This is very important step! Thank you!

Is this suitable to create a Monero-accepting shop?
There is no purchase item feature, only account funding. But the principle of processing payments works the same way, so it shouldn't be very hard to implement if you want that.

Jojatekok
Sr. Member
****
Offline Offline

Activity: 264
Merit: 250


View Profile
April 16, 2015, 07:47:36 PM
 #23052

XMR Integration / DEMO

Finally done with this script. Grin The idea is to make it easier for people to setup their own monero accepting website. A working demo can help with that!

This is a complete PHP integration of monero. Once setup you will have a working membership site with:

  • Login/Registration
  • Generation of payment id
  • Deposit of funds (automatically added to account after X confirmations)
  • Withdraw of funds (added to processing queue and processed automatically)
  • Admin Panel displaying current balances and other useful info (e.g status of daemon and wallet)
  • With some minor changes, you can add multiple cryptonote types of currencies/assets
  • The script comes with cron.php, which is the processing script. It can be setup to run forever in the background, or even as a cron job. Read the comment in cron.php for more info.

For install instructions simply open install.php

Download here: https://github.com/TheKoziTwo/xmr-integration

Step by step install (install.php):


Login/Registration:


Account area:


Admin area:


There is no guide for how to setup daemon and simplewallet in "server mode". I have been working on a guide as well, but it's not posted anywhere yet, so I'll put some quick guidelines below:
Quote
Introduction

With bitcoin, transactions are identified with a unique address. Monero uses payment id instead to identify transactions. This means that your XMR receiving address will be the same for all users, but payment_id will be unique. Users transferring money to your site need to specify both address and payment id

Setting up server

Bitcoin has both wallet and daemon in one and the same software. Monero has split these into two separate applications. You have bitmonerod which is the daemon and simplewallet which is the wallet. This requires us to connect to two different services.

Daemon (localhost:18081/rpc/)

You need to launch daemon in server mode, to do so run it with:
Code:
./bitmonerod --rpc-bind-ip 127.0.0.1 --rpc-bind-port 18081

Thats all. Once you have a daemon running, you can connect to it from one or even multiple wallets.

Wallet (localhost:18082/rpc/)
First of all create a wallet as usual (if you have not already done so):

Code:
simplewallet --generate-new-wallet mywallet.dat

Enter a password (demo123), you don’t need to write down the seed, but you may.

exit the wallet.

In order to perform operations usings the API, the wallet must run in rpc server mode, to do so, run it with the following param (make sure the daemon is already running first):

Code:
./simplewallet --wallet-file mywallet.dat --password demo123 --rpc-bind-port 18082

Another example, if you have bound the daemon to an IP/PORT and also wants to bind the simplewallet, this example below shows how:
Code:
./simplewallet --daemon-host 192.168.10.54 --daemon-port 18081 --wallet-file mywallet.dat --rpc-bind-ip 192.168.10.54 --rpc-bind-port 18082 --password demo123

Now you should be able to access the wallet outside of your localhost also.

IMPORTANT: When wallet is running in RPC mode it’s technically possible for hackers to empty your wallet if your port is open. You don’t want that, so make sure 18082 is closed.


Incredible news! Hopefully I'll be able to seek through your TX date retrieval mechanism, thus, I'd be able to implement that functionality into Monero API .NET, and then MoneroX.

Code:
Monero  (XMR): 47hK4gehaMrFTQCiV5FEmM54hpqTrdHudb9nUBG88NicBDpxH4TGuh3TmW84Dc6dpMiEiBLGvJCuT3xC3LNHctmx7mG8NLM
Bitcoin (BTC): 14wHehBtFt321WTV15khon8Juaxh9drnfJ
cryptonight.net
Newbie
*
Offline Offline

Activity: 28
Merit: 0


View Profile WWW
April 16, 2015, 07:52:27 PM
 #23053

XMR Integration / DEMO

Finally done with this script. Grin The idea is to make it easier for people to setup their own monero accepting website. A working demo can help with that!

This is a complete PHP integration of monero. Once setup you will have a working membership site with:


This is very important step! Thank you!

Is this suitable to create a Monero-accepting shop?
There is no purchase item feature, only account funding. But the principle of processing payments works the same way, so it shouldn't be very hard to implement if you want that.

I don't plan to sell anything right now. I assume that the store - the most important use case.
TheKoziTwo
Legendary
*
Offline Offline

Activity: 1551
Merit: 1029



View Profile
April 16, 2015, 07:59:08 PM
 #23054

Some may wonder why the integration is using bcmath, my explaination below:

Float, Decimal, Integer ? Mathematics in PHP & MySQL

Floating point numbers are not accurate and should never be used for financial transactions.

A few examples of this:

Code:
$a = '35';
$b = '-34.99';
echo ($a + $b);

Results in 0.009999999999998 instead of 0.01

Code:
echo floor((0.1+0.7)*10);

Results in 7 instead of the expected answer 8

So we’re not able to use PHPs native operators for math calculations with decimals since those are treated as floats.

Then we have integer. A much more suited choice for financial transactions. One thing to keep in mind if choosing integer is the php limits. Those are for 32-bit build of PHP limited to integers in the range of -2147483648 to 2147483647 while 64-bit -9 223 372 036 854 775 808 to 9 223 372 036 854 775 807

Imagine you have 100k XMR. Since monero has up to 12 decimals, to store 1 monero we need a number like this: 10^12 = 1 000 000 000 000

That’s more than a 32-bit build can handle right there.

To store 100k XMR we would store:100000 * (10^12) = 100 000 000 000 000 000

Let’s compare:
Code:
9 223 372 036 854 775 807 (64-bit limit)
  100 000 000 000 000 000 (100k XMR)

Well, it’s still within the range, but if we increase it to 10 million XMR not even 64-bit can handle it.

Satoshi Nakamoto was pretty smart, he knew this. That’s probably why the limit is 21 million BTC. 1 Satoshi is the lowest unit of bitcoin, and 1 BTC = 100 000 000 Satoshi. Not only did he get it within the maximum integer value that can be stored. He also got it within the limit of floating point numbers, useful for languages like javascript, but that’s another story (you can read more here)

21 000 000 * 100,000,000 = 2100000000000000

Comparing again:
Code:
9223372036854775807 (64-bit limit)
         2147483647 (32-bit limit)
   2100000000000000 (Max BTC)

As we can see, bitcoin fit’s within these ranges.

We want our application to be scalable, there is always a good chance we’re going to want to add another currency with it’s own unique rules at one point.

So monero cannot ultimately be stored as integer if we intend to preserve all the decimals. We could reduce the decimals to 8 like bitcoin. That will take care of it. But there is one unexplored alternative I’d like to present first: decimals and arbitrary precision math.

If you enable an extension for PHP called “bcmath” you will be able to go beyond the limits of your system. With arbitrary precision mathematics you’ll have a binary calculator which supports numbers of any size and precision represented as strings.

By using BCMath, we can do calculations and know with certainty that the numbers are 100% correct at all times, with every single satoshi accounted for.

Not only that, but we get to store numbers like they are supposed to be stored in database. Just like they look. By using MySQL DECIMAL, we can store the smallest unit of monero as:

0.000000000001.

Let us repeat the examples we did for float with bcmath:

Code:
$a = '35';
$b = '-34.99';
echo bcadd($a,$b);

Results in 0.01

Code:
echo bc::floor(bcmul(bcadd('0.1','0.7'),'10'));

Results in 8

Large numbers is no problem at all, let us multiply the 64-bit max limit by itself:

Code:
echo bcmul('9223372036854775807','9223372036854775807');

Results in 85070591730234615847396907784232501249

Check for yourself (if you can even find a calculator doing that! hint: Wolfram Alpha)

Similarly small amounts:
Code:
echo bcmul('0.000000000001','0.000000000001');

0.000000000000000000000001

But before you do that, make sure to set bcscale() to something high enough.

The script comes with a wrapper class for bc math, this will make it a tad easier to work with.

As for downsides to using bcmath:

  • You need to have the bcmath extension (very easy to install, WHM/cPanel servers has it as a tick box)
  • Not as fancy using functions to do operations as using + - * /, e.g bcadd(1,2) instead of 1+2
  • Some functions available for php that is not integrated in bcmath, example is the php function “floor”, however there are re-implementations for this (I have included some in the wrapper)
  • A bit slower…  (But no big deal!)

So all calculations in the script are done using bcmath, the numbers are treated like strings and stored as decimals in the database. Only when we transfer money out do we convert to integer, and we do that outside of php as well (in json, with parameter JSON_NUMERIC_CHECK)


papa_lazzarou
Hero Member
*****
Offline Offline

Activity: 650
Merit: 500


moneroblocks.info


View Profile
April 16, 2015, 08:30:01 PM
 #23055

XMR Integration / DEMO

Finally done with this script. Grin The idea is to make it easier for people to setup their own monero accepting website. A working demo can help with that!

This is a complete PHP integration of monero. Once setup you will have a working membership site with:


Great job. Thanks.

So many goodies lately, I feel like we're getting spoiled.

|| Monero Blocks - The Monero Block Explorerdonate.moneroblocks.info ||
smooth
Legendary
*
Offline Offline

Activity: 2604
Merit: 1167



View Profile
April 16, 2015, 09:04:21 PM
Last edit: April 17, 2015, 12:30:04 AM by smooth
 #23056

So monero cannot ultimately be stored as integer if we intend to preserve all the decimals. We could reduce the decimals to 8 like bitcoin. That will take care of it. But there is one unexplored alternative I’d like to present first: decimals and arbitrary precision math.

Monero can be stored in a 64 bit unsigned integer. The total money supply has to fit in a 64 bit unsigned integer currently (as required by the base reward formula). This will be true until some time after the tail reward kicks in (roughly eight years). Even then, the amount allowed for any single transaction will still be constrained by a 64 bit unsigned integer.

Some languages don't natively support unsigned integers. It is possible to use signed integers as unsigned, but error prone. Operations such as addition work fine, but I/O, division, comparisons (and a few other operations) require some extra processing.

There is certainly nothing wrong with using string-based numbers for accounting though. That probably the most reliable approach, and suitable for nearly all cases where performance and a possible space penalty don't matter.

Very nice work on the integration utility. Congratulations on the release!
fluffypony
Donator
Legendary
*
Offline Offline

Activity: 1274
Merit: 1057


GetMonero.org / MyMonero.com


View Profile WWW
April 16, 2015, 09:05:50 PM
 #23057

Updated: https://forum.getmonero.org/14/events/237/monero-meetup-berlin-germany-may-24th-2015

This is confirmed for Sunday, May 24th, 2015. We have the venue from 4pm - 7pm, and we will start promptly at 5pm.

A venue has been kindly provided for us by Thoughtworks at Werkstatt Berlin -

Mülhauser Str. 6. Hofgebäude 1. OG
10405 Berlin
Germany

Afterwards we will move to the Metzer Eck (an old-school Berliner pub) for fresh beer and good conversation.

Hueristic
Legendary
*
Offline Offline

Activity: 2604
Merit: 1890


Doomed to see the future and unable to prevent it


View Profile
April 16, 2015, 09:31:48 PM
 #23058

So once the database is released for all to enjoy (which is so soon its about to fall off the branch - fruit/github pun!!!) what're we going to start clamoring for / working on next? ...


Do to the dependencies what we need is a hierarchy branch structure of the development schedule. This would make the Teams goals much easier to understand for the layman. Visual representation is so much easier to point out than reiterating lists.

“Bad men need nothing more to compass their ends, than that good men should look on and do nothing.”
rpietila
Donator
Legendary
*
Offline Offline

Activity: 1722
Merit: 1016



View Profile
April 16, 2015, 09:45:47 PM
 #23059

Updated: https://forum.getmonero.org/14/events/237/monero-meetup-berlin-germany-may-24th-2015

This is confirmed for Sunday, May 24th, 2015. We have the venue from 4pm - 7pm, and we will start promptly at 5pm.

A venue has been kindly provided for us by Thoughtworks at Werkstatt Berlin -

Mülhauser Str. 6. Hofgebäude 1. OG
10405 Berlin
Germany

Afterwards we will move to the Metzer Eck (an old-school Berliner pub) for fresh beer and good conversation.

Berlin is close enough that the royal retinue might be seen there.

HIM TVA Dragon, AOK-GM, Emperor of the Earth, Creator of the World, King of Crypto Kingdom, Lord of Malla, AOD-GEN, SA-GEN5, Ministry of Plenty (Join NOW!), Professor of Economics and Theology, Ph.D, AM, Chairman, Treasurer, Founder, CEO, 3*MG-2, 82*OHK, NKP, WTF, FFF, etc(x3)
dEBRUYNE
Legendary
*
Offline Offline

Activity: 2212
Merit: 1139


View Profile
April 16, 2015, 10:16:11 PM
 #23060

So once the database is released for all to enjoy (which is so soon its about to fall off the branch - fruit/github pun!!!) what're we going to start clamoring for / working on next? ...


Do to the dependencies what we need is a hierarchy branch structure of the development schedule. This would make the Teams goals much easier to understand for the layman. Visual representation is so much easier to point out than reiterating lists.

Something like a flowchart with arrows would be great for this in my opinion.

EDIT: The flowchart could also be updated with people who are working on it, that would make communicating a lot easier and the work will probably go a lot faster.

Privacy matters, use Monero - A true untraceable cryptocurrency
Why Monero matters? http://weuse.cash/2016/03/05/bitcoiners-hedge-your-position/
Pages: « 1 ... 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 [1153] 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 ... 2098 »
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!