Author Topic: Raspberry pi issue with asic miner  (Read 19934 times)

ppafford

  • Member
  • ***
  • Posts: 3
Raspberry pi issue with asic miner
« on: March 31, 2014, 10:07:48 pm »
Related:

 - http://bitcoin.stackexchange.com/questions/20024/bfgminer-cant-find-my-nanofury

Posted on the RPi Exchange as well

 - http://raspberrypi.stackexchange.com/questions/14753/bfgminer-cant-find-my-nanofury-on-raspberry-pi

Forums:

 - https://bitcointalk.org/index.php?topic=529545

I see the miners with these commands

    lsusb -t
    /:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=dwc_otg/1p, 480M
        |__ Port 1: Dev 2, If 0, Class=hub, Driver=hub/3p, 480M
            |__ Port 1: Dev 3, If 0, Class=vend., Driver=smsc95xx, 480M
            |__ Port 3: Dev 4, If 0, Class=hub, Driver=hub/4p, 480M
                |__ Port 4: Dev 5, If 0, Class=hub, Driver=hub/4p, 480M
                    |__ Port 1: Dev 6, If 0, Class=HID, Driver=usbhid, 12M
                    |__ Port 4: Dev 7, If 0, Class=HID, Driver=usbhid, 12M

and

    lsusb
    Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp.
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 001 Device 006: ID 04d8:00de Microchip Technology, Inc.                          <-- USB Miner
    Bus 001 Device 007: ID 04d8:00de Microchip Technology, Inc.                          <-- USB Miner
    Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp.
    Bus 001 Device 004: ID 1a40:0101 Terminus Technology Inc. 4-Port HUB
    Bus 001 Device 005: ID 1a40:0101 Terminus Technology Inc. 4-Port HUB

but they do not show up when running bfgminer 3.10.0

Running Raspbian and have compiled everything from source.

Is there a missing driver I need for these?

command line

    ./bfgminer -o stratum+tcp://stratum.d7.lt:3333 -u username -p password -S nanofury:all --set-device NFY:osc6_bits=33

output

    NO DEVICES FOUND: Press 'M' and '+' to add

I've seen this configured on other systems, do I need o configure this as well?

    # NF2
    ATTRS{idVendor}=="04d8", ATTRS{idProduct}=="00de", SUBSYSTEMS=="usb", ACTION=="add", MODE="0666", GROUP="root"

debug output

    2014-03-25 04:01:06] hid_devinfo_scan: Found "NanoFury NF2 v0.5 by MLM" serial "0000100001"
     [2014-03-25 04:01:06] hid_devinfo_scan: Found "NanoFury NF2 v0.5 by MLM" serial "0000100002"
     [2014-03-25 04:01:06] lowlevel_scan: Found usb device at usb:001:005 (path=(null), vid=1a40, pid=0101, manuf=(null), prod=USB 2.0 Hub, serial=(null))
     [2014-03-25 04:01:06] lowlevel_scan: Found usb device at usb:001:004 (path=(null), vid=1a40, pid=0101, manuf=(null), prod=USB 2.0 Hub, serial=(null))
     [2014-03-25 04:01:06] lowlevel_scan: Found usb device at usb:001:003 (path=(null), vid=0424, pid=ec00, manuf=(null), prod=(null), serial=(null))
     [2014-03-25 04:01:06] lowlevel_scan: Found usb device at usb:001:007 (path=(null), vid=04d8, pid=00de, manuf=Microchip Technology Inc., prod=NanoFury NF2 v0.5 by MLM, serial=0000100001)
     [2014-03-25 04:01:06] lowlevel_scan: Found usb device at usb:001:006 (path=(null), vid=04d8, pid=00de, manuf=Microchip Technology Inc., prod=NanoFury NF2 v0.5 by MLM, serial=0000100002)
     [2014-03-25 04:01:06] lowlevel_scan: Found usb device at usb:001:001 (path=(null), vid=1d6b, pid=0002, manuf=Linux 3.10.25+ dwc_otg_hcd, prod=DWC OTG Controller, serial=bcm2708_usb)
     [2014-03-25 04:01:06] lowlevel_scan: Found usb device at usb:001:002 (path=(null), vid=0424, pid=9512, manuf=(null), prod=(null), serial=(null))
     [2014-03-25 04:01:06] lowlevel_scan: Found hid device at hid:/dev/hidraw1 (path=/dev/hidraw1, vid=04d8, pid=00de, manuf=Microchip Technology Inc., prod=NanoFury NF2 v0.5 by MLM, serial=0000100001)
     [2014-03-25 04:01:06] lowlevel_scan: Found hid device at hid:/dev/hidraw0 (path=/dev/hidraw0, vid=04d8, pid=00de, manuf=Microchip Technology Inc., prod=NanoFury NF2 v0.5 by MLM, serial=0000100002)
     [2014-03-25 04:01:06] lowlevel_scan: Found mcp2210 device at hid:/dev/hidraw0 (path=/dev/hidraw0, vid=04d8, pid=00de, manuf=Microchip Technology Inc., prod=NanoFury NF2 v0.5 by MLM, serial=0000100001)
     [2014-03-25 04:01:06] lowlevel_scan: Found mcp2210 device at hid:/dev/hidraw1 (path=/dev/hidraw1, vid=04d8, pid=00de, manuf=Microchip Technology Inc., prod=NanoFury NF2 v0.5 by MLM, serial=0000100002)
     [2014-03-25 04:01:06] mcp2210_set_cfg_gpio: Failed to set current GPIO config
     [2014-03-25 04:01:06] mcp2210_get_gpio_input: Failed to get current GPIO input values
     [2014-03-25 04:01:06] mcp2210_set_cfg_gpio: Failed to set current GPIO config
     [2014-03-25 04:01:06] mcp2210_set_cfg_gpio: Failed to set current GPIO config
     [2014-03-25 04:01:06] mcp2210_get_gpio_input: Failed to get current GPIO input values
     [2014-03-25 04:01:06] mcp2210_set_cfg_gpio: Failed to set current GPIO config
     [2014-03-25 04:01:06] nanofury_lowl_probe: Matched "NanoFury NF2 v0.5 by MLM" serial "0000100001", but failed to detect nanofury
     [2014-03-25 04:01:06] mcp2210_set_cfg_gpio: Failed to set current GPIO config
     [2014-03-25 04:01:06] mcp2210_get_gpio_input: Failed to get current GPIO input values
     [2014-03-25 04:01:06] mcp2210_get_gpio_input: Failed to get current GPIO input values
     [2014-03-25 04:01:06] nanofury_lowl_probe: Matched "NanoFury NF2 v0.5 by MLM" serial "0000100002", but failed to detect nanofury
     [2014-03-25 04:01:06] INFO: bitfury_detect
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:06] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:07] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:07] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:07] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:07] Unable to open SPI device: No such file or directory
     [2014-03-25 04:01:07] No Bitfury chips detected!
     [2014-03-25 04:01:07] ManageTUI: (none): No new devices found

UPDATE

Looks like I missed a package I needed to install:

 - https://bitcointalk.org/index.php?topic=291456.msg3924680#msg3924680

But now Im getting this error

     [2014-03-26 01:43:29] mcp2210_get_configs: Failed to get current SPI config
    Select processor to manage using up/down arrow keys
     [2014-03-26 01:43:29] NFY 0: Failed to open mcp2210 device
     NFY 0 : Initializing... [2014-03-26 01:43:29] NFY 0 failure, exitingSegmentation fault
    root@raspberrypi:/usr/bfgminer/bfgminer-3.10.0#

at least it's progress but still an issue

Jan Axelson

  • Administrator
  • Frequent Contributor
  • *****
  • Posts: 3033
    • Lakeview Research
Re: Raspberry pi issue with asic miner
« Reply #1 on: April 01, 2014, 09:21:03 pm »
I don't claim to know anything about bitcoin miners, but from what you've posted, it looks like the device enumerated OK but there is a problem with the SPI communications. If the SPI data is being transferred to/from the USB host, a USB protocol analyzer might offer some insight into what's happening:

http://www.janaxelson.com/development_tools.htm#analyzers
« Last Edit: July 13, 2014, 09:57:46 pm by Jan Axelson »

ppafford

  • Member
  • ***
  • Posts: 3
Re: Raspberry pi issue with asic miner
« Reply #2 on: April 01, 2014, 09:53:36 pm »
Thanks for your reply, I'm thinking the same. Someone pointed me to this site:

 - https://projects.drogon.net/wiringpi-and-the-raspberry-pi-revision-2/

BTW do you have any USB Analyzer tools for Debian? looks like most of those are for Windows

ppafford

  • Member
  • ***
  • Posts: 3
Re: Raspberry pi issue with asic miner
« Reply #3 on: April 01, 2014, 11:10:04 pm »
some additional output since I've updated the RPi firmware

[2014-04-02 03:08:21] nanofury_lowl_probe: Matched "NanoFury NF2 v0.5 by MLM" serial "0000142845", but mcp2210 lowlevel driver failed to open it
 [2014-04-02 03:08:22] Probing for an alive pool
 [2014-04-02 03:08:22] Network difficulty changed to 96.8M (693.1Th/s)
 [2014-04-02 03:08:22] Stratum from pool 0 detected new block
 [2014-04-02 03:08:22] Pool 0 is hiding block contents from us
 [2014-04-02 03:08:23] mcp2210_spi_transfer: Failed to continue SPI transfer (1 bytes remaining)
 [2014-04-02 03:08:23] mcp2210_set_cfg_spi: Error setting current SPI config (248)
 [2014-04-02 03:08:23] NFY 0 failure, attempting to reinitialize
 [2014-04-02 03:08:23] mcp2210_spi_transfer: Failed to continue SPI transfer (1 bytes remaining)
 [2014-04-02 03:08:23] mcp2210_set_cfg_spi: Error setting current SPI config (248)

Barry Twycross

  • Frequent Contributor
  • ****
  • Posts: 263
Re: Raspberry pi issue with asic miner
« Reply #4 on: April 01, 2014, 11:35:23 pm »
BTW do you have any USB Analyzer tools for Debian?
Looks like TotalPhase http://www.totalphase.com/protocols/usb/?___SID=U does a Linux host.

Jan Axelson

  • Administrator
  • Frequent Contributor
  • *****
  • Posts: 3033
    • Lakeview Research
Re: Raspberry pi issue with asic miner
« Reply #5 on: April 02, 2014, 11:13:20 am »
If you want to try a software-only analyzer, see:

http://wiki.wireshark.org/CaptureSetup/USB