| 59 | } |
| 60 | |
| 61 | void Wait(uint32_t ms) |
| 62 | { |
| 63 | int32_t remainder = static_cast<int32_t>(ms); |
| 64 | while (remainder > 200) { |
| 65 | remainder -= 200; |
| 66 | std::chrono::milliseconds t(200); |
| 67 | std::this_thread::sleep_for(t); |
| 68 | if (_powerNodes.size()) { |
| 69 | for (auto& n : _powerNodes) { |
| 70 | printf("%f ", n->db()); |
| 71 | } |
| 72 | printf("\n"); |
| 73 | } |
| 74 | } |
| 75 | if (remainder < 200 && remainder > 0) { |
| 76 | std::chrono::milliseconds t(remainder); |
| 77 | std::this_thread::sleep_for(t); |
| 78 | } |
| 79 | } |
| 80 | |
| 81 | void AddMonitorNodes() { |
| 82 | for (auto n : _nodes) { |