My problem with emdje's latest version is that if first pool stops with "waiting for work to be available from pools" and is still alive, then cgminer never switches to backup pools and minings stops. Any idea, mayb some cgminer setting? Also Im not sure if this latest version really contain the extra-nounce support since I stopped seeing the extra-nonce messages from nicehash (#xnsub).
$cmd = "sudo ./cgminer ... --A1Pll1 ".$speed1." --A1Pll2 ".$speed2." --A1Pll3 ".$speed3." --A1Pll4 ".$speed4." --A1Pll5 ".$speed5." --A1Pll6 ".$speed6." --diff ".$diff." --cs 8 --stmcu 0 --hwreset
--lowmem > cgminer.log &";