AngularJS - Selects and ng-options

HTML

<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.6/angular.min.js"></script>
<div ng-app="myApp" ng-controller="MainController">
  <select ng-model="selectedModel" ng-options="device as device.text for device in devices track by device.id">
  </select>
  <h5>{{selectedModel}}</h5>
</div>

JavaScript

var myApp = angular.module('myApp', []);

myApp.controller('MainController', function($scope) {
  $scope.selectedModel;
  $scope.devices = [{
    id: 1,
    text: "Device1"
  }, {
    id: 2,
    text: "Device2"
  }];
});