Example: save packet data to file. Rotate file every 60 seconds
# -n - numeric. do not convert addresses, port numbers, etc. to names
# -i - interface to listen on. e.g. 'eth0', 'wlan0', etc. Usually defaults to all traffic minus loopback and tunnel interfaces. 
#      Wildcard 'all' can be specified to capture all including loopback and tunnel interfaces
# -w <filename> - save packet data to specified file. 
# -G <n seconds> - rotate file every n seconds 
# -z <postrotate-command> -- Used with -C or -G, will execute 'postrotate-command file' -- once each file is generated
tcpdump -n -i wlan0 -w '/home/pi/tcpdump/tcpudmp.w.%Y%m%d_%H%M%S' -G 60