15 lines
968 B
PowerShell
15 lines
968 B
PowerShell
[Console]::OutputEncoding = [Text.Encoding]::UTF8
|
|
$cap = "$env:TEMP\opencode\sym_startup.pcap"
|
|
$ts = "C:\Program Files\Wireshark\tshark.exe"
|
|
Write-Host "=== claim frames (ident 110 / 47B 55 / AECH 560) ==="
|
|
& $ts -r $cap -Y "udp.length==110 or udp.length==55 or udp.length==560" -T fields -e frame.time_relative -e ip.src -e ip.dst -e udp.length 2>$null | Select-Object -First 12
|
|
Write-Host ""
|
|
Write-Host "=== host-sent frame types (all, until +30s after claim window end) ==="
|
|
$all = @(& $ts -r $cap -Y "ip.src==192.168.123.113" -T fields -e frame.time_relative -e ip.dst -e udp.length 2>$null)
|
|
$g = @{}
|
|
foreach ($l in $all) { $p = $l -split "`t"; $k = $p[1] + " len=" + $p[2]; if (-not $g.ContainsKey($k)) { $g[$k] = New-Object System.Collections.ArrayList }; [void]$g[$k].Add([double]$p[0]) }
|
|
foreach ($k in ($g.Keys | Sort-Object)) {
|
|
$arr = $g[$k]
|
|
Write-Host ("{0,-30} n={1,-6} first={2:N1}s last={3:N1}s" -f $k, $arr.Count, $arr[0], $arr[$arr.Count-1])
|
|
}
|