kopia lustrzana https://github.com/cyoung/stratux
Merge branch 'master' into jdp_dev
commit
cb1dbcf92f
|
@ -449,7 +449,11 @@ func cpuTempMonitor() {
|
||||||
if err == nil {
|
if err == nil {
|
||||||
tInt, err := strconv.Atoi(tempStr)
|
tInt, err := strconv.Atoi(tempStr)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
globalStatus.CPUTemp = float32(tInt) / float32(1000.0)
|
if tInt > 1000 {
|
||||||
|
globalStatus.CPUTemp = float32(tInt) / float32(1000.0)
|
||||||
|
} else {
|
||||||
|
globalStatus.CPUTemp = float32(tInt) // case where Temp is returned as simple integer
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -58,9 +58,7 @@
|
||||||
<script src="plates/js/logs.js"></script>
|
<script src="plates/js/logs.js"></script>
|
||||||
<script src="plates/js/settings.js"></script>
|
<script src="plates/js/settings.js"></script>
|
||||||
<script src="plates/js/status.js"></script>
|
<script src="plates/js/status.js"></script>
|
||||||
<!--
|
|
||||||
<script src="plates/js/towers.js"></script>
|
<script src="plates/js/towers.js"></script>
|
||||||
-->
|
|
||||||
<script src="plates/js/traffic.js"></script>
|
<script src="plates/js/traffic.js"></script>
|
||||||
<script src="plates/js/weather.js"></script>
|
<script src="plates/js/weather.js"></script>
|
||||||
<script src="js/j3di-all.min.js"></script>
|
<script src="js/j3di-all.min.js"></script>
|
||||||
|
@ -81,9 +79,7 @@
|
||||||
<a class="list-group-item" href="#/weather"><i class="fa fa-cloud"></i> Weather <i class="fa fa-chevron-right pull-right"></i></a>
|
<a class="list-group-item" href="#/weather"><i class="fa fa-cloud"></i> Weather <i class="fa fa-chevron-right pull-right"></i></a>
|
||||||
<a class="list-group-item" href="#/traffic"><i class="fa fa-plane"></i> Traffic <i class="fa fa-chevron-right pull-right"></i></a>
|
<a class="list-group-item" href="#/traffic"><i class="fa fa-plane"></i> Traffic <i class="fa fa-chevron-right pull-right"></i></a>
|
||||||
<a class="list-group-item" href="#/gps"><i class="fa fa-globe"></i> GPS/AHRS <i class="fa fa-chevron-right pull-right"></i></a>
|
<a class="list-group-item" href="#/gps"><i class="fa fa-globe"></i> GPS/AHRS <i class="fa fa-chevron-right pull-right"></i></a>
|
||||||
<!--
|
|
||||||
<a class="list-group-item" href="#/towers"><i class="fa fa-signal"></i> Towers <i class="fa fa-chevron-right pull-right"></i></a>
|
<a class="list-group-item" href="#/towers"><i class="fa fa-signal"></i> Towers <i class="fa fa-chevron-right pull-right"></i></a>
|
||||||
-->
|
|
||||||
<a class="list-group-item" href="#/logs"><i class="fa fa-file-text-o"></i> Logs <i class="fa fa-chevron-right pull-right"></i></a>
|
<a class="list-group-item" href="#/logs"><i class="fa fa-file-text-o"></i> Logs <i class="fa fa-chevron-right pull-right"></i></a>
|
||||||
<a class="list-group-item" href="#/settings"><i class="fa fa-gear"></i> Settings <i class="fa fa-chevron-right pull-right"></i></a>
|
<a class="list-group-item" href="#/settings"><i class="fa fa-gear"></i> Settings <i class="fa fa-chevron-right pull-right"></i></a>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -23,12 +23,12 @@ app.config(function ($stateProvider, $urlRouterProvider) {
|
||||||
controller: 'StatusCtrl',
|
controller: 'StatusCtrl',
|
||||||
reloadOnSearch: false
|
reloadOnSearch: false
|
||||||
})
|
})
|
||||||
// .state('towers', {
|
.state('towers', {
|
||||||
// url: '/towers',
|
url: '/towers',
|
||||||
// templateUrl: 'plates/towers.html',
|
templateUrl: 'plates/towers.html',
|
||||||
// controller: 'TowersCtrl',
|
controller: 'TowersCtrl',
|
||||||
// reloadOnSearch: false
|
reloadOnSearch: false
|
||||||
// })
|
})
|
||||||
.state('weather', {
|
.state('weather', {
|
||||||
url: '/weather',
|
url: '/weather',
|
||||||
templateUrl: 'plates/weather.html',
|
templateUrl: 'plates/weather.html',
|
||||||
|
|
|
@ -48,7 +48,7 @@
|
||||||
<span class="col-xs-3 text-center">{{ahrs_heading}}°</span>
|
<span class="col-xs-3 text-center">{{ahrs_heading}}°</span>
|
||||||
<span class="col-xs-3 text-center">{{ahrs_pitch}}°</span>
|
<span class="col-xs-3 text-center">{{ahrs_pitch}}°</span>
|
||||||
<span class="col-xs-3 text-center">{{ahrs_roll}}°</span>
|
<span class="col-xs-3 text-center">{{ahrs_roll}}°</span>
|
||||||
<span class="col-xs-3 text-center">{{ahrs_alt}}'</span>
|
<span class="col-xs-3 text-center">{{ahrs_alt}} ft</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -124,10 +124,14 @@ function WeatherCtrl($rootScope, $scope, $state, $http, $interval) {
|
||||||
|
|
||||||
data_item.flight_condition = parseFlightCondition(obj.Type, obj.Data);
|
data_item.flight_condition = parseFlightCondition(obj.Type, obj.Data);
|
||||||
data_item.location = obj.Location;
|
data_item.location = obj.Location;
|
||||||
var dThen = parseShortDatetime(obj.Time);
|
s = obj.Time;
|
||||||
var dNow = new Date(obj.LocaltimeReceived);
|
data_item.time = s.substring(0, 2) + '-' + s.substring(2, 4) + ':' + s.substring(4, 6) + 'Z';
|
||||||
data_item.age = dThen.getTime();
|
// we can not accurately determime the current time on the Stratux
|
||||||
data_item.time = utcTimeString(Math.abs(dNow - dThen)) + " old";
|
// calculating age of a weather report is indeterminate
|
||||||
|
// var dThen = parseShortDatetime(obj.Time);
|
||||||
|
// var dNow = new Date(obj.LocaltimeReceived);
|
||||||
|
// data_item.age = dThen.getTime();
|
||||||
|
// data_item.time = utcTimeString(Math.abs(dNow - dThen)) + " old";
|
||||||
data_item.received = utcTimeString(obj.LocaltimeReceived);
|
data_item.received = utcTimeString(obj.LocaltimeReceived);
|
||||||
data_item.data = obj.Data;
|
data_item.data = obj.Data;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,9 @@
|
||||||
<div class="section text-left help-page">
|
<div class="section text-left help-page">
|
||||||
<p>The <strong>Towers</strong> page provides a list of recent towers which have been received. Each time a new tower is received, it is added to the list. Each time new messages are received from an existing tower, the list is updated. If no messages are received from a tower for 5 minutes, the tower is removed from the list.</p>
|
<p>The <strong>Towers</strong> page provides a list of the towers from which UAT message have been received within the last minute.</p>
|
||||||
<p>more details will be added here eventually :-)</p>
|
<p>For each tower, the list includes the following details:</p>
|
||||||
|
<ul class="list-simple">
|
||||||
|
<li><strong>Location</strong> - the latitude and longitude of the tower</li>
|
||||||
|
<li><strong>Signal</strong> - teh signal strength reported by the tower</li>
|
||||||
|
<li><strong>Msgs</strong> - the number of messages (traffic or weather) received from teh tower in the last minute</li>
|
||||||
|
</ul>
|
||||||
</div>
|
</div>
|
|
@ -7,7 +7,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="panel-body towers-page">
|
<div class="panel-body towers-page">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<span class="col-xs-6"><strong>Tower</strong></span>
|
<span class="col-xs-6"><strong>Location</strong></span>
|
||||||
<span class="col-xs-3 text-right">Signal</span>
|
<span class="col-xs-3 text-right">Signal</span>
|
||||||
<span class="col-xs-3 text-right">Msgs</span>
|
<span class="col-xs-3 text-right">Msgs</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
Ładowanie…
Reference in New Issue