Bitcoin Forum
April 26, 2024, 02:29:04 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1] 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 »  All
  Print  
Author Topic: Modular Python Bitcoin Miner - Official Thread  (Read 73923 times)
TheSeven (OP)
Hero Member
*****
Offline Offline

Activity: 504
Merit: 500


FPGA Mining LLC


View Profile WWW
February 06, 2012, 04:10:15 PM
Last edit: March 26, 2012, 01:19:53 PM by TheSeven
 #1

    Modular Python Bitcoin Miner


    The Modular Python Bitcoin Miner is a very flexible mining software written in Python, aiming to unify the frontend of FPGA-based mining hardware.


    Features

    • Runs on Python 2.6+ / 3.0+
    • Very flexible, to allow for all kinds of weird mining hardware and future mining pool protocols
    • Multi-pool support (load balancing or failover, configurable)
    • Multi-worker support
    • Worker hotplug support
    • Web interface
    • All UI functions available through JSON API
    • Can easily handle clusters of tens of gigahashes, dependinding on the board type


    Supported devices

    • Simple RS232-based interface, as a starting point for interface developers
    • X6500 FPGA mining board (no need for D2XX driver!)
    • Icarus board
    • ZTEX boards
    • Butterfly Labs (BFL) BitFORCE Single
    • ...more to follow!
    • Feel free to implement your own one!
    • Board vendors: Contact TheSeven with an offer (e.g. a board for testing) if you want your board to be added!


    Screenshots




    News

    • 2012-03-26: v0.1.0beta released
    • 2012-03-22: Testing branch almost ready to be released for production use
    • 2012-03-21: Added ztex board support to testing branch
    • 2012-02-09: Added experimental support for Icarus board
    • 2012-02-06: Initial public beta release (v0.0.4beta)


    Documentation / Howtos

    • Coming soon...


    Download / Source code



    IRC channel



    Donations

    • Donations to 13NuRX6rdE4Do4vddzhfKK7FqmGSTMcjYh are gratefully accepted Grin
    • Or, even better, donate a small share of your mining power to the MPBM authors by leaving the demo pool entries in the default configuration file enabled



    [/list]

    My tip jar: 13kwqR7B4WcSAJCYJH1eXQcxG5vVUwKAqY
    You get merit points when someone likes your post enough to give you some. And for every 2 merit points you receive, you can send 1 merit point to someone else!
    Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
    1714098544
    Hero Member
    *
    Offline Offline

    Posts: 1714098544

    View Profile Personal Message (Offline)

    Ignore
    1714098544
    Reply with quote  #2

    1714098544
    Report to moderator
    1714098544
    Hero Member
    *
    Offline Offline

    Posts: 1714098544

    View Profile Personal Message (Offline)

    Ignore
    1714098544
    Reply with quote  #2

    1714098544
    Report to moderator
    1714098544
    Hero Member
    *
    Offline Offline

    Posts: 1714098544

    View Profile Personal Message (Offline)

    Ignore
    1714098544
    Reply with quote  #2

    1714098544
    Report to moderator
    TheSeven (OP)
    Hero Member
    *****
    Offline Offline

    Activity: 504
    Merit: 500


    FPGA Mining LLC


    View Profile WWW
    February 06, 2012, 04:10:37 PM
     #2

    <placeholder>

    My tip jar: 13kwqR7B4WcSAJCYJH1eXQcxG5vVUwKAqY
    shad
    Full Member
    ***
    Offline Offline

    Activity: 148
    Merit: 100


    View Profile
    February 06, 2012, 06:27:52 PM
     #3

    so without the D2xx-drivers we could get this thing running on OpenWRT?

    15dUzJEUkxgjrtcvDSdsEDkXu7E7RCbNN3
    TheSeven (OP)
    Hero Member
    *****
    Offline Offline

    Activity: 504
    Merit: 500


    FPGA Mining LLC


    View Profile WWW
    February 06, 2012, 06:42:53 PM
     #4

    so without the D2xx-drivers we could get this thing running on OpenWRT?

    That depends on:
    • Availability of /dev/bus/usb
    • Availability of libusb
    • Availability of python
    • Available RAM etc.

    My tip jar: 13kwqR7B4WcSAJCYJH1eXQcxG5vVUwKAqY
    O_Shovah
    Sr. Member
    ****
    Offline Offline

    Activity: 410
    Merit: 252


    Watercooling the world of mining


    View Profile
    February 06, 2012, 08:01:02 PM
     #5

    Is there a more detailed description for setting the scripts up avaidable ?

    I tried running it on my linux maschine but i keep getting errors for a common file.
    I guess my Pm to you dindn't reach you. Seems to be unreliable lately.

    thirdlight
    Sr. Member
    ****
    Offline Offline

    Activity: 445
    Merit: 250



    View Profile
    February 06, 2012, 08:36:05 PM
     #6

    I'm using windows xp & getting
    Code:
    2012-02-06 20:23:21.406000: Traceback (most recent call last):
    2012-02-06 20:23:21.406000:   File "miner.py", line 331, in <module>
    2012-02-06 20:23:21.406000:     miner.run()
    2012-02-06 20:23:21.406000:   File "miner.py", line 171, in run
    2012-02-06 20:23:21.406000:     self.adjustfetchers()
    2012-02-06 20:23:21.406000:   File "miner.py", line 180, in adjustfetchers
    2012-02-06 20:23:21.406000:     self.spawnfetcher()
    2012-02-06 20:23:21.406000:   File "miner.py", line 192, in spawnfetcher
    2012-02-06 20:23:21.406000:     excessmhashes = p.mhashes - ((now - p.starttime).total_seconds() + queuedelay) * p.hashrate
    2012-02-06 20:23:21.406000: AttributeError: 'datetime.timedelta' object has no attribute 'total_seconds'
    in the log.

    The terminal window is blank.

    Am I missing something?

    Thanks

    torusJKL
    Hero Member
    *****
    Offline Offline

    Activity: 619
    Merit: 500


    View Profile
    February 06, 2012, 08:49:52 PM
     #7

    Looks great.
    Thanks for sharing.

    If you find my post useful send some Bitcoin: 167XM1Za8aG9CdbYuHFMpL2kvPsw6uC8da
    Bitrated || bitcoin-otc || Moon Bitcoin Faucet
    TheSeven (OP)
    Hero Member
    *****
    Offline Offline

    Activity: 504
    Merit: 500


    FPGA Mining LLC


    View Profile WWW
    February 06, 2012, 08:59:11 PM
     #8

    I'm using windows xp & getting
    Code:
    2012-02-06 20:23:21.406000: Traceback (most recent call last):
    [...]
    2012-02-06 20:23:21.406000:     excessmhashes = p.mhashes - ((now - p.starttime).total_seconds() + queuedelay) * p.hashrate
    2012-02-06 20:23:21.406000: AttributeError: 'datetime.timedelta' object has no attribute 'total_seconds'
    in the log.
    That sounds like you're using Python <2.7 to me. Only 2.7 and 3.x is supported.

    @O_Shovah: I've responded to your PM now... Looks like common.py is missing for some reason? (I have no idea why...)

    My tip jar: 13kwqR7B4WcSAJCYJH1eXQcxG5vVUwKAqY
    kronosvl
    Full Member
    ***
    Offline Offline

    Activity: 134
    Merit: 100


    View Profile
    February 06, 2012, 09:40:27 PM
     #9

    Sub'd
    same here, specially openWRT oportunity

    Donations are accepted @: 19Uk8zVhdgfrRo5Z6wH9yghWxZUtdiNtX9
    OTC: http://bitcoin-otc.com/viewgpg.php?nick=kronosvl
    thirdlight
    Sr. Member
    ****
    Offline Offline

    Activity: 445
    Merit: 250



    View Profile
    February 06, 2012, 09:47:54 PM
     #10

    That sounds like you're using Python <2.7 to me. Only 2.7 and 3.x is supported.
    Yes, 2.6.7 as standard for X6500.

    I tried 2.7, log has:
    Code:
    2012-02-06 21:45:41.750000: Exception in thread X6500 hotplug controller_main:
    2012-02-06 21:45:41.750000: Traceback (most recent call last):
    2012-02-06 21:45:41.750000:   File "c:\python27\lib\threading.py", line 552, in __bootstrap_inner
    2012-02-06 21:45:41.750000:     self.run()
    2012-02-06 21:45:41.750000:   File "c:\python27\lib\threading.py", line 505, in run
    2012-02-06 21:45:41.750000:     self.__target(*self.__args, **self.__kwargs)
    2012-02-06 21:45:41.750000:   File "C:\mpbm\worker\fpgamining\x6500hotplug.py", line 127, in main
    2012-02-06 21:45:41.750000:     if not self.useftd2xx or self.takeover: import usb
    2012-02-06 21:45:41.750000: ImportError: No module named usb

    How do I get usb module?

    Thanks

    TheSeven (OP)
    Hero Member
    *****
    Offline Offline

    Activity: 504
    Merit: 500


    FPGA Mining LLC


    View Profile WWW
    February 06, 2012, 09:59:57 PM
     #11

    That sounds like you're using Python <2.7 to me. Only 2.7 and 3.x is supported.
    Yes, 2.6.7 as standard for X6500.

    I tried 2.7, log has:
    Code:
    2012-02-06 21:45:41.750000: Exception in thread X6500 hotplug controller_main:
    2012-02-06 21:45:41.750000: Traceback (most recent call last):
    2012-02-06 21:45:41.750000:   File "c:\python27\lib\threading.py", line 552, in __bootstrap_inner
    2012-02-06 21:45:41.750000:     self.run()
    2012-02-06 21:45:41.750000:   File "c:\python27\lib\threading.py", line 505, in run
    2012-02-06 21:45:41.750000:     self.__target(*self.__args, **self.__kwargs)
    2012-02-06 21:45:41.750000:   File "C:\mpbm\worker\fpgamining\x6500hotplug.py", line 127, in main
    2012-02-06 21:45:41.750000:     if not self.useftd2xx or self.takeover: import usb
    2012-02-06 21:45:41.750000: ImportError: No module named usb

    How do I get usb module?

    Thanks


    http://sourceforge.net/projects/pyusb/files/PyUSB%201.0/1.0.0-alpha-2/pyusb-1.0.0a2.zip/download

    you can just unpack the "usb" directory from that zip file into the mpbm directory, or install it system-wide using setup.py

    My tip jar: 13kwqR7B4WcSAJCYJH1eXQcxG5vVUwKAqY
    bitcowok
    Newbie
    *
    Offline Offline

    Activity: 48
    Merit: 0


    View Profile
    February 07, 2012, 02:48:53 AM
     #12

    Hi.

    Looking really good!

    Couple problems with v0.0.4alpha that I can see:
    1) curses line characters are all messed up in my locale  (en_AU.UTF-8) (let me know if you want a screenshot)
    2) I'm getting "Invalid long polling URL for Slushies: http://api.bitcoin.cz:8410"

    Thanks for this work, i'm loving the idea of one program to run ALL the FPGA's.
    coblee
    Donator
    Legendary
    *
    Offline Offline

    Activity: 1653
    Merit: 1286


    Creator of Litecoin. Cryptocurrency enthusiast.


    View Profile
    February 07, 2012, 04:27:10 AM
     #13

    I'm getting this error:

    Code:
    2012-02-06 20:25:26.472938: X6500 board AH00WOWD: No backend available
    2012-02-06 20:25:26.475037: X6500 board AH00WI18: dlsym(RTLD_DEFAULT, usb_find_busses): symbol not found

    LazarusLong
    Newbie
    *
    Offline Offline

    Activity: 16
    Merit: 0


    View Profile
    February 07, 2012, 08:27:54 AM
     #14

    I was working on a port with libftdi to replace the d2xx lib - it did not work, some bits in the data streams differ.
    Great work! I really need this stuff on openwrt... Grin
    thirdlight
    Sr. Member
    ****
    Offline Offline

    Activity: 445
    Merit: 250



    View Profile
    February 07, 2012, 08:37:58 AM
     #15

    you can just unpack the "usb" directory from that zip file ...

    Thanks, TheSeven. I bet you underestimated the level of hand-holding some users need!

    Now getting:
    Code:
    2012-02-07 08:34:53.468000: Caught exception: No backend available

    Not getting quite as far as coblee, as no board serial detected?

    coblee
    Donator
    Legendary
    *
    Offline Offline

    Activity: 1653
    Merit: 1286


    Creator of Litecoin. Cryptocurrency enthusiast.


    View Profile
    February 07, 2012, 09:25:38 AM
     #16

    Well, I put the serial in the config.py myself:

    Code:
      # Single X6500 worker
      { \
        # Worker module
        "type": worker.fpgamining.x6500.X6500Worker, \
        # Worker module parameters, in this case board serial number (default: take first available)
        "deviceid": "AH00WOWD", \
      }, \

      # Single X6500 worker
      { \
        # Worker module
        "type": worker.fpgamining.x6500.X6500Worker, \
        # Worker module parameters, in this case board serial number (default: take first available)
        "deviceid": "AH00WI18", \
      }, \

    TheSeven (OP)
    Hero Member
    *****
    Offline Offline

    Activity: 504
    Merit: 500


    FPGA Mining LLC


    View Profile WWW
    February 07, 2012, 12:07:40 PM
     #17

    Hi.

    Looking really good!

    Couple problems with v0.0.4alpha that I can see:
    1) curses line characters are all messed up in my locale  (en_AU.UTF-8) (let me know if you want a screenshot)
    2) I'm getting "Invalid long polling URL for Slushies: http://api.bitcoin.cz:8410"

    Thanks for this work, i'm loving the idea of one program to run ALL the FPGA's.

    1) might be curses not properly detecting your terminal type. Running it inside a screen session sometimes helps with this. If you're using PuTTY as a terminal, make sure to set its charset to UTF-8.
    2) MPBM probably expects a trailing slash here... I'll fix that later today.

    I'm getting this error:

    Code:
    2012-02-06 20:25:26.472938: X6500 board AH00WOWD: No backend available
    2012-02-06 20:25:26.475037: X6500 board AH00WI18: dlsym(RTLD_DEFAULT, usb_find_busses): symbol not found

    you can just unpack the "usb" directory from that zip file ...

    Thanks, TheSeven. I bet you underestimated the level of hand-holding some users need!

    Now getting:
    Code:
    2012-02-07 08:34:53.468000: Caught exception: No backend available

    Not getting quite as far as coblee, as no board serial detected?

    Sounds like you don't have libusb installed or a weird version of it.

    Well, I put the serial in the config.py myself:

    Code:
      # Single X6500 worker
      { \
        # Worker module
        "type": worker.fpgamining.x6500.X6500Worker, \
        # Worker module parameters, in this case board serial number (default: take first available)
        "deviceid": "AH00WOWD", \
      }, \

      # Single X6500 worker
      { \
        # Worker module
        "type": worker.fpgamining.x6500.X6500Worker, \
        # Worker module parameters, in this case board serial number (default: take first available)
        "deviceid": "AH00WI18", \
      }, \

    If that works, autodetecting should have worked as well.

    My tip jar: 13kwqR7B4WcSAJCYJH1eXQcxG5vVUwKAqY
    TheSeven (OP)
    Hero Member
    *****
    Offline Offline

    Activity: 504
    Merit: 500


    FPGA Mining LLC


    View Profile WWW
    February 07, 2012, 12:25:01 PM
     #18

    2) I'm getting "Invalid long polling URL for Slushies: http://api.bitcoin.cz:8410"

    Fixed Smiley

    My tip jar: 13kwqR7B4WcSAJCYJH1eXQcxG5vVUwKAqY
    TheSeven (OP)
    Hero Member
    *****
    Offline Offline

    Activity: 504
    Merit: 500


    FPGA Mining LLC


    View Profile WWW
    February 07, 2012, 12:41:33 PM
     #19

    I'm using windows xp & getting
    Code:
    2012-02-06 20:23:21.406000: Traceback (most recent call last):
    [...]
    2012-02-06 20:23:21.406000:     excessmhashes = p.mhashes - ((now - p.starttime).total_seconds() + queuedelay) * p.hashrate
    2012-02-06 20:23:21.406000: AttributeError: 'datetime.timedelta' object has no attribute 'total_seconds'
    in the log.

    MPBM should now be compatible with Python 2.6 as well.
    Thanks to LazarusLong for providing the patch Smiley

    My tip jar: 13kwqR7B4WcSAJCYJH1eXQcxG5vVUwKAqY
    thirdlight
    Sr. Member
    ****
    Offline Offline

    Activity: 445
    Merit: 250



    View Profile
    February 07, 2012, 04:58:53 PM
     #20

    I've had mpbm working using "useftd2xx":"true" and python 2.6.7.

    It saw all the boards, but couldn't "open" all of them.

    Seemed to be getting shares, pool reported widely varying hashrate. The terminal window has a message about "window too small" so no stats to relay.

    Froze around an hour later, no reason in the log.

    I like that it manages (or tries to) all the boards at once - much neater than multiple windows. I will persevere.

    Pages: [1] 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 »  All
      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!