12345678910111213141516171819202122232425 |
- using Sensors.ANT;
- using Sensors.Polar;
- using UnityEngine;
- namespace Sensors
- {
- public class ListenToSensors : MonoBehaviour
- {
- public SpeedSensorConfig speedSensorConfig;
- public PolarSensorConfig polarSensorConfig;
- public int hrAntId;
- public int powerMeterId;
- private void Start()
- {
- BikeSensorData.Instance.StartListening(speedSensorConfig, polarSensorConfig, powerMeterId,
- hrAntId < 0 ? null : new int?(hrAntId));
- }
- private void OnDestroy()
- {
- BikeSensorData.Instance.Dispose();
- }
- }
- }
|