Author

Topic: cgminer API: Antminer (Z9 mini) remotecontrol questions (Read 276 times)

newbie
Activity: 1
Merit: 0
config/cgminer.conf "api-allow": "A: 0/0, W: *", replace "api-allow": "W: 0/0, W: *", reboot   and you will be happy
newbie
Activity: 5
Merit: 0
sorry for pushing, but maybe someone can tell if there is any option to use a privileged API access (change pool, freq, etc.) for Antminer Z9 mini? (special settings, config or firmware?)
newbie
Activity: 5
Merit: 0
Hi together,

just owned an ASIC antminer (Z9 mini) and now looking for a remote control option.
I found the cgminer API, read the API-readme from github, but get stuck running some cmds.

this is my cgminer.conf: (just for testing)
Code:
"api-listen" : true,
"api-network" : true,
"api-groups" : "A:stats:pools:devs:summary:version",
"api-allow" : "W:0/0",
"bitmain-use-vil" : true,
"bitmain-freq" : "600"

First question:
The original api-allow row was this:
Code:
"api-allow" : "A:0/0,W:*",
I know that 0/0 means access from any IP-Address, but what means "*"@ ",W:*" in api-allow section?


For testing the API I am using the api-example.PY and api-example.PHP but the results are the same.

Executing the following cmds on a remote maschine in the same network:
1. "python api-example.py summary"
     AND api-example.php with "request('summary')"          -> successful getting summary information.
2. "python api-example.py stats"                               ->getting syntax error from python "ValueError: Expecting , delimiter: line 1 column 225 (char 224)"
     AND api-example.php with "request('stats')"                  -> successful getting summary information.

3. python api-example.py "check|ascset"                   -> successful getting this return: "{u'STATUS': [{u'STATUS': u'S', u'Msg': u'Check command', u'Code': 72, u'When': 1530261460, u'Description': u'cgminer 4.9.0'}], u'CHECK': [{u'Access': u'N', u'Exists': u'N'}], u'id': 1}"

4. python api-example.py "ascset|0,frequency,0-500" -> getting following erroras return: "{u'STATUS': [{u'STATUS': u'E', u'Msg': u'Invalid command', u'Code': 14, u'When': 1530261532, u'Description': u'cgminer 4.9.0'}], u'id': 1}"
   AND api-example.php with "request('ascset|0,frequency,0-500')" -> getting this return: "ascset|0,frequency,0-500 returned 'STATUS=E,When=1530261674,Code=14,Msg=Invalid command,Description=cgminer 4.9.0|' Array ( [STATUS] => Array ( [STATUS] => E [When] => 1530261674 => 14 [Msg] => Invalid command [Description] => cgminer 4.9.0 ) )"

So can someone please tell me whats the correct syntax for this cmds?

Also looking for the option to change frequency, fan speed, pool, settings via the API. But the cmds i tested above and I got from the API-Readme doesn´t work. 
I read somewhere that the cgminer on antminer ASICS is changed a lot. Are there other cmds for these actions?

And the last question:
Want to control the asic from a Webserver in WAN - is there an option to protect the API connection from unauthorized access, except the IP-restriction?


would be nice i someone can helpü me with these question!
Thanks and best regards,
Dave



Jump to: