This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$report = @() | |
foreach ($vm in $view) { | |
foreach ($vc in $vcenter) { | |
if($vm.Name -eq $vc.Name) { | |
$entry = [PSCustomObject] @{ | |
Name = $vm.Name | |
CPU = $vc.summary.config.NumCpu | |
Memory = $vc.summary.config.MemorySizeMB | |
}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$brokers = "mapvasdfp02", "natviasdf2", "stpvasdf02" | |
$vcenters = "mapvasdfp02", "natasdf2", "stasdfp02" | |
#$creds = Get-Credential -Message "Please enter your credentials" | |
"Connecting to vCenter Servers" | |
connect-viserver $vcenters -Credential $creds | |
Set-StrictMode -Version 2.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//include all libraries | |
#include <ESP8266WiFi.h> | |
#include <ESP8266mDNS.h> | |
#include <ESP8266httpUpdate.h> | |
#include <PubSubClient.h> | |
#include <RCSwitch.h> | |
#include <fauxmoESP.h> | |
//basic defines | |
#define MQTT_VERSION MQTT_VERSION_3_1_1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <ESP8266WiFi.h> | |
#include <PubSubClient.h> | |
// WiFi Settings | |
#define wifi_ssid "ssid" | |
#define wifi_password "pw" | |
// MQTT Settings | |
#define mqtt_server "192.168.0.27" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <IRremote.h> | |
int RECV_PIN = 11; | |
IRrecv irrecv(RECV_PIN); | |
IRsend irsend; | |
boolean recording = true; | |
decode_results results; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <Servo.h> | |
Servo esc; | |
int escPin = 9; | |
int minPulseRate = 1000; | |
int maxPulseRate = 2000; | |
int throttleChangeDelay = 100; | |
void setup() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <ESP8266WiFi.h> | |
#include <PubSubClient.h> | |
#include <ESP8266mDNS.h> | |
#include <WiFiUdp.h> | |
#include <ArduinoOTA.h> | |
#include "secrets.h" | |
#define ROOM "what" | |
#define NAME "ever" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Connect-VIServer asdf | |
Clear-Variable report | |
$report = Get-Datacenter -PipelineVariable datacenter | | |
ForEach-Object { | |
get-cluster -Location $_ -PipelineVariable cluster | | |
ForEach-Object { get-vmhost -Location $_ | | |
foreach-object {[pscustomobject]@{ | |
Datacenter=$datacenter.Name; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2019-08-08T22:47:43.993+02:00> LVL:1 RC: 0 VGMAC :Stat frms: R=000000/000000/002750 T=000000/001365/001098 (A/I/O) Loss=0.00%/0.00% (R/T) | |
2019-08-08T22:48:44.071+02:00> LVL:1 RC: 0 VGMAC :Stat frms: R=000000/000000/004875 T=000000/002682/002119 (A/I/O) Loss=0.00%/0.00% (R/T) | |
2019-08-08T22:49:44.328+02:00> LVL:1 RC: 0 VGMAC :Stat frms: R=000000/000000/008169 T=000000/004467/003477 (A/I/O) Loss=0.00%/0.00% (R/T) | |
2019-08-08T22:50:44.324+02:00> LVL:1 RC: 0 VGMAC :Stat frms: R=000000/000000/010081 T=000356/005626/004329 (A/I/O) Loss=0.00%/0.00% (R/T) | |
2019-08-08T22:51:44.569+02:00> LVL:1 RC: 0 VGMAC :Stat frms: R=000000/000000/012161 T=000356/006768/005296 (A/I/O) Loss=0.00%/0.00% (R/T) | |
2019-08-08T22:52:44.641+02:00> LVL:1 RC: 0 VGMAC :Stat frms: R=000000/000000/013773 T=000356/007559/005970 (A/I/O) Loss=0.00%/0.00% (R/T) | |
2019-08-08T22:53:44.899+02:00> LVL:1 RC: 0 VGMAC :Stat frms: R=000000/000000/015832 T=000356/009122/00685 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function CleanVariables { Get-Variable | Where-Object { $startupVariables -notcontains $_.Name } | ForEach-Object { | |
try { Remove-Variable -Name "$($_.Name)" -Force -Scope "global" -ErrorAction SilentlyContinue -WarningAction SilentlyContinue } | |
catch { } | |
} | |
} | |
CleanVariables | |
<# This form was created using POSHGUI.com a free online gui designer for PowerShell | |
.NAME |
OlderNewer