If you get the following error whilst making a call to an external list make sure that you instantiate a spservicecontext. Just add the lines below above your get-spweb.
# BEGIN: Get the SpServiceContext as a BCS call is being made
$context = Get-SPServiceContext “http://sharepoint/”;
$scope = New-Object microsoft.SharePoint.SPServiceContextScope $context ;
# END: Get the SpServiceContext as a BCS call is being made