Skip to content

Commit

Permalink
Added PLNcoin (block explorer as dummy)
Browse files Browse the repository at this point in the history
  • Loading branch information
Rav3nPL committed Jan 28, 2015
1 parent ef633f7 commit 03adbcc
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 0 deletions.
30 changes: 30 additions & 0 deletions p2pool/bitcoin/networks/plncoin.py
@@ -0,0 +1,30 @@
import os
import platform

from twisted.internet import defer

from .. import data, helper
from p2pool.util import pack


P2P_PREFIX = 'fbc0b6db'.decode('hex') #pchmessagestart
P2P_PORT = 9334
ADDRESS_VERSION = 22 #pubkey_address
RPC_PORT = 9331
RPC_CHECK = defer.inlineCallbacks(lambda bitcoind: defer.returnValue(
'plncoinaddress' in (yield bitcoind.rpc_help()) and
not (yield bitcoind.rpc_getinfo())['testnet']
))
SUBSIDY_FUNC = lambda height: 44*100000000 >> (height + 1)//438000
POW_FUNC = lambda data: pack.IntType(256).unpack(__import__('ltc_scrypt').getPoWHash(data))
BLOCK_PERIOD = 60 # seconds
SYMBOL = 'PLNc'
CONF_FILE_FUNC = lambda: os.path.join(os.path.join(os.environ['APPDATA'], 'PlnCoin')
if platform.system() == 'Windows' else os.path.expanduser('~/Library/Application Support/PlnCoin/')
if platform.system() == 'Darwin' else os.path.expanduser('~/.plncoin'), 'plncoin.conf')
BLOCK_EXPLORER_URL_PREFIX = 'http://altexplorer.net/block/'
ADDRESS_EXPLORER_URL_PREFIX = 'http://altexplorer.net/address/'
TX_EXPLORER_URL_PREFIX = 'http://altexplorer.net/tx/'
SANE_TARGET_RANGE = (2**256//1000000000 - 1, 2**256//1000 - 1)
DUMB_SCRYPT_DIFF = 2**16
DUST_THRESHOLD = 0.03e8
18 changes: 18 additions & 0 deletions p2pool/networks/plncoin.py
@@ -0,0 +1,18 @@
from p2pool.bitcoin import networks

PARENT = networks.nets['plncoin']
SHARE_PERIOD = 20 # seconds
CHAIN_LENGTH = 12*60*60//20 # shares
REAL_CHAIN_LENGTH = 12*60*60//20 # shares
TARGET_LOOKBEHIND = 20 # shares
SPREAD = 10 # blocks
IDENTIFIER = 'ffdd0a3ba17e00a1'.decode('hex')
PREFIX = 'ee3b819a0133e7fa'.decode('hex')
P2P_PORT = 7133
MIN_TARGET = 0
MAX_TARGET = 2**256//2**20 - 1
PERSIST = False
WORKER_PORT = 9133
BOOTSTRAP_ADDRS = 'rav3n.dtdns.net'.split(' ')
ANNOUNCE_CHANNEL = '#p2pool-alt'
VERSION_CHECK = lambda v: True

0 comments on commit 03adbcc

Please sign in to comment.