Connect IQ > APIメモ > Toybox > Activity > Info

「Connect IQ/APIメモ/Toybox/Activity/Info」の編集履歴(バックアップ)一覧に戻る

Connect IQ/APIメモ/Toybox/Activity/Info - (2016/03/02 (水) 23:43:57) の編集履歴(バックアップ)


下位ページ

Content

Class: Toybox::Activity::Info

現在のアクティビティ情報をもつクラス。使う前には各フィールドのnullチェックを行うこと。
Activity.getActivityInfo()で取得された時点の値を持っている。(更新したい場合は再度取得する必要がある。)

属性


  • Time
    • (Number) elapsedTime : Activity の経過時間[msec]
    • (Moment) startTime : activity の開始時間
    • (Number) timerTime : 計測時間[ms]
  • Distance
    • (Float) elapsedDistance : 距離[m]
    • (Float) averageDistance : 水泳の(前のインターバルでの)ストロール平均距離[m]
  • Speed
    • (Float) currentSpeed : 現在速度[m/s]
    • (Float) averageSpeed : 平均速度[m/s]
    • (Float) maxSpeed : 現在のアクティビティの最高速度[m/s]
  • HeartRate
    • (Number) currentHeartRate : The current heart rate in beats per minute.
    • (Number) averageHeartRate : The average heart rate in beats per minute.
    • (Number) maxHeartRate : The maximum heart rate in beats per minute.
  • Cadence
    • (Number) currentCadence : 現在のケイデンス[rpm](ランニング中はピッチ[bpm])
    • (Number) averageCadence : セッション中の平均ケイデンス[rpm](ランニング中はピッチ[bpm])
    • (Number) maxCadence : セッション中の最大ケイデンス[rpm](ランニング中はピッチ[bpm])
  • Power
    • (Number) currentPower : The current power in watts.
    • (Number) averagePower : The average power in watts.
    • (Number) maxPower : The maximum power in watts.
  • Location
    • (Location) currentLocation : The current location.
    • (Location) startLocation : The starting location of the activity.
    • (Number) currentLocationAccuracy : GPS Accuracy (See the accuracy member of the Info object
  • Altitude
    • (Float) altitude : The altitude in meters.
    • (Float) totalAscent : The total ascent in meters.
    • (Float) totalDescent : The total descent in meters.
  • (Float) currentHeading : The current true north referenced heading in radians.
in the Position module for more information).
  • Calorie
    • (Number) calories :The current calories burned during the current activity being recorded in kcal.
    • (Float) energyExpenditure : Momentary energy expenditure in kcals/min (www.firstbeat.com/consumers/analyzed-by-firstbeat-features#4).
    • (Float) trainingEffect : Training Effect: The activity's level of effect on aerobic fitness.
  • Swim
    • (Number) swimStrokeType : The swim stroke type from the previous length.
    • (Number) swimSwolf : The swimming SWOLF score from the previous length.


Instance Attribute Details

(Number) elapsedTime : Activity の経過時間[msec]

途中で Session を停止させても、elaspedTime は経過し続ける。
  • Returns : (Number)
  • Since : 1.0.0

(Number) timerTime : 計測時間[ms]

途中で Session を停止させると、timerTime は停止する。Session を再び開始すると、そこから増加し始める。
  • Returns : (Number)
  • Since : 1.0.0

(Moment) startTime : activity の開始時間

Session.start() の時間。Moment は不変の値に使われる。
  • Returns : (Moment)
  • Since : 1.0.0

(Float) elapsedDistance : 距離[m]

  • Returns : (Float)
  • Since : 1.0.0

(Float) averageDistance : 水泳の(前のインターバルでの)ストロール平均距離[m]

  • Returns : (Float)
  • Since : 1.2.2

(Float) currentSpeed : 現在速度[m/s]

(See the speed member of the Info object in the Position module for more information)
  • Returns : (Float)
  • Since : 1.0.0

(Float) averageSpeed : 平均速度[m/s]

The average is computed as the elapsed 3-D accumulated distance divided by the elapsed time.
  • Returns : (Float)
  • Since : 1.0.0

(Float) maxSpeed : 現在のアクティビティの最高速度[m/s]

  • Returns : (Float)
  • Since : 1.0.0

(Number) currentHeartRate : 現在の心拍数[bpm]

  • Returns : (Number)
  • Since : 1.0.0

(Number) averageHeartRate : 平均心拍数[bpm]

The average heart rate in beats per minute
  • Returns : (Number)
  • Since : 1.0.0

(Float) altitude

The altitude in meters
  • Returns : (Float)
  • Since : 1.0.0

(Number) currentCadence : 現在のケイデンス[rpm](ランニング中はピッチ[bpm])

  • Returns : (Number)
  • Since : 1.0.0

(Number) averageCadence : セッション中の平均ケイデンス[rpm](ランニング中はピッチ[bpm])

  • Returns : (Number)
  • Since : 1.0.0

(Number) maxCadence セッション中の最大ケイデンス[rpm](ランニング中はピッチ[bpm])

  • Returns : (Number)
  • Since : 1.0.0


(Number) averagePower


The average power in watts

Returns:

   (Number)

  • Since : 1.0.0
  • Supported Devices : Forerunner 920XT, fenix 3, epix, All Edges

(Number) calories


The current calories burned during the current activity being recorded in kcal

Returns:

   (Number)

Since:

   1.0.0

(Float) currentHeading


The current true north referenced heading in radians. This value matches heading from the Positioning module. It will provide the direction of travel when moving. When stopped, it will provide compass orientation, if supported by the device.

Returns:

   (Float)

Since:

   1.0.0

(Location) currentLocation

The current location
  • Returns : (Location)
  • Since : 1.0.0

(Number) currentLocationAccuracy

GPS Accuracy (See the accuracy member of the Info object in the Position module for more information)
  • Returns : (Number) Position.QUALITY_XXX value
  • Since : 1.0.0

(Number) currentPower

The current power in watts
  • Returns : (Number)
  • Since : 1.0.0
  • Supported Devices : Forerunner 920XT, fenix 3, epix, All Edges

(Float) energyExpenditure

Momentary energy expenditure in kcals/min (www.firstbeat.com/consumers/analyzed-by-firstbeat-features#4)
  • Returns : (Float)
  • Since : 1.2.0

(Number) maxHeartRate

The maximum heart rate in beats per minute
  • Returns : (Number)
  • Since : 1.0.0

(Number) maxPower

The maximum power in watts

Returns:

   (Number)

  • Since : 1.0.0
  • Supported Devices : Forerunner 920XT, fenix 3, epix, All Edges

(Location) startLocation


The starting location of the activity

Returns:

   (Location)

Since:

   1.0.0

(Number) swimStrokeType

The swim stroke type from the previous length

Returns:

   (Number) —

   Activity.SWIM_STROKE_XXX value

Since:

   1.2.2

  • (Number) swimSwolf

The swimming SWOLF score from the previous length

Returns:

   (Number)

Since:

   1.2.2

(Float) totalAscent


The total ascent in meters

Returns:

   (Float)

Since:

   1.0.0

  • (Float) totalDescent

The total descent in meters

Returns:

   (Float)

Since:

   1.0.0

  • (Float) trainingEffect

Training Effect: The activity's level of effect on aerobic fitness. (www.firstbeat.com/consumers/analyzed-by-firstbeat-features#3)

Returns:

   (Float)

Since:

   1.2.0