Bitcoin Forum
May 10, 2024, 11:37:21 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Getting Minera working with Innosilicon A4+ ASICs  (Read 142 times)
Aepko (OP)
Newbie
*
Offline Offline

Activity: 12
Merit: 1


View Profile
January 11, 2018, 05:24:18 PM
 #1

Hey guys! I've been reading posts on here for a while and wanted to post my progress and get some help with Minera on the A4+ ASICs (and probably other Inno ASICs)

I'll get start some instructions on how to get as far as I've gotten and edit the post when I've figured out the last part.

So to start, you should already have your ASIC configured and good to go with your pools. From there,

Enable Telnet if you're using windows. If you're using another Telnet program, on linux, etx, you can skip this step.

You can enable Telnet by typing "Turn Windows Features On or Off" into your start menu and selecting the "Telnet Client" box.

Now open up a command prompt window and type

Code:
telnet

then

Code:
o "ASIC IP" 8100

it will ask you for a username and a password. Your username will be root, and the password for the December 22nd firmware is t1t2t3a5

Now you are logged into your ASIC, but we need to give ourselves write access to the system. To do this, type

Code:
 mount / -o rw,remount 

Now we're able to edit the config files. From here, I enabled API access to ccminer following the steps on the A4+ advanced setup post here https://bitcointalk.org/index.php?topic=2549898.0

  • type "cd /home/inno_py/"
  • type "cp /home/inno_py/inno_config.py ./inno_config.py.bk" to take a backup of your file before editing
  • type "vi /home/inno_py/inno_config.py" to erdit your config file
  • scroll down until you see the value gInnoInitCmdStr
  • click the letter i on the keyboard to enable edit mode in vi
  • at the end of that line replace "--api-listen" with "--api-listen --api-network --api-allow W:0/0" this will enable network privileged access from API
  • Click  "ESC" on the keyboard to exit Edit Mode
  • click ":wq" and Enter to save the file
  • type reboot to reboot your miner and for changes to take effect

Now, you can install Minera on your linux system (such as a Raspberry Pi) and connect it to your network. Follow the steps on getminera.com and add a "Network Miner" by typing in your ASICs IP address with the port 4028

It appears as online in the Network Miner list in the settings, but Minera never finishes refreshing. If you check the raw JSON file, it has the proper hashrate and pool info, but a PHP error stops it from adding the stats to the dashboard. The PHP error according to the JSON is

Code:
 <h4>A PHP Error was encountered</h4>

<p>Severity: Notice</p>
<p>Message:  Undefined property: stdClass::$Type</p>
<p>Filename: models/util_model.php</p>
<p>Line Number: 435</p>

Once that can be fixed, I don't see why Minera can't manage these ASICs
1715384241
Hero Member
*
Offline Offline

Posts: 1715384241

View Profile Personal Message (Offline)

Ignore
1715384241
Reply with quote  #2

1715384241
Report to moderator
"In a nutshell, the network works like a distributed timestamp server, stamping the first transaction to spend a coin. It takes advantage of the nature of information being easy to spread but hard to stifle." -- Satoshi
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1715384241
Hero Member
*
Offline Offline

Posts: 1715384241

View Profile Personal Message (Offline)

Ignore
1715384241
Reply with quote  #2

1715384241
Report to moderator
1715384241
Hero Member
*
Offline Offline

Posts: 1715384241

View Profile Personal Message (Offline)

Ignore
1715384241
Reply with quote  #2

1715384241
Report to moderator
michelem
Legendary
*
Offline Offline

Activity: 1015
Merit: 1000



View Profile WWW
January 11, 2018, 05:45:30 PM
 #2

That's a problem with the data output from the A4, it's not like the Antminers so I need to change something there.
To do this I need to know how the stats come from A4, please try to run this from the RPI:

Code:
 echo '{"command": "stats"}' | nc <A4-IP> 4028

Get Minera. Your next bitcoin mining dashboard. Donations are welcome
Aepko (OP)
Newbie
*
Offline Offline

Activity: 12
Merit: 1


View Profile
January 11, 2018, 05:53:21 PM
 #3

This is the reply back

Code:
 echo '{"command": "stats"}' | nc 192.168.1.41 4028
{"STATUS":[{"STATUS":"S","When":1515693143,"Code":70,"Msg":"CGMiner stats","Description":"cgminer 4.10.0"}],"STATS":[{"STATS":0,"ID":"BA10","Elapsed":3382,"Calls":0,"Wait":0.000000,"Max":0.000000,"Min":99999999.000000},{"STATS":1,"ID":"BA11","Elapsed":3382,"Calls":0,"Wait":0.000000,"Max":0.000000,"Min":99999999.000000},{"STATS":2,"ID":"BA12","Elapsed":3382,"Calls":0,"Wait":0.000000,"Max":0.000000,"Min":99999999.000000},{"STATS":3,"ID":"BA13","Elapsed":3382,"Calls":0,"Wait":0.000000,"Max":0.000000,"Min":99999999.000000},{"STATS":4,"ID":"POOL0","Elapsed":3382,"Calls":0,"Wait":0.000000,"Max":0.000000,"Min":99999999.000000,"Pool Calls":0,"Pool Attempts":0,"Pool Wait":0.000000,"Pool Max":0.000000,"Pool Min":99999999.000000,"Pool Av":0.000000,"Work Had Roll Time":false,"Work Can Roll":false,"Work Had Expire":false,"Work Roll Time":0,"Work Diff":65536.00000000,"Min Diff":8192.00000000,"Max Diff":65536.00000000,"Min Diff Count":974,"Max Diff Count":230480,"Times Sent":488,"Bytes Sent":54470,"Times Recv":721,"Bytes Recv":240146,"Net Bytes Sent":54470,"Net Bytes Recv":240146}],"id":1}
Aepko (OP)
Newbie
*
Offline Offline

Activity: 12
Merit: 1


View Profile
January 11, 2018, 08:54:53 PM
 #4

For anyone more savvy than me.. Here is the full JSON returned with the A4+ from Minera

Code:
<div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">

<h4>A PHP Error was encountered</h4>

<p>Severity: Notice</p>
<p>Message:  Undefined property: stdClass::$Type</p>
<p>Filename: models/util_model.php</p>
<p>Line Number: 435</p>

</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">

<h4>A PHP Error was encountered</h4>

<p>Severity: Notice</p>
<p>Message:  Undefined property: stdClass::$Type</p>
<p>Filename: models/util_model.php</p>
<p>Line Number: 435</p>

</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">

<h4>A PHP Error was encountered</h4>

<p>Severity: Notice</p>
<p>Message:  Undefined property: stdClass::$Type</p>
<p>Filename: models/util_model.php</p>
<p>Line Number: 435</p>

</div>{"notrunning":true,"network_miners":{"MY RIG":{"start_time":1515689761,"totals":{"temperature":false,"frequency":false,"accepted":2027,"rejected":2,"hw_errors":14729,"shares":0,"hashrate":0,"last_share":1515703884},"pool":{"hashrate":629125673,"url":"MY POOL","alive":true},"pools":[{"priority":0,"url":"MY POOL","active":true,"user":"MY RIG","pass":false,"stats":[{"start_time":false,"accepted":2027,"rejected":2,"shares":883415,"stop_time":false,"stats_id":1}],"stats_id":1,"alive":true}],"config":{"ip":"192.168.1.41","port":"4028","algo":"Scrypt"}}},"minera_id":"ymmyjknmfhzm","miner":"cpuminer","algo":"Scrypt","sysload":[1.04,0.28,0.1],"cron":null,"sysuptime":"31","temp":{"value":"54.23","scale":"c"},"btc_rates":{"high_eur":12549.19,"last_eur":11274.52,"high":"14973.07","last":"13452.19","timestamp":"1515703820","bid_eur":11293.3,"vwap_eur":11506.84,"bid":"13474.60","vwap":"13729.39","volume":"19181.92181082","low_eur":10727.91,"ask_eur":11303.11,"low":"12800.00","ask":"13486.31","eur_usd":1.19315},"altcoins_rates":{"error":"true"},"avg":{"1min":[],"5min":[false],"1hour":[false],"1day":[]},"profits":[{"symbol":"btc","coin":"bitcoin","algo":"sha256","reward":12.5,"difficulty":1931136454487.7,"blocks":503751,"networkhashps":"19504895985485860000","btcValue":1,"price":1,"coin_profitability":1.3021197676727e-10,"btc_profitability":1.3021197676727e-10,"timestamp":1515703803,"hashrate":1000000},{"symbol":"bch","coin":"bitcoin cash","algo":"sha256","reward":12.5,"difficulty":53206941.883907,"blocks":518174,"networkhashps":6.0455462793642e+14,"btcValue":0.18799036,"price":0.18799036,"coin_profitability":4.7260204447539e-6,"btc_profitability":8.8844628477665e-7,"timestamp":1515703803,"hashrate":1000000},{"symbol":"ltc","coin":"litecoin","algo":"scrypt","reward":25,"difficulty":3660955.7838378,"blocks":1348615,"networkhashps":1.1439741936518e+14,"btcValue":0.01717569,"price":0.01717569,"coin_profitability":0.00013737237486249,"btc_profitability":2.3594653252019e-6,"timestamp":1515703803,"hashrate":1000000}],"livestat":true,"timestamp":1515703885}

This is what line 435 of util_model.php reads

Code:
 if (isset($stats->stats[0]->STATS[0]) && ($stats->stats[0]->STATS[0]->Type == 'Antminer S9' || $stats->stats[0]->STATS[0]->Type == 'Antminer L3+' || $stats->stats[0]->STATS[0]->Type == 'Antminer D3')) $antNew = true;

and this is what is returned from the A4+ when I ask the API for stats

Code:
 echo '{"command": "stats"}' | nc 192.168.1.41 4028
{"STATUS":[{"STATUS":"S","When":1515693143,"Code":70,"Msg":"CGMiner stats","Description":"cgminer 4.10.0"}],"STATS":[{"STATS":0,"ID":"BA10","Elapsed":3382,"Calls":0,"Wait":0.000000,"Max":0.000000,"Min":99999999.000000},{"STATS":1,"ID":"BA11","Elapsed":3382,"Calls":0,"Wait":0.000000,"Max":0.000000,"Min":99999999.000000},{"STATS":2,"ID":"BA12","Elapsed":3382,"Calls":0,"Wait":0.000000,"Max":0.000000,"Min":99999999.000000},{"STATS":3,"ID":"BA13","Elapsed":3382,"Calls":0,"Wait":0.000000,"Max":0.000000,"Min":99999999.000000},{"STATS":4,"ID":"POOL0","Elapsed":3382,"Calls":0,"Wait":0.000000,"Max":0.000000,"Min":99999999.000000,"Pool Calls":0,"Pool Attempts":0,"Pool Wait":0.000000,"Pool Max":0.000000,"Pool Min":99999999.000000,"Pool Av":0.000000,"Work Had Roll Time":false,"Work Can Roll":false,"Work Had Expire":false,"Work Roll Time":0,"Work Diff":65536.00000000,"Min Diff":8192.00000000,"Max Diff":65536.00000000,"Min Diff Count":974,"Max Diff Count":230480,"Times Sent":488,"Bytes Sent":54470,"Times Recv":721,"Bytes Recv":240146,"Net Bytes Sent":54470,"Net Bytes Recv":240146}],"id":1}
Aepko (OP)
Newbie
*
Offline Offline

Activity: 12
Merit: 1


View Profile
January 11, 2018, 10:55:53 PM
 #5

I'm pretty sure if I can turn off error reporting, it will work. Its the PHP errors freezing the dashboard, all the info is there though.
Pages: [1]
  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!