implemented wifi scan, log writing.