has anyone tried butchering jj's hashmonitor powershell script to monitor castxmr now that it has an API?
i would but my programming leaves a lot to be desired....
I posted this on another thread and also helping some redditor, but you can try this:
I have modified the script slightly to work with 1 of my Vega card. You can modified it accordingly to fit your rig.
Download link below:
https://drive.google.com/open?id=0B2XFJ__I0jzLWlBZMTVCMWZDZ3YwRDZiRkh6cldKWnc1WjlzSome changes I made:
If you are executing the run_HashMonitor.cmd, make sure you change the file name in it accordingly to reflect CastXMR_HashMonitor_v2.6.ps1 (Or any name that you saved as).
Notable change I have made in this ps script includes:
Line 168 - 172 : I am using the script to call Cast-XMR directly, and Line 169 is the usual config including my wallet address, mining pool etc (the usual you put in a .bat) & also --remoteaccess in this case. Line 170 - 172 is to assign the localhost & port accordingly (7777)
Line 187: The main address for local/remote monitoring
Line 191 - 201: I didn't use $hdiff variable, but make a new variable for min Vega Hashrate before restart $global:vegahash @ line 201 (multiply by 1,000 since the reported value in the web is in actual hash rate)
Line 392 - 397 : Initial Vega hashrate for comparison (Not really needed since we have a reset trigger down below, but it's the same as the next)
Line 476 - 479 : Vega hashrate used for monitoring in order for restart.
Line 483 - 484 : Nothing major, just changing monitoring from 1 minute to every 30 secs
7: Line 486 : Most important part, condition to restart (Here to check my Vega hashrate against my preset target -> ~1.75kH/s @ Line 201)
This should set you up in the right direction to start with;
Do take note that I am running only 1 Vega to check against, hence I can use the total_hash_rate for comparison; if you are running multiple Vegas rig, you might need to divide it by number of GPU instances before you make the comparison. Alternatively is to loop through the "devices" in the hashrate report JSON to check if any of them drop, but I find total_hash_rate to be easier. You can also use total_hash_rate_avg in the report, as current total_hash_rate might be too sensitive for occasional dip.
And remember to change the CMDLine in Line 169, or else you would be mining to my wallet instead.
Let me know if you have any further question. I will try my best to help set up.
Thanks for this. Will report on results soon.