$PSVersionTable.PSVersion.
"Upgrading PowerShell and .NET Framework.ps1"
Download and excutute on "ConfigureRemotingForAnsible.ps1" remote machine. check Vm listner status using below commond
winrm enumerate winrm/config/Listener check Winrm service on machine winrs -r:http://$hostname:5985/wsman -u:$username -p:password ipconfig