my widget code works pretty well on the FR935, F5/5S and 5X but as soon as I open up the scope to the VA3 some strange things happens (but only on some physical devices). The simulator shows zero problems on the VA3 and I borrowed one from a friend - this unit did also not show any problems. But some users complain about e. g. that the descending floors are not shown as a graph, but only the descending floors. The ascending floors are shown quiet normal although the only difference is the qualifier. Here is the code snippet:
function createHistArray(aHistArr, current, label) {
var arr = new [8];
arr = [0, 0, 0, 0, 0, 0, 0, 0];
arr[0] = current;
if (null != aHistArr && aHistArr.size() > 0) {
for (var i = 0; i < aHistArr.size() && i < 7; ++i) {
if (null != aHistArr&& null != aHistArr[label]) {
arr[i+1] = aHistArr[label];
}
}
}
return arr;
}
[/CODE]
The calls are pretty much the same:
floorsClimbedArr = createHistArray(hist, Amo.getInfo().floorsClimbed, :floorsClimbed);
floorsDescendedArr = createHistArray(hist, Amo.getInfo().floorsDescended, :floorsDescended);
I wrote some debug code for those users where the descending floors are not shown and the array is neither [0, 0, ...] not [null, null, ...] but nothing is printed on the physical device.
Furthermore some other strange things happens on some VA3 devices. E. g. a back command to the latest screen let crash the widget. But only some back commands not all.
Do you have any ideas how to debug this?