Subscriptions to resources not working as expected
-
I am struggling with getting subscriptions working as expected. This is what I tested …
Subscribed in manifest …
/Activity/Move/-1/Speed/Current - OK
/Activity/Move/-1/Speed/Avg - Seems to return instantaneous value
/Activity/Lap/-1/Speed/Avg - OK
/Activity/Lap/-1/Speed/Max - returns NaN
/Activity/Lap/-1/Speed/Min - returns NaN
/Activity/Lap/-2/Speed/Avg - Seems to give average from current lapSubscribed resources are assigned to a JS variable, which is inspected in the simulator
function evaluate(input, output) {
// Copy resource to JS variable
mrDebug = input.SpeedAvg;Lap here is generated in code by …
// Trigger a silent lap
$.put(‘Activity/Trigger’, 24);Currently I am computing max HR and average pace for last lap in evaluate() but it would be nice to get it from the FW. Any suggestions?
Also I have tried having two subscriptions to the same resource but with different names (e.g. last lap average) in the manifest file. That does not seem to work, is this by design, i.e. only one subscription allowed?
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login