1. Pressure and Depth Measurements on Gamin Devices - Connect IQ App Development Discussion - Connect IQ - Garmin Forums
   URL: https://forums.garmin.com/developer/connect-iq/f/discussion/6354/pressure-and-depth-measurements-on-gamin-devices
   Pressure and Depth Measurements on Gamin Devices - Connect IQ App Development Discussion - Connect IQ - Garmin Forums

- Replies 0 replies
- Subscribers 15 subscribers
- Views 1924 views
- Users 0 members are here

Options

Related

# Pressure and Depth Measurements on Gamin Devices

Here is a video and some insights on my experience in working with pressure and depth measurements on Garmin devices. My diving apps are available at www.diveiq.com https://www.youtube.com/watch?v=rt-yz88q4LE&t=41s This video shows depth being computed using three different methods for obtaining pressure on Garmin devices.1) Raw ambient pressure: As measured by the pressure sensor.2) Ambient pressure: A smoothed, two-stage filtered pressure provided by Garmin which reduces noise and instantaneous variation.3) Altitude pressure: Pressure derived from the altitude .Many Garmin watches have a pressure sensor that Garmin uses internally to compute altitude. This sensor's data was only available internally to Garmin software and not made available to third party developers. Third party apps such as DiveIQ's Dive Computer and Freedive apps were forced to convert altitude back to pressure. This reverse conversion works pretty accurately but introduces some lag (delay) because it takes a few seconds for pressure changes to reflect on the altitude. Applications deriving pressure from altitude also need to be capable of coping with altitude decalibration because the altitude measurement provided by Garmin does not solely depend on pressure. The altitude also depends on multiple user settings that Garmin uses to determine if changes in pressure are due to changes in weather or changes in altitude. GPS measurements and manual calibrations are also taken into account. Garmin now provides two pressure measurements. A "raw ambient pressure" value taken directly from the sensor and an "ambient pressure" value smoothed by a two-stage filter that reduces noise and instantaneous variation. This video shows shows the response time and accuracy when using each pressure measurement method to compute depth in meters.

- Sign in to reply
- Cancel

2. Freediving Depth Data Field - Connect IQ App Development Discussion - Connect IQ - Garmin Forums
   URL: https://forums.garmin.com/developer/connect-iq/f/discussion/4028/freediving-depth-data-field
   Freediving Depth Data Field - Connect IQ App Development Discussion - Connect IQ - Garmin Forums

- Replies 12 replies
- Subscribers 19 subscribers
- Views 5216 views
- Users 0 members are here

Options

Related

# Freediving Depth Data Field

Recently I noticed that the very useful freediving data field called "Depth" has disappeared from the Connect IQ Store. I have no Idea why and I also don't remember the author of this data field. Because I need this data field and because I want to be able to record the data, I now try to code it myself. Only problem is that I currently run into some difficulties: -There seems to be no way to get the pressure reading from the barometer into a data field, because it would use the Sensor module which is not allowed to be used for a data field, only for an app (Gives error when put in manifest file). -And taken that it could be done anyhow, it most likely could not be done with Info.pressure because according to the API documentation this would return a pressure value corrected with the current altitude, whereas I would need the raw value to calculate the diving depth. So, my big question is: How did the author of this freediving depth data field achieve this?? Can anybody give me a hint with this? PS: Yes, I know that there exists a diving computer app at www.diveiq.com. But it’s quite expensive and not ideal for freediving. What I really want is just a data field to show me the current depth, which creates a FIT-File to show the depth as a graph in Garmin Connect.

- Sign in to reply
- Cancel

## Top Replies

- Don't confuse the water rating (how deep you can take the watch) with what pressures you can read with the watch. If I recall, some devices max out pressure readings at a depth that would work for…

## All Replies

You may want to check this sticky thread, as this is why the DF is now gone. https://forums.garmin.com/showthread.php?362498-Diving-related-Apps

> You may want to check this sticky thread, as this is why the DF is now gone. https://forums.garmin.com/showthread.php?362498-Diving-related-Apps

First thanks a lot for the quick answer. I was already expecting something like this. Honestly I think that’s a really bad decision made by Garmin here. Isn’t it each user’s own responsibility whether he wants to risk damaging his watch or not? I mean he bought it didn’t he? Ok. I see the point, that Garmin does not want to get sued, by users who “accidentally” destroyed their watch while using a diving app, but is banning all the diving apps really the way to go? Wouldn’t it be enough to make it mandatory to display a big fat red warning message when installing diving apps, which the user has to confirm? Then it would be 100% his own fault, if he broke his watch. This being said, could anybody help me with my coding related questions?

You might be able to use the altitude value provided inside the Activity.Info. If you go to 5m below the surface, the altimeter will show A. At 10m, it might show B... If you take measurements at various depths, you can establish a function that takes the altitude returned by the device and converts it to a depth. It would take a lot of testing to verify the correctness, but it seems that it might be a reasonable approach.Of course you could always try go contact the author of that original data field, and find out how he did it. Given that his data field was removed from the app store, he's probably going to be willing to share the source code with those that are interested.Travis

Depends on which watch you're developing for. For fenix 5 you can read raw pressure. I built exactly this data field today. Pop me a pm if you're interested. Cheers

Hi Niall,

I'm interested in this data field.

Can you help me, please? Thanks

Hi, have you had any luck?

Hi Marphy43

I know that it is now 5 years since you asked this question.

But I accidently saw your question just now. I were the author of the Depth gauge and the Max Depth gauge datafields that were on Connect IQ for a while.

The data fields were intended for use for fun when freediving etc.

I originally made it for Fenix3 and it were compatible with a few more devices. As I recall it, they were active for about a year and there were more than 3000 downloads and a lot of great reviews and no complaints.

I were working on other datafields for freediving like eg. surface time, time of last dive etc.

But, then one day I received a email from Garmin, stating that the Fenix3 and other compatible devices were never supposed to be used as a watch for diving and that the datafields were now removed from connect IQ.

It even stopped working on my own watch :-)

So yeah I spend time and effort on something that were loved and used by a lot of users, but it ended up being banned.

I used data from the altimeter to measure the depth. I wrote in an old thread how I did it here: https://forums.garmin.com/developer/connect-iq/f/app-ideas/974/freediving-depth-meter-surf-time

That's really sad, to hear.I was Hopping to Cross load this feature to the Instinct 2.0...It shows just how much Garmin tries too squeeze every Cent of its End User which Software Upgradeable Features that could and should be Free on a +400€ Watch...Want a Diving Feature? Nah, just buy another Watch for 800€...Want VO2Max? We could Software add it but nah, New Model for additional 400€while Dropping the Worth of your 2-Year-Old Watch by 60% without warning...I would say its about Time to Create an Open Source Rugged Smartwatch alternative that's Freely Configurable to your Needs.Will be Interesting to see, how long till this comment gets Taken down...Sorry for the Rant

You want to check out the App Approval Exceptions: https://forums.garmin.com/developer/connect-iq/w/wiki/10/app-approval-exceptions

Extreme Sports

Apps designed for scuba diving, free diving, skydiving, base-jumping, and extreme flight sports will not be listed on the app store for the following reasons:

- The diving features available on the Descent Mk1 are the only Garmin features intended for underwater diving use.
- The altimeter/barometer feature available in some Garmin devices is intended to be used for general altitude reference only, and is not intended to be used for extreme sports such as skydiving, base-jumping or other activities that require the use of equipment that is designed and intended for such use. The Jumpmaster feature on the Garmin tactix Bravo watch is intended to be used for skydiving activities by experienced skydivers. This is the only Garmin feature that is intended for use while skydiving.

Thanks for your Answer,About "[...] or other activities that require the use of equipment that is designed and intended for such use."the Instinct Tactic Series has also an Base Jumping Activity.And I doubt that the Barometric Sensor differs across the Series.The Instinct is Rated for 10 Bar, so technically a depth of 100m.Normal Scuba Diving goes to ~30m, 50-60m at max. so the Specification would suffice.For Apnoe it's Technically Possible, but i doubt that even a dwindling Minority can surpass a depth of 50 m.I know that for Scuba Diving Watches of 20 Bar are recommended as minimum Requirement.So technically this is right. But you could Inform the User about that and let him Accept an Agreement, like with the aviation-specific apps if thats a Problem.Like "Not Intended for Usage as Reference, only for Data Recording additionally the Watch is not Intended to be Used for this Use Case" Your Answer got my Hope up, that it might be Possible to get that App from other Sources, if you know what you are doing?Because it Technically says "will not be listed" not that its not allowed...Assumed Cross Loading is Possible.Could you Point me in such Direction?Or could you @Miguel_Hermann post it even on a Github Repo, so not everyone has to Recode it himself?

3. Water depth with instinct 2 - Connect IQ App Development Discussion - Connect IQ - Garmin Forums
   URL: https://forums.garmin.com/developer/connect-iq/f/discussion/290491/water-depth-with-instinct-2/1404491
   Water depth with instinct 2 - Connect IQ App Development Discussion - Connect IQ - Garmin Forums

- Replies 25 replies
- Subscribers 19 subscribers
- Views 9361 views
- Users 0 members are here

Options

Related

# Water depth with instinct 2

Good afternoon all

My instinct2 has the same barometer sensor as the G1 so iv been told. Im trying to make a water depth data field, but the simulator app crashes. I'm fairly new to monkey c could one of you experts read it over and tell me where im going wrong

```
import Toybox.Activity;
import Toybox.Lang;
import Toybox.Time;
import Toybox.WatchUi;
import Toybox.Sensor;

class valueView extends WatchUi.SimpleDataField {

    function initialize() {
        SimpleDataField.initialize();
        label = "Water depth M";
    }

     var x = Activity.getActivityInfo().ambientPressure;
     var y = ((x - 1013)/9.9) ; //1013 average sea level pressure Pr, h=(P-Pr)/(rho * g '=9.9')
    function compute(info as Activity.Info) as Numeric or Duration or String or Null {
        return y ;
    }

}
```

- Sign in to reply
- Cancel

## Top Replies

- There is a missing "}"after line 17. and a missing ";" on line 17

## All Replies

Pressure is not directly related to altitude and calibration occurs based on GPS, but GPS isn't that great for altitude.

You can be at the exact same spot and pressure changes. If you look at altitude (after using GPS for something, is it correct?

When you hear the pressure on a weather report, that's often the sea level pressure as the altitude will result in different pressurs with ambien. So there is also meanSeaLevelPressure and that too is available:

### var meanSeaLevelPressure as Lang.Float or Null

The mean sea level barometric pressure in Pascals (Pa).

This returns barometric pressure calibrated to sea level. Since pressure varies dues to several factors, a GPS-based altitude must first be obtained, then the ambient (local) pressure is measured by the pressure sensor before conversion to a calibrated barometric pressure value.

I' not sure Garmin had this (arguably interesting idea) in their mind when they released the pressure data in the sdk. It's mainly for calculating altitude changes during activity or counting how many floors you climbed. It'll be interesting to see how accurate it'll work for calculating water depth. Though there's the Descent watch that seems to be marketed towards divers.

Devices can limit the data under water so it can't be used for diving, Only Descent devices have been certified for that. In app approval exceptions it specifically talks about diving apps.

Apps designed for scuba diving, free diving, skydiving, base-jumping, and extreme flight sports will not be listed on the app store for the following reasons:

- The diving features available on the Descent Mk1 are the only Garmin features intended for underwater diving use.
- The altimeter/barometer feature available in some Garmin devices is intended to be used for general altitude reference only, and is not intended to be used for extreme sports such as skydiving, base-jumping or other activities that require the use of equipment that is designed and intended for such use. The Jumpmaster feature on the Garmin tactix Bravo watch is intended to be used for skydiving activities by experienced skydivers. This is the only Garmin feature that is intended for use while skydiving.

That's seems to give accurate results now with the code below just putting in an offset. It would be good to just be able to read barometer after correction/calibration like the suunto watches. Yes i appreciate you should not rely on this data for any critical activities. I had looked at the G1 and had my finger was on the bin button but could not justify it for a swimming pool and the occasional snorkelling. Thanks

```
import Toybox.Activity;
import Toybox.Lang;
import Toybox.Time;
import Toybox.WatchUi;
import Toybox.Sensor;

class valueView extends WatchUi.SimpleDataField {

    function initialize() {
        SimpleDataField.initialize();
        label = "Water depth M";
    }
   function compute(info as Activity.Info) as Numeric or Duration or String or Null {
        var x=((info.ambientPressure/100)+28.1);//conversion Pa to Mb + error
        var y=0;
    if(x!=null) {
            y = -((x - 1013.25)/100.7); //1013 average sea level pressure Pr, h=(P-Pr)/((sea water 1027kg*9.81m/s sq)/10') data displayed in - neg for depth
    }
       return y ;
        }
   }
```

Hello all

Iv noticed custom data fields don't get logged say like HR, anyway to log custom data fields for viewing in Garmin connects app ?

Use fit contrib for user data and define how it's displayed in Garmin Connect using fitcontib resources

Hi Jim, thanks for your reply. would you have any literature on how to use fit contrib ?

Thanks

Yes.

Thanks, would you have a working example of the code being implemented?

4. Documentation for data available on watches - Connect IQ App Development Discussion - Connect IQ - Garmin Forums
   URL: https://forums.garmin.com/developer/connect-iq/f/discussion/256905/documentation-for-data-available-on-watches
   Documentation for data available on watches - Connect IQ App Development Discussion - Connect IQ - Garmin Forums

- Replies 10 replies
- Subscribers 18 subscribers
- Views 3519 views
- Users 0 members are here

Options

Related

# Documentation for data available on watches

We are preparing to write an app for the fenix 6, and a companion app for the iPhone that it syncs with via bluetooth. As part of that, we're trying to find clear documentation of what sensor data is available, and what format it is in. For example, to calculate heart rate variability, do we get the raw PPG files, or has it been processed into timecodes for heart beats? So far, we're having trouble locating that documentation for devices. The "Devices Reference" (link below) only provides information on graphical displays.

- Sign in to reply
- André Zunido likes this" data-format="{count}" data-configuration="Format=%7Bcount%7D&IncludeTip=true">
- Cancel

Have you looked at the samples in the SDK? Or the API doc?

We weren't able to find anything in the API documentation (link below).

The programmers guide (link below) has only brief descriptions of the sensor functions.

As far as the SDK samples, does that mean we have to dig through the code in each sample to see what sensor data is available? Also, does the SDK sample code have specs for different watches?

You may want to check this section of the API documentation:

This may be of interest: https://developer.garmin.com/connect-iq/api-docs/Toybox/Sensor/Info.html

(I believe most or all of this sensor data has already been preprocessed/filtered/calibrated -- i.e. it's not "raw sensor data"):

The Sensor.Info class contains all of the information provided by enabled sensors.

Sensor.Info can be retrieved on every call of onUpdate() or it can be obtained on demand. accelThe accelerometer reading of the x, y, and z axes as an Array of Number values in millig-units.

altitudeThe altitude above mean sea level in meters (m).

cadenceThe cadence in revolutions per minute (rpm).

headingThe true north referenced heading in radians.

heartRateThe heart rate in beats per minute (bpm).

magThe magnetometer reading of the x, y, and z axes as an Array of Number values in milliGauss (mG).

oxygenSaturationThe current oxygen saturation in percent (%).

powerThe power in Watts (W).

pressureThe barometric pressure in Pascals (Pa).

speedThe speed in meters per second (m/s).

temperatureThe temperature in degrees Celsius (C).

And this:

A class to encapsulate all high-frequency sensor data that can be retrieved.

pitchThe Array of pitch values as Floats in degrees.

powerThe Array of vector power values as Numbers in millig-units.

rollThe Array of roll values as Floats in degrees.

xThe Array of x axis values as Numbers in millig-units.

yThe Array of y axis values as Numbers in millig-units.

zThe Array of z axis values as Numbers in millig-units.

var heartBeatIntervals ⇒ Toybox.Lang.Array

The most recent beat-to-beat interval data as an Array of Number objects in milliseconds (ms).

Very helpful!

Are you aware of a list of data available by device? Or should we just assume, for example, that devices with O2 sensors have the oxygenSaturation variable available, etc.?

Or should we just assume, for example, that devices with O2 sensors have the oxygenSaturation variable available, etc.?

That's probably a safe bet.

If you want to determine that at run-time, you can use the has operator:

var info = Sensor.Info.getInfo();

if (info has :oxygenSaturation) {

// ...}

If you want to know the available sensors per-device (sort of), you can look in the CIQ Devices folder and examine simulator.json for each device.

1) Open devices folder:

Windows: %appdata%\garmin\connectiq\devices

Mac/Linux (unconfirmed): ~/garmin/connectiq/devices

2) Open {DEVICENAME}\simulator.json and navigate to sensorHistory (at the top level). e.g. For venu:

"sensorHistory": [ { "interval": 120, "size": 180, "type": "heartrate" }, { "interval": 120, "size": 180, "type": "elevation" }, { "interval": 120, "size": 180, "type": "temperature" }, { "interval": 120, "size": 180, "type": "pressure" }, { "interval": 3600, "size": 168, "type": "pulseox" } ]

If you wanted to collect this information for all devices in a single file, you could use jq to aggregate, filter and reshape the data.

With o2, readings are only taken something like every 15 minutes, and history is saved every hour, but last I checked, that's also saved from oldest to newest, so backwards from what you might expect.

Also, this is only available on watches running CIQ 3.2 or higher.

Good to know.

Thanks again for the help! Does the watch provide respiratory rate data? Generally, we would calculate that from the raw PPG. If I go to my Garmin Connect webportal, I can see my respiratory rate over the course of a workout. That leads me to think RR should be available.

Not available with CIQ. There's data used or generated by first beat that's not exposed in CIQ.

As said before, look at the data in Sensors. That's what you have access to,. And then only in some app types, and possibly only if those sensors are enabled. For example, OHR, by default you see the less accurate 24/7 data, but when enabled, you see better data, and in this case, it could also be data from an external HRM.

Temperature in most cases is only available with an external Tempe sensor.

If you look at the Sensor sample in the SDK, you see a simple app that accesses HR and graphs it.

5. finfinack/depth
   URL: https://github.com/finfinack/depth
   # finfinack/depth

Data field for Garmin watches (Tactix, Fenix, Epix) to display water depth.

- Stars: 1
- Forks: 0
- Watchers: 1
- Open issues: 0
- License: Apache License 2.0
- Default branch: main
- Created: 2024-06-14T19:01:18Z

## Languages

- Monkey C

## Topics

- fenix
- garmin-connect-iq
- garmin-sdk
- garmin-watch
- measurement
- tactix
- water-depth

## Top Contributors

- finfinack (8 contributions)

---

## README

# Depth

This is a data field for Garmin watches (Fenix, Epix, Tactix) displaying the current water depth.

See https://developer.garmin.com/connect-iq/connect-iq-basics/ for some information around how to set up the Garmin SDK, compile and run the app. The following is mostly a copy of one of the [examples on the Garmin Connect IQ developer page](https://developer.garmin.com/connect-iq/connect-iq-basics/your-first-app/#yourfirstconnectiqapp).

## Running the Program

You should be able to run the app from Visual Studio Code in an Emulator:

- Before running the program, make sure you have one of your source files (in the `source` folder with the `.mc` extension) open and selected in the editor.
- Select `Run > Run Without Debugging` (`Command + F5` on Mac, `Ctrl + F5` on other platforms)
- You will be prompted with the list of products your application supports. Select one from the list.

## Side Loading an App

The Monkey C extension provides a wizard to help developers side load an application. The wizard will create an executable (PRG) of the selected project. Here’s how to use it:

- Plug your device into your computer
- Use `Ctrl + Shift + P` (`Command + Shift + P` on the Mac) to summon the command palette
- In the command palette type “Build for Device” and select `Monkey C: Build for Device`
- Select the product you wish to build for. If you are unable to choose a device for which to build (the menu appears empty), it means that there are no valid devices configured for your project.
- Choose a directory for the output and click `Select Folder`
- In your file manager, go to the directory selected in step 4
- Copy the generated `PRG` files to your device’s `GARMIN/APPS` directory

finfinack/depth


1. Install Apps manually - Venu 2 - Health & Wellness - Garmin Forums
   URL: https://forums.garmin.com/sports-fitness/healthandwellness/f/venu-2/268681/install-apps-manually
   Install Apps manually - Venu 2 - Health & Wellness - Garmin Forums

- Cancel
- More
- German Forum
- Beta Program
- Developer
- Pilots
- Sports & Fitness
- Outdoor Recreation
- Apps & Software

Related

This discussion has been locked.

You can no longer post new replies to this discussion. If you have a question you can start a new discussion

# Install Apps manually

Is there a way to install Apps manually? cause there is no version for the Venu2. For Example for the app SmartWakePro or the koomot app.

I cant find a way to download the App files in Windows to transfer it to the watch with the explorer.

- Cancel

You mean side load an app?

I wouldn't recommend that unless you are developing an app.

If an app doesn't support a specific device there is generally a reason. It could be lack of hardware support for functionality, display constraints, etc.

If an app isn't supported on the Venu 2, you should contact the author and ask them to implement it.

Yes, you can transfer a file directly to the watch in Windows explorer. You'd have to get the app file from the developer. Plug the cable into your watch and the computer. Then copy and paste into the appropriate folder on the watch.

As mentioned, you'd be taking a chance if it doesn't support the Venu 2.

2. How to sideload widgets to Fenix 3 HR for testing? - Connect IQ App Development Discussion - Connect IQ - Garmin Forums
   URL: https://forums.garmin.com/developer/connect-iq/f/discussion/4070/how-to-sideload-widgets-to-fenix-3-hr-for-testing
   How to sideload widgets to Fenix 3 HR for testing? - Connect IQ App Development Discussion - Connect IQ - Garmin Forums

- Cancel
- More
- German Forum
- Beta Program
- Developer
- Pilots
- Sports & Fitness
- Outdoor Recreation
- Apps & Software

- Users 0 members are here
- Views 2098 views
- Subscribers 15 subscribers
- Replies 2 replies

- files
- sideload
- eclipse
- fenix 3

Options

- Cancel
- More
- Share

Related

# How to sideload widgets to Fenix 3 HR for testing?

I'm attempting to sideload a test widget to my Fenix 3 HR via USB. In the past, I've been able to build a full file from the SDK, and then simply add it to the device's root folder on my computer. Now, all of the files on the device are .FIT and I cannot seem to get a widget .prg on it! Obviously I'm newer to this so please excuse any incorrect wording/descriptions. In short, how do I get a widget onto my device for testing without having to upload to the store and download to my device? I'm using Java Eclipse to work in. Regards, Nash

- Cancel
- Sign in to reply

I think I answered my own question. Signing! I need to upgrade my SDK to 2.1?

For signing, yes, you'll need a 2.x SDK. Also, the .prg goes into the \garmin\apps directory on the watch.

3. Venu 2 Series Owner's Manual - Downloading Connect IQ Features Using Your Computer
   URL: https://www8.garmin.com/manuals/webhelp/GUID-D93137A9-B374-4A24-8A4D-A66C9AC91265/EN-US/GUID-18B744AE-FBE0-4022-9A43-D8A89D7DAFAB.html
   Venu 2 Series Owner's Manual - Downloading Connect IQ Features Using Your Computer

Downloading Connect IQ Features Using Your Computer

# Downloading Connect IQ Features Using Your Computer

1. Connect the watch to your computer using a USB cable.
2. Go to apps.garmin.com, and sign in.
3. Select a Connect IQ™ feature, and download it.
4. Follow the on-screen instructions.

GUID-D93137A9-B374-4A24-8A4D-A66C9AC91265 v6

September 2023

4. VENU 2/2S Owner’s Manual
   URL: https://www8.garmin.com/manuals-apac/webhelp/venu22s/EN-SG/GUID-65691725-B262-48D5-9167-1A846D62D9CF-5040.html
   VENU 2/2S Owner’s Manual

### VENU 2/2S Owner’s Manual

# Connect IQ Features

You can add Connect IQ features to your watch from Garmin and other providers using the Connect IQ app. You can customize your device with watch faces, data fields, glances, and apps.

Watch Faces: Allow you to customize the appearance of the clock.

Data Fields: Allow you to download new data fields that present sensor, activity, and history data in new ways. You can add Connect IQ data fields to built-in features and pages.

Glances: Provide information at a glance, including sensor data and notifications.

Apps: Add interactive features to your watch, such as new outdoor and fitness activity types.

Downloading Connect IQ Features

Downloading Connect IQ Features Using Your Computer

###### Previous

###### Next

###### Highlight

###### Share

###### Print

5. Venu - side loaded .PRG is not working - Connect IQ App Development Discussion - Connect IQ - Garmin Forums
   URL: https://forums.garmin.com/developer/connect-iq/f/discussion/411316/venu---side-loaded-prg-is-not-working
   Venu - side loaded .PRG is not working - Connect IQ App Development Discussion - Connect IQ - Garmin Forums

- Replies 7 replies
- Subscribers 18 subscribers
- Views 1435 views
- Users 0 members are here

Options

Related

# Venu - side loaded .PRG is not working

I am side loading my Watch App .prg using OpenMTP on Mac into the /GARMIN/APPS folder....then when I disconnect the power cable it shows the Verifying Connect IQ loading spinner...promising, but the App doesn't appear in the apps list. The .prg file is removed from the /APPS folder however

Anyone know why this doesn't work on the Venu watch? I can install Apps ok from the Connect IQ store but I'm not ready to publish it yet, side loading works ok for me on my FR255M

Thanks for any insights

- Sign in to reply
- Cancel

Brandon mentioned beta firmware, but I wouldn't be surprised that it may be rolling out to production FW any day now.

Do you see an error in the CIQ_LOG file? What SDK are you using to build the sideload?

are you sure you copied the prg built for the venu? I think I saw this happening in the past when I accidentally used the wrong prd file or buit it for another device.

Yes I have built the .PRG for the Venu and it works ok on the simulator

I have my SDK Manager set to SDK 6.2.0 and manifest has minSdkVersion="3.0.0"

Ah yes just checked the CIQ_LOG.YML and it has...Error: 'Signature check failed on file: MYAPP.debug'Time: 2025-05-09T04:26:18ZPart-Number: 006-B1234-00Firmware-Version: '7.80'Language-Code: eng

Looks like the issue you mentioned above

You need to use the 7.4.3 SDK or greater per Bandon's post. Sound like the device has the "Q2" firmware (Q2="Second quarter" update)

Ah yea, changed the SDK and its working now, thanks guys

Brandon.ConnectIQ maybe we could have a pinned post with some knowledge for new members with some links, tips, etc. One of the 1st things I'd add is to always use the latest SDK version (maybe the one before if there's a knows issue with the latest) before you ask about something in the forum...

VENU 2/2S Owner’s Manual


I have a lot of useful information now. Let me summarize what I found:

**Garmin Venu 2:**
- Water rating: 5 ATM (withstands pressure equivalent to 50m depth)
- However, this is "Swim" rating, not diving. 5 ATM means suitable for swimming, not diving.
- Has wrist-based heart rate, barometric altimeter, GPS, etc.
- Pool swimming only (not for diving)
- Cannot record wrist heart rate while swimming
- AMOLED touchscreen
- Connect IQ support

**Garmin Fenix 3:**
- Water rating: 10 ATM (100m depth)
- Still only rated for surface swimming, not diving. Manual explicitly states: "The device is intended for surface swimming. Scuba diving with the device may damage the product and will void the warranty."
- Cannot record heart rate data while swimming
- Has barometric altimeter, GPS, etc.
- Connect IQ support

**Garmin Fenix 5:**
- Water rating: 10 ATM (100m depth)
- Also intended for surface swimming only, not diving
- Cannot record wrist heart rate while swimming
- HRM-Tri/HRM-Swim accessories can record heart rate underwater
- Has barometric altimeter, GPS, etc.
- Connect IQ support
- Raw pressure can be read on Fenix 5

**Important Connect IQ restriction:**
Garmin has app approval exceptions: apps designed for scuba diving, free diving, skydiving, base-jumping will not be listed on the app store. The diving features on Descent Mk1 (and later Descent watches) are the only Garmin features intended for underwater diving use. The altimeter/barometer is intended for general altitude reference only, not for diving.

However, you can still build and sideload apps for personal use (not publish to store). The Fenix 5 supports reading raw pressure, which can be converted to depth. The Venu 2 has pressure sensor but uses altitude (calibrated pressure).

For underwater heart rate: wrist-based OHR doesn't work underwater reliably. Need chest strap HRM-Swim or HRM-Tri (ANT+) that stores data and downloads to watch after surfacing.

Depth measurement: Use barometric pressure sensor. Formula: depth = (P - P_surface) / (rho * g). For fresh water: ~100 Pa per meter. For salt water: ~102.7 Pa per meter. Activity.Info has ambientPressure in newer SDKs. For older devices, you might need to derive from altitude or use Sensor.Info.pressure.

Static breathhold: This is a timer function, easy to implement without sensors.

Dive time: Use Activity timer.

Distance in length: For depth - use pressure. For horizontal length - GPS doesn't work underwater. Could use accelerometer or require manual input, or use it only for surface swimming / snorkeling.

Uploading app:
- For personal sideload: Build PRG in VS Code with Monkey C extension, copy to /GARMIN/APPS/ folder on watch via USB. Need SDK signing for newer firmware.
- For store: Must pass Garmin approval; diving apps won't be approved for non-Descent devices.
- For Fenix 3: older SDK 2.x/3.x, .prg to /garmin/apps directory.

Now I need to write a structured implementation plan. The user asked to use "codebase context as needed" - but this isn't really a codebase project, it's a hardware/app development plan. I should use the research findings as constraints.

I should also consider whether to ask clarifying questions. The request is fairly broad but I have enough to make a plan. However, there are some open questions I should raise at the end.

Let me structure:

1. **Goal**: Create a personal/sideloaded Garmin Connect IQ app for freediving that tracks dive time, depth (from barometer), heart rate (via chest strap), and includes a static breath-hold timer, deployable on the user's existing Garmin watch.

2. **Constraints**:
   - Venu 2: 5 ATM (50m pressure equivalent), not rated for diving; no raw pressure in older SDK? Actually newer SDK has ambientPressure in Activity.Info.
   - Fenix 3: 10 ATM (100m), surface swimming only per warranty.
   - Fenix 5: 10 ATM (100m), raw pressure readable, best candidate but still not dive-rated.
   - Garmin bans diving apps in Connect IQ store; app must be sideloaded for personal use only.
   - Wrist HR does not work underwater reliably; need HRM-Swim/HRM-Tri chest strap for underwater HR.
   - GPS doesn't work underwater; horizontal distance only surface/snorkel, not dive.
   - Pressure-to-depth requires calibration and fresh/salt water density compensation.
   - Battery life: Venu 2 GPS up to 24h, Fenix 5 up to 24h, Fenix 3 up to 20h.

3. **Approach**:
   - Build a Connect IQ "app" (not data field) in Monkey C using VS Code + SDK.
   - Target Fenix 5 as primary device (raw pressure available); Fenix 3 and Venu 2 as secondary via altitude/pressure derivation.
   - Read barometric pressure each tick, compute depth relative to surface pressure.
   - Pair with HRM-Swim or HRM-Tri for underwater heart rate (stores data underwater, downloads at surface).
   - Implement breath-hold timer mode with countdown/vibrations.
   - Log custom FIT fields for depth and dive events.
   - Sideload via USB as personal app; do not submit to store.

4. **Steps** (numbered, actionable, verifiable):
   1. Choose target device and SDK version.
   2. Set up Connect IQ SDK and simulator.
   3. Create a new Connect IQ app project.
   4. Read barometric pressure and compute depth.
   5. Implement dive timer.
   6. Add heart rate support (surface + chest strap underwater).
   7. Build static breath-hold mode.
   8. Add data screens / UI.
   9. Log depth/dive data to FIT file.
   10. Build and sideload to watch.
   11. Test in controlled conditions (pool/shallow).

5. **Verification** for each step.

6. **Risks & Rollbacks**:
   - Water damage not covered by warranty.
   - App store rejection if try to publish.
   - Inaccurate depth from pressure due to weather changes/altitude calibration.
   - Wrist HR failure underwater.
   - Rollback: uninstall app, reset to factory defaults, use official pool swim profile.

7. **Open Questions**:
   - Max depth you actually plan to dive?
   - Fresh or salt water?
   - Do you have or are willing to buy HRM-Swim/Tri chest strap?
   - Are you okay with sideloading only (no store)?
   - Which watch will you use as primary?
   - Do you want depth alerts/safety features?
   - Are you comfortable with Monkey C / do you want me to implement?

I should make this clear and actionable. Let me write the plan.

# Structured Implementation Plan: Garmin Freediving App

## 1. Goal
Create a personal, sideloaded Garmin Connect IQ app that records freedive sessions (dive time, depth from barometric pressure, heart rate via compatible chest strap, and a static breath-hold timer) on the user’s existing Garmin watch.

## 2. Constraints
- **Hardware / water rating**
  - **Venu 2:** 5 ATM (pressure equivalent to ~50 m). Garmin classifies it as “Swim,” not dive-rated. Touchscreen AMOLED, no physical buttons for underwater use.
  - **fēnix 3:** 10 ATM (pressure equivalent to ~100 m). Garmin explicitly states it is “intended for surface swimming,” and scuba/free diving may void the warranty.
  - **fēnix 5:** 10 ATM (pressure equivalent to ~100 m). Same “surface swimming” limitation, but it exposes raw barometric pressure in Connect IQ, making it the most practical of the three for depth estimation.
- **Sensor limitations**
  - Wrist-based optical HR does **not** work reliably underwater on any of these watches.
  - Underwater heart rate requires an ANT+ chest strap such as **HRM-Swim** or **HRM-Tri**, which stores HR while submerged and downloads it to the watch when surfacing.
  - GPS does **not** work underwater, so horizontal “distance in length” can only be approximated from arm movement/accelerometer or logged only for surface swimming/snorkeling segments.
- **Connect IQ policy**
  - Garmin’s app-approval exceptions ban scuba, freediving, skydiving, and base-jumping apps from the Connect IQ Store. The app can only be used by **sideloading** the `.prg` file for personal use.
- **Depth measurement**
  - Depth must be derived from barometric pressure: `depth ≈ (P − P_surface) / (ρ · g)`.
  - Surface pressure must be calibrated at the start of the dive and may drift with weather/temperature.
  - fēnix 5 can read raw pressure directly; fēnix 3 and Venu 2 may need to derive pressure from altitude or use newer SDK `Activity.Info.ambientPressure` where available.

## 3. Approach
Build a single Connect IQ **app** (not a data field, because Sensor module access is restricted for data fields) in Monkey C using the latest compatible SDK. Target the **fēnix 5** as the primary device because raw pressure access is simplest; keep the **fēnix 3** and **Venu 2** as secondary targets using the pressure/altitude fallback. Implement three modes:
1. **Dive mode:** continuously samples pressure → depth, records elapsed dive time, and pairs with an ANT+ HR strap.
2. **Static breath-hold mode:** countdown timer with configurable target time and vibration cues.
3. **Surface / snorkel mode:** logs GPS track and horizontal distance when the watch is above water.

Log depth and dive events as custom FIT contributions so the data appears in Garmin Connect after sync.

## 4. Steps

| # | Task | Deliverable |
|---|------|-------------|
| 1 | **Pick the target device and SDK** | Decide whether to buy a fēnix 5 or use the fēnix 3/Venu 2. Download the latest Connect IQ SDK that still supports the chosen device (fēnix 3 requires SDK 2.x–3.x era; fēnix 5 and Venu 2 can use newer SDKs). |
| 2 | **Set up the development environment** | Install VS Code, the Monkey C extension, and the SDK manager. Verify by building the “Hello World” sample and running it in the device simulator. |
| 3 | **Create the app skeleton** | New Monkey C project with an app-type manifest, a main view, and a data-screen loop for dive / breath-hold / surface modes. |
| 4 | **Read pressure and compute depth** | Implement a sensor callback or `Activity.Info.ambientPressure`/altitude polling loop. Convert pressure to depth in meters, with fresh-water (≈100 Pa/m) and salt-water (≈102.7 Pa/m) switches. Calibrate surface pressure on mode entry. |
| 5 | **Implement the dive timer** | Start/stop activity timer on button press; display current depth, max depth, elapsed time, and current HR. Add lap marking per dive. |
| 6 | **Add heart-rate support** | Enable `Sensor.setEnabledSensors` for HR + ANT+. Test with both wrist HR (above water only) and an HRM-Swim/Tri chest strap for underwater storage. |
| 7 | **Build the static breath-hold mode** | A standalone timer with a settable target (e.g., 1:30, 2:00, etc.), countdown, periodic vibration cues, and final hold-time display. |
| 8 | **Design the UI / data screens** | Large, high-contrast fields for depth, time, and HR; use a font/layout that is readable underwater and with wet hands (fēnix physical buttons preferred). |
| 9 | **Log depth and dive events to FIT** | Use `FitContributor` to record custom fields: depth (m), max depth, surface interval, breath-hold duration, and lap events. Verify the generated `.fit` file in the simulator or on device. |
| 10 | **Build and sideload** | Generate a signed `.prg` with the Monkey C “Build for Device” command, copy it to `GARMIN/APPS/` via USB, and confirm it appears in the watch’s apps list. |
| 11 | **Test in controlled conditions** | Start in a swimming pool at shallow depth (1–3 m) with a known reference, compare watch depth to measured depth, and validate HR download from the chest strap. |

## 5. Verification
| Step | How to confirm it works |
|------|--------------------------|
| 1 | Check device compatibility matrix in the SDK’s `devices.xml` / simulator; confirm the chosen device is listed and the SDK version compiles for it. |
| 2 | Run the sample app in the simulator; ensure it launches without build errors and produces a `.prg`. |
| 3 | Launch the app in the simulator; verify the three modes can be switched and no runtime errors appear in the CIQ console. |
| 4 | Simulate pressure changes in the device simulator or move the watch up/down in air; confirm computed depth is plausible and surface calibration resets correctly. |
| 5 | Start/stop the timer; check that elapsed time increments and pauses correctly, and max depth updates. |
| 6 | Pair a real or simulated HRM; confirm HR value appears in the UI and, for HRM-Swim/Tri, that stored data downloads after “surfacing.” |
| 7 | Run breath-hold mode; confirm countdown reaches zero, vibrations fire, and final time is accurate. |
| 8 | Test UI readability at arm’s length and with simulated sunlight/wet-screen overlays; confirm buttons are mapped correctly on non-touch devices. |
| 9 | Save an activity in the simulator, open the resulting `.fit` in a FIT viewer, and verify the custom depth/dive fields are present. |
| 10 | Sideload to watch; check the watch’s app list, `CIQ_LOG.YML` for “signature check passed,” and that the app launches. |
| 11 | Compare pool-depth readings against a measured reference; verify HR data appears in Garmin Connect after syncing. |

## 6. Risks & Rollbacks
| Risk | Mitigation / Rollback |
|------|----------------------|
| **Water damage voids warranty** | Use the watch only at shallow depths initially; never exceed the manufacturer’s “surface swimming” guidance. Rollback: stop using the app for diving and revert to the built-in pool-swim profile. |
| **Depth reading is inaccurate** | Calibrate surface pressure before every session; allow a warm-up dive; include a fresh/salt-water setting. Rollback: disable depth field and rely on time-only logging. |
| **App cannot be published to the store** | Plan from the start for personal sideloading only; do not submit to Connect IQ Store. Rollback: none needed—keep the `.prg` for personal use. |
| **Wrist HR fails underwater** | Require or recommend an HRM-Swim/Tri strap for any underwater HR logging. Rollback: use HR only during surface intervals or omit HR from underwater dives. |
| **Battery dies mid-dive** | Reduce GPS/Bluetooth usage in dive mode; warn user to start with >80 % battery. Rollback: use shorter sessions or carry a backup dive computer. |
| **Sideloading fails after firmware update** | Rebuild with the latest SDK that matches the watch firmware; check `CIQ_LOG.YML` for signature errors. Rollback: remove the app and restore default watch settings. |

## 7. Open Questions
Before implementation starts, these need clarification:

1. **Target watch:** Will you buy a fēnix 5, or do you want the app to run on the fēnix 3 or Venu 2 you already own?
2. **Maximum depth:** How deep do you realistically plan to freedive? (This affects whether the 5 ATM / 10 ATM rating is even relevant and how accurate the pressure-based depth needs to be.)
3. **Heart-rate accessory:** Do you already own, or are you willing to buy, an **HRM-Swim** or **HRM-Tri** chest strap for underwater HR?
4. **Water type:** Will you train mostly in fresh water (pool/lake) or salt water (ocean)? This changes the depth-conversion constant.
5. **Distribution:** Are you okay with **sideloading only** and not publishing to the Connect IQ Store?
6. **Safety features:** Do you want configurable depth/time/vibration alerts (e.g., “turnaround at 25 m”), or just post-dive review?
7. **Implementation role:** Do you want to write the Monkey C code yourself, or should I implement the app for you in a follow-up step?


1. if possible for the watches i alraedy own, venu2 or fenix3
2. for now not more than 30meters


Create a structured implementation plan for: 1. if possible for the watches i alraedy own, venu2 or fenix3 2. for now not more than 30meters 3. the venu has heartrate include for the fenix i have the monitor 4. mainly feshwater or pool 5. only sideloading 6. would be great if possible 7. i would like you to build the app, but first if the mentioned watches would support anything like this? would they be able to meassure the depth consice? What limitations would i have with either watch?

Follow this format:
1. **Goal** — one-sentence objective
2. **Constraints** — existing code, dependencies, tests, or assumptions to respect
3. **Approach** — high-level strategy and rationale
4. **Steps** — numbered, actionable tasks small enough to verify one at a time
5. **Verification** — how to confirm each step works (tests, logs, manual checks)
6. **Risks & Rollbacks** — what could go wrong and how to undo safely
7. **Open Questions** — anything that needs clarification before starting

Use the codebase context as needed. Do not write implementation code yet; only produce the plan.


The user wants a structured implementation plan, specific for their watches: Venu 2 or Fenix 3, max depth 30m, freshwater/pool, sideloading only, HR included Venu 2 and Fenix has monitor. They want me to build the app, but first confirm if watches support it, measure depth concisely, limitations.

Need to research specifically: Connect IQ SDK support for Fenix 3 and Venu 2, pressure/depth API availability, raw ambient pressure, water rating, HR underwater constraints. Need also to see if there is existing codebase? The instruction says use codebase context as needed. We are in /home/liph. No codebase context for Garmin likely, but maybe need to check current directory. We have context-mode active. Should use context tools maybe for research? Since web research needed, but also maybe no local codebase. The task is plan only.

Need to be thorough. We need answer: would these watches support? Venu 2 5ATM but not dive-rated, touchscreen, no physical buttons, no raw pressure? Need verify via web. Fenix 3 is older, 10ATM, but Connect IQ SDK version may not support Sensor.Info.ambientPressure? We need check device compatibility and sensors.

We need fetch/index or search web. Use web_explore and ctx_fetch_and_index maybe. Let's search specific: "Garmin Venu 2 Connect IQ ambientPressure sensor", "Garmin Fenix 3 Connect IQ barometer raw pressure", "Connect IQ devices Venu 2 pressure sensor API". Also "freediving app Fenix 3 Venu 2 Connect IQ".

Question: Garmin Venu 2 Connect IQ pressure sensor ambientPressure barometer API SDK

Question: Garmin Fenix 3 Connect IQ pressure sensor barometer raw pressure SDK support

Question: Garmin Connect IQ water depth app Fenix 3 Venu 2 freediving limitations

Question: Garmin Venu 2 button controls underwater touchscreen swimming no physical buttons

Question: Garmin Fenix 3 warranty void diving 10 ATM surface swimming freediving


Reviewed 3 sources · synthesized answer with 3 findings

Too many requests · GitHub

Get the SDK | Connect IQ

- [web_fetch] Community/practical context: A collection of Connect IQ apps and libraries Purpose This repo is officially maintained by the Garmin Connect IQ team, containing a small set of reference examples and monkey barr
- [web_fetch] Community/practical context: You have exceeded a secondary rate limit. Please wait a few minutes before you try again; in some cases this may take up to an hour. Signing in may provide a higher rate limit if y
- [web_fetch] Community/practical context: By downloading any of the following SDKs, you accept our license agreement.This Connect IQ Developer Agreement (the "Agreement") between you and, if applicable, your company ("you"

Internal research: web_search ×1, web_fetch ×4, web_fetch_headless ×1

Findings
- [web_fetch] Community/practical context: A collection of Connect IQ apps and libraries Purpose This repo is officially maintained by the Garmin Connect IQ team, containing a small set of reference examples and monkey barr
- [web_fetch] Community/practical context: You have exceeded a secondary rate limit. Please wait a few minutes before you try again; in some cases this may take up to an hour. Signing in may provide a higher rate limit if y
- [web_fetch] Community/practical context: By downloading any of the following SDKs, you accept our license agreement.This Connect IQ Developer Agreement (the "Agreement") between you and, if applicable, your company ("you"

Sources
- [web_fetch] GitHub - garmin/connectiq-apps: A collection of Connect IQ apps.: https://github.com/garmin/connectiq-apps
- [web_fetch] Too many requests · GitHub: https://github.com/topics/garmin-api
- [web_fetch] Get the SDK | Connect IQ: https://developer.garmin.com/connect-iq/sdk/

Internal tools
Internal research: web_search ×1, web_fetch ×4, web_fetch_headless ×1

Caveat
Evidence is partial: the strongest readable sources were mostly community/practical context.

Too many requests · GitHub

Get the SDK | Connect IQ


Home | Garmin Developers

- [web_fetch] Community/practical context: A collection of Connect IQ apps and libraries Purpose This repo is officially maintained by the Garmin Connect IQ team, containing a small set of reference examples and monkey barr
- [web_fetch] Community/practical context: High-frequency raw sensor data capture from Garmin watches with live streaming to Android for storage and analysis. Overview Garmin watches contain powerful sensors (accelerometer,
- [web_fetch] Community/practical context: Garmin DevelopersBuild Something with Us Connect IQ™ SDKDevelop watch faces, data fields, widgets and apps for our wearable devices.Garmin Connect Developer ProgramDevelop custom a

Internal research: web_search ×1, web_fetch ×4, web_fetch_headless ×1

Findings
- [web_fetch] Community/practical context: A collection of Connect IQ apps and libraries Purpose This repo is officially maintained by the Garmin Connect IQ team, containing a small set of reference examples and monkey barr
- [web_fetch] Community/practical context: High-frequency raw sensor data capture from Garmin watches with live streaming to Android for storage and analysis. Overview Garmin watches contain powerful sensors (accelerometer,
- [web_fetch] Community/practical context: Garmin DevelopersBuild Something with Us Connect IQ™ SDKDevelop watch faces, data fields, widgets and apps for our wearable devices.Garmin Connect Developer ProgramDevelop custom a

Sources
- [web_fetch] GitHub - garmin/connectiq-apps: A collection of Connect IQ apps.: https://github.com/garmin/connectiq-apps
- [web_fetch] GitHub - GITvinceHub/garmin-raw-sensor-stream: High-frequency raw sensor data capture from Garmin watches with live streaming to Android for storage and analysis.: https://github.com/GITvinceHub/garmin-raw-sensor-stream
- [web_fetch] Home | Garmin Developers: https://developer.garmin.com/

Internal tools
Internal research: web_search ×1, web_fetch ×4, web_fetch_headless ×1

Caveat
Evidence is partial: the strongest readable sources were mostly community/practical context.

Home | Garmin Developers


Reviewed 2 sources · synthesized answer with 2 findings

- [web_fetch] Community/practical context: Freediver (Connect IQ) A personal freediving logger for Garmin watches that samples barometric pressure, converts it to depth (m), detects dives, and records a depth timeline plus
- [web_fetch] Community/practical context: General Go to the Apnea DYN or Apnea CWT application page and see if your model is on the compatibility list. Compatibility lists: Apnea DYN Apnea CWT Garmin has introduced a limit

Internal research: web_search ×1, web_fetch ×4, web_fetch_headless ×1

Findings
- [web_fetch] Community/practical context: Freediver (Connect IQ) A personal freediving logger for Garmin watches that samples barometric pressure, converts it to depth (m), detects dives, and records a depth timeline plus
- [web_fetch] Community/practical context: General Go to the Apnea DYN or Apnea CWT application page and see if your model is on the compatibility list. Compatibility lists: Apnea DYN Apnea CWT Garmin has introduced a limit

Sources
- [web_fetch] GitHub - BertilBraun/Freediver: Simple Garmin Watch App to track Freediving: https://github.com/BertilBraun/Freediver
- [web_fetch] Apnea: An application dedicated to freediving for your Garmin watch.: https://www.apnea.me/faq/

Internal tools
Internal research: web_search ×1, web_fetch ×4, web_fetch_headless ×1

Caveat
Evidence is partial: the strongest readable sources were mostly community/practical context.


Venu 2 Series Owner's Manual

- [web_fetch] Community/practical context: Previous TopicNext TopicDownload PDFPrint Page Going for a Pool Swim Press . Select Pool Swim. Select your pool size, or enter a custom size. Press to start the activity timer. Sta
- [web_fetch] Community/practical context: Contents Table of Contents Troubleshooting FAQs Bookmarks Table of Contents VENU 2 SERIES ® Owner's Manual Table of Contents Why is my Garmin Venu 2 Series watch battery draining q

Internal research: web_search ×1, web_fetch ×4, web_fetch_headless ×1

Findings
- [web_fetch] Community/practical context: Previous TopicNext TopicDownload PDFPrint Page Going for a Pool Swim Press . Select Pool Swim. Select your pool size, or enter a custom size. Press to start the activity timer. Sta
- [web_fetch] Community/practical context: Contents Table of Contents Troubleshooting FAQs Bookmarks Table of Contents VENU 2 SERIES ® Owner's Manual Table of Contents Why is my Garmin Venu 2 Series watch battery draining q

Sources
- [web_fetch] Venu 2 Series Owner's Manual: https://www8.garmin.com/manuals/webhelp/GUID-D93137A9-B374-4A24-8A4D-A66C9AC91265/EN-US/GUID-387D15DA-0A9D-47D0-BAB9-05CC2B97D65C.html
- [web_fetch] GARMIN VENU 2 SERIES OWNER'S MANUAL Pdf Download: https://www.manualslib.com/manual/2063536/Garmin-Venu-2-Series.html

Internal tools
Internal research: web_search ×1, web_fetch ×4, web_fetch_headless ×1

Caveat
Evidence is partial: the strongest readable sources were mostly community/practical context.

Venu 2 Series Owner's Manual


fēnix 3/HR - Swimming

- [web_fetch] Community/practical context: Get HelpGarmin Support CenterContentsExpand|CollapseIndexSearch GlossarySearch Results No search has been performed.Related ManualsEnglishEnglishPrevious TopicNext TopicDownload PD
- [web_fetch] Community/practical context: If you’re considering a Garmin watch for swimming, showering, or outdoor adventures, one of the most common questions is: are Garmin watches waterproof? The short answer is no Garm
- [web_fetch] Community/practical context: Garmin watches are widely known for fitness tracking, GPS accuracy, and outdoor durability. One of the most common questions users ask before buying is: are Garmin watches waterpro

Internal research: web_search ×1, web_fetch ×4, web_fetch_headless ×1

Findings
- [web_fetch] Community/practical context: Get HelpGarmin Support CenterContentsExpand|CollapseIndexSearch GlossarySearch Results No search has been performed.Related ManualsEnglishEnglishPrevious TopicNext TopicDownload PD
- [web_fetch] Community/practical context: If you’re considering a Garmin watch for swimming, showering, or outdoor adventures, one of the most common questions is: are Garmin watches waterproof? The short answer is no Garm
- [web_fetch] Community/practical context: Garmin watches are widely known for fitness tracking, GPS accuracy, and outdoor durability. One of the most common questions users ask before buying is: are Garmin watches waterpro

Sources
- [web_fetch] fēnix 3/HR - Swimming: https://www8.garmin.com/manuals/webhelp/fenix3/EN-US/GUID-AC68D94C-821E-4567-8705-F433CDEA5525.html
- [web_fetch] Are Garmin Watches Waterproof? A Complete Guide - ComputerCity: https://computercity.com/watches/are-garmin-watches-waterproof
- [web_fetch] Are Garmin Watches Waterproof? Complete Guide to Water Resistance, Swimming & Diving: https://www.exquisitetimepieces.com/blog/are-garmin-watches-waterproof-complete-guide-to-water-resistance-swimming-diving/

Internal tools
Internal research: web_search ×1, web_fetch ×4, web_fetch_headless ×1

Caveat
Evidence is partial: the strongest readable sources were mostly community/practical context.

fēnix 3/HR - Swimming


web_explore gives only synthesized findings; need specific details. Use ctx_fetch_and_index on relevant pages or ollama_web_search. Let's search specific for API.

Question: Garmin Connect IQ Venu 2 pressure sensor ambientPressure barometer raw pressure

Question: Garmin Connect IQ Fenix 3 pressure sensor raw barometer SDK

Question: Garmin Venu 2 physical buttons underwater operation touchscreen

Question: Garmin Fenix 3 diving warranty 10 ATM freediving

Question: Connect IQ FitContributor custom depth field app type required


1. Device Reference
   URL: https://developer.garmin.com/connect-iq/device-reference/venu2/
   Device Reference

MenuDevice Reference

Device Reference
[Garmin Developers](https://developer.garmin.com/)
#
* [Overview](https://developer.garmin.com/connect-iq/overview/)
*
* [Compatible Devices](https://developer.garmin.com/connect-iq/compatible-devices/)
*
* [API Docs](https://developer.garmin.com/connect-iq/api-docs/)
*
* [Get the SDK](https://developer.garmin.com/connect-iq/sdk/)
*
* [Submit an App](https://developer.garmin.com/connect-iq/submit-an-app/)
*
* [Stay Informed](https://developer.garmin.com/connect-iq/stay-informed/)
*
* [Connect IQ Basics](https://developer.garmin.com/connect-iq/connect-iq-basics/)
*
* [Monkey C](https://developer.garmin.com/connect-iq/monkey-c/)
*
* [Core Topics](https://developer.garmin.com/connect-iq/core-topics/)
*
* [User Experience Guidelines](https://developer.garmin.com/connect-iq/user-experience-guidelines/)
*
* [Personality Library](https://developer.garmin.com/connect-iq/personality-library/)
*
* [Connect IQ FAQ](https://developer.garmin.com/connect-iq/connect-iq-faq/)
*
* [Reference Guides](https://developer.garmin.com/connect-iq/reference-guides/)
*
* [App Review Guidelines](https://developer.garmin.com/connect-iq/app-review-guidelines/)
*
* [Monetization](https://developer.garmin.com/connect-iq/monetization/)
*
* [Device Reference](https://developer.garmin.com/connect-iq/device-reference/)
*
* [Approach® S50](https://developer.garmin.com/connect-iq/device-reference/approachs50/)
* [Approach® S60](https://developer.garmin.com/connect-iq/device-reference/approachs60/)
* [Approach® S62](https://developer.garmin.com/connect-iq/device-reference/approachs62/)
* [Approach® S70 42mm](https://developer.garmin.com/connect-iq/device-reference/approachs7042mm/)
* [Approach® S70 47mm](https://developer.garmin.com/connect-iq/device-reference/approachs7047mm/)
* [D2™ Air](https://developer.garmin.com/connect-iq/device-reference/d2air/)
* [D2™ Air X10](https://developer.garmin.com/connect-iq/device-reference/d2airx10/)
* [D2™ Bravo](https://developer.garmin.com/connect-iq/device-reference/d2bravo/)
* [D2™ Bravo Titanium](https://developer.garmin.com/connect-iq/device-reference/d2bravo-titanium/)
* [D2™ Charlie](https://developer.garmin.com/connect-iq/device-reference/d2charlie/)
* [D2™ Delta](https://developer.garmin.com/connect-iq/device-reference/d2delta/)
* [D2™ Delta PX](https://developer.garmin.com/connect-iq/device-reference/d2deltapx/)
* [D2™ Delta S](https://developer.garmin.com/connect-iq/device-reference/d2deltas/)
* [D2™ Mach 1](https://developer.garmin.com/connect-iq/device-reference/d2mach1/)
* [D2™ Mach 2](https://developer.garmin.com/connect-iq/device-reference/d2mach2/)
* [D2™ Mach 2 Pro](https://developer.garmin.com/connect-iq/device-reference/d2mach2pro/)
* [Descent™ G1 / G1 Solar](https://developer.garmin.com/connect-iq/device-reference/descentg1/)
* [Descent™ G2](https://developer.garmin.com/connect-iq/device-reference/descentg2/)
* [Descent™ Mk1](https://developer.garmin.com/connect-iq/device-reference/descentmk1/)
* [Descent™ Mk2 / Mk2i](https://developer.garmin.com/connect-iq/device-reference/descentmk2/)
* [Descent™ Mk2 S](https://developer.garmin.com/connect-iq/device-reference/descentmk2s/)
* [Descent™ Mk3 43mm / Mk3i 43mm](https://developer.garmin.com/connect-iq/device-reference/descentmk343mm/)
* [Descent™ Mk3i 51mm](https://developer.garmin.com/connect-iq/device-reference/descentmk351mm/)
* [Edge® 1030](https://developer.garmin.com/connect-iq/device-reference/edge1030/)
* [Edge® 1030 / Bontrager](https://developer.garmin.com/connect-iq/device-reference/edge1030bontrager/)
* [Edge® 1030 Plus](https://developer.garmin.com/connect-iq/device-reference/edge1030plus/)
* [Edge® 1040 / 1040 Solar](https://developer.garmin.com/connect-iq/device-reference/edge1040/)
* [Edge® 1050](https://developer.garmin.com/connect-iq/device-reference/edge1050/)
* [Edge® 130](https://developer.garmin.com/connect-iq/device-reference/edge130/)
* [Edge® 130 Plus](https://developer.garmin.com/connect-iq/device-reference/edge130plus/)
* [Edge® 520 Plus](https://developer.garmin.com/connect-iq/device-reference/edge520plus/)
* [Edge® 530](https://developer.garmin.com/connect-iq/device-reference/edge530/)
* [Edge® 540 / 540 Solar](https://developer.garmin.com/connect-iq/device-reference/edge540/)
* [Edge® 550](https://developer.garmin.com/connect-iq/device-reference/edge550/)
* [Edge® 820 / Explore](https://developer.garmin.com/connect-iq/device-reference/edge820/)
* [Edge® 830](https://developer.garmin.com/connect-iq/device-reference/edge830/)
* [Edge® 840 / 840 Solar](https://developer.garmin.com/connect-iq/device-reference/edge840/)
* [Edge® 850](https://developer.garmin.com/connect-iq/device-reference/edge850/)
* [Edge® 1000 / Explore](https://developer.garmin.com/connect-iq/device-reference/edge-1000/)
* [Edge® 520](https://developer.garmin.com/connect-iq/device-reference/edge-520/)
* [Edge® Explore](https://developer.garmin.com/connect-iq/device-reference/edgeexplore/)
* [Edge® Explore 2](https://developer.garmin.com/connect-iq/device-reference/edgeexplore2/)
* [Edge® MTB](https://developer.garmin.com/connect-iq/device-reference/edgemtb/)
* [Enduro™](https://developer.garmin.com/connect-iq/device-reference/enduro/)
* [Enduro™ 3](https://developer.garmin.com/connect-iq/device-reference/enduro3/)
* [epix™](https://developer.garmin.com/connect-iq/device-reference/epix/)
* [epix™ (Gen 2) / quatix® 7 Sapphire](https://developer.garmin.com/connect-iq/device-reference/epix2/)
* [epix™ Pro (Gen 2) 42mm](https://developer.garmin.com/connect-iq/device-reference/epix2pro42mm/)
* [epix™ Pro (Gen 2) 47mm / quatix® 7 Pro](https://developer.garmin.com/connect-iq/device-reference/epix2pro47mm/)
* [epix™ Pro (Gen 2) 51mm / D2™ Mach 1 Pro / tactix® 7 – AMOLED Edition](https://developer.garmin.com/connect-iq/device-reference/epix2pro51mm/)
* [eTrex® Touch](https://developer.garmin.com/connect-iq/device-reference/etrextouch/)
* [fēnix® 3 / tactix® Bravo / quatix® 3](https://developer.garmin.com/connect-iq/device-reference/fenix3/)
* [fēnix® 3 HR](https://developer.garmin.com/connect-iq/device-reference/fenix3-hr/)
* [fēnix® 5 / quatix® 5](https://developer.garmin.com/connect-iq/device-reference/fenix5/)
* [fēnix® 5 Plus](https://developer.garmin.com/connect-iq/device-reference/fenix5plus/)
* [fēnix® 5S](https://developer.garmin.com/connect-iq/device-reference/fenix5s/)
* [fēnix® 5S Plus](https://developer.garmin.com/connect-iq/device-reference/fenix5splus/)
* [fēnix® 5X / tactix® Charlie](https://developer.garmin.com/connect-iq/device-reference/fenix5x/)
* [fēnix® 5X Plus](https://developer.garmin.com/connect-iq/device-reference/fenix5xplus/)
* [fēnix® 6 / 6 Solar / 6 Dual Power](https://developer.garmin.com/connect-iq/device-reference/fenix6/)
* [fēnix® 6 Pro / 6 Sapphire / 6 Pro Solar / 6 Pro Dual Power / quatix® 6](https://developer.garmin.com/connect-iq/device-reference/fenix6pro/)
* [fēnix® 6S / 6S Solar / 6S Dual Power](https://developer.garmin.com/connect-iq/device-reference/fenix6s/)
* [fēnix® 6S Pro / 6S Sapphire / 6S Pro Solar / 6S Pro Dual Power](https://developer.garmin.com/connect-iq/device-reference/fenix6spro/)
* [fēnix® 6X Pro / 6X Sapphire / 6X Pro Solar / tactix® Delta Sapphire / Delta Solar / Delta Solar - Ballistics Edition / quatix® 6X / 6X Solar / 6X Dual Power](https://developer.garmin.com/connect-iq/device-reference/fenix6xpro/)
* [fēnix® 7 / quatix® 7](https://developer.garmin.com/connect-iq/device-reference/fenix7/)
* [fēnix® 7 Pro](https://developer.garmin.com/connect-iq/device-reference/fenix7pro/)
* [fēnix® 7 Pro - Solar Edition (no Wi-Fi)](https://developer.garmin.com/connect-iq/device-reference/fenix7pronowifi/)
* [fēnix® 7S](https://developer.garmin.com/connect-iq/device-reference/fenix7s/)
* [fēnix® 7S Pro](https://developer.garmin.com/connect-iq/device-reference/fenix7spro/)
* [fēnix® 7X / tactix® 7 / quatix® 7X Solar / Enduro™ 2](https://developer.garmin.com/connect-iq/device-reference/fenix7x/)
* [fēnix® 7X Pro](https://developer.garmin.com/connect-iq/device-reference/fenix7xpro/)
* [fēnix® 7X Pro - Solar Edition (no Wi-Fi)](https://developer.garmin.com/connect-iq/device-reference/fenix7xpronowifi/)
* [fēnix® 8 43mm](https://developer.garmin.com/connect-iq/device-reference/fenix843mm/)
* [fēnix® 8 47mm / 51mm / tactix® 8 47mm / 51mm / quatix® 8 47mm / 51mm](https://developer.garmin.com/connect-iq/device-reference/fenix847mm/)
* [fēnix® 8 Pro 47mm / 51mm / MicroLED / quatix® 8 Pro 47mm / 51mm](https://developer.garmin.com/connect-iq/device-reference/fenix8pro47mm/)
* [fēnix® 8 Solar 47mm](https://developer.garmin.com/connect-iq/device-reference/fenix8solar47mm/)
* [fēnix® 8 Solar 51mm / tactix® 8 Solar 51mm](https://developer.garmin.com/connect-iq/device-reference/fenix8solar51mm/)
* [fēnix® Chronos](https://developer.garmin.com/connect-iq/device-reference/fenixchronos/)
* [fēnix® E](https://developer.garmin.com/connect-iq/device-reference/fenixe/)
* [Forerunner® 165](https://developer.garmin.com/connect-iq/device-reference/fr165/)
* [Forerunner® 165 Music](https://developer.garmin.com/connect-iq/device-reference/fr165m/)
* [Forerunner® 170](https://developer.garmin.com/connect-iq/device-reference/fr170/)
* [Forerunner® 170 Music](https://developer.garmin.com/connect-iq/device-reference/fr170m/)
* [Forerunner® 230](https://developer.garmin.com/connect-iq/device-reference/fr230/)
* [Forerunner® 235](https://developer.garmin.com/connect-iq/device-reference/fr235/)
* [Forerunner® 245](https://developer.garmin.com/connect-iq/device-reference/fr245/)
* [Forerunner® 245 Music](https://developer.garmin.com/connect-iq/device-reference/fr245m/)
* [Forerunner® 255](https://developer.garmin.com/connect-iq/device-reference/fr255/)
* [Forerunner® 255 Music](https://developer.garmin.com/connect-iq/device-reference/fr255m/)
* [Forerunner® 255s](https://developer.garmin.com/connect-iq/device-reference/fr255s/)
* [Forerunner® 255s Music](https://developer.garmin.com/connect-iq/device-reference/fr255sm/)
* [Forerunner® 265](https://developer.garmin.com/connect-iq/device-reference/fr265/)
* [Forerunner® 265s](https://developer.garmin.com/connect-iq/device-reference/fr265s/)
* [Forerunner® 45](https://developer.garmin.com/connect-iq/device-reference/fr45/)
* [Forerunner® 55](https://developer.garmin.com/connect-iq/device-reference/fr55/)
* [Forerunner® 570 42mm](https://developer.garmin.com/connect-iq/device-reference/fr57042mm/)
* [Forerunner® 570 47mm](https://developer.garmin.com/connect-iq/device-reference/fr57047mm/)
* [Forerunner® 630](https://developer.garmin.com/connect-iq/device-reference/fr630/)
* [Forerunner® 645](https://developer.garmin.com/connect-iq/device-reference/fr645/)
* [Forerunner® 645 Music](https://developer.garmin.com/connect-iq/device-reference/fr645m/)
* [Forerunner® 70](https://developer.garmin.com/connect-iq/device-reference/fr70/)
* [Forerunner® 735xt](https://developer.garmin.com/connect-iq/device-reference/fr735xt/)
* [Forerunner® 745](https://developer.garmin.com/connect-iq/device-reference/fr745/)
* [Forerunner® 920XT](https://developer.garmin.com/connect-iq/device-reference/fr920xt/)
* [Forerunner® 935](https://developer.garmin.com/connect-iq/device-reference/fr935/)
* [Forerunner® 945](https://developer.garmin.com/connect-iq/device-reference/fr945/)
* [Forerunner® 945 LTE](https://developer.garmin.com/connect-iq/device-reference/fr945lte/)
* [Forerunner® 955 / Solar](https://developer.garmin.com/connect-iq/device-reference/fr955/)
* [Forerunner® 965](https://developer.garmin.com/connect-iq/device-reference/fr965/)
* [Forerunner® 970](https://developer.garmin.com/connect-iq/device-reference/fr970/)
* [Garmin Swim™ 2](https://developer.garmin.com/connect-iq/device-reference/garminswim2/)
* [GPSMAP® 66s / 66i / 66sr / 66st](https://developer.garmin.com/connect-iq/device-reference/gpsmap66/)
* [GPSMAP® 67 / 67i](https://developer.garmin.com/connect-iq/device-reference/gpsmap67/)
* [GPSMAP® 86s / 86sc / 86i / 86sci](https://developer.garmin.com/connect-iq/device-reference/gpsmap86/)
* [GPSMAP® H1 / H1i Plus](https://developer.garmin.com/connect-iq/device-reference/gpsmaph1/)
* [Instinct® 2 / Solar / Dual Power / dēzl Edition](https://developer.garmin.com/connect-iq/device-reference/instinct2/)
* [Instinct® 2S / Solar / Dual Power](https://developer.garmin.com/connect-iq/device-reference/instinct2s/)
* [Instinct® 2X Solar](https://developer.garmin.com/connect-iq/device-reference/instinct2x/)
* [Instinct® 3 AMOLED 45mm](https://developer.garmin.com/connect-iq/device-reference/instinct3amoled45mm/)
* [Instinct® 3 AMOLED 50mm](https://developer.garmin.com/connect-iq/device-reference/instinct3amoled50mm/)
* [Instinct® 3 Solar 45mm / 50mm](https://developer.garmin.com/connect-iq/device-reference/instinct3solar45mm/)
* [Instinct® Crossover](https://developer.garmin.com/connect-iq/device-reference/instinctcrossover/)
* [Instinct® Crossover AMOLED](https://developer.garmin.com/connect-iq/device-reference/instinctcrossoveramoled/)
* [Instinct® E 40mm](https://developer.garmin.com/connect-iq/device-reference/instincte40mm/)
* [Instinct® E 45mm](https://developer.garmin.com/connect-iq/device-reference/instincte45mm/)
* [Captain Marvel](https://developer.garmin.com/connect-iq/device-reference/legacyherocaptainmarvel/)
* [First Avenger](https://developer.garmin.com/connect-iq/device-reference/legacyherofirstavenger/)
* [Darth Vader™](https://developer.garmin.com/connect-iq/device-reference/legacysagadarthvader/)
* [Rey™](https://developer.garmin.com/connect-iq/device-reference/legacysagarey/)
* [MARQ® (Gen 2) Athlete / Adventurer / Captain / Golfer / Carbon Edition / Commander - Carbon Edition](https://developer.garmin.com/connect-iq/device-reference/marq2/)
* [MARQ® (Gen 2) Aviator](https://developer.garmin.com/connect-iq/device-reference/marq2aviator/)
* [MARQ® Adventurer](https://developer.garmin.com/connect-iq/device-reference/marqadventurer/)
* [MARQ® Athlete](https://developer.garmin.com/connect-iq/device-reference/marqathlete/)
* [MARQ® Aviator](https://developer.garmin.com/connect-iq/device-reference/marqaviator/)
* [MARQ® Captain / MARQ® Captain: American Magic Edition](https://developer.garmin.com/connect-iq/device-reference/marqcaptain/)
* [MARQ® Commander](https://developer.garmin.com/connect-iq/device-reference/marqcommander/)
* [MARQ® Driver](https://developer.garmin.com/connect-iq/device-reference/marqdriver/)
* [MARQ® Expedition](https://developer.garmin.com/connect-iq/device-reference/marqexpedition/)
* [MARQ® Golfer](https://developer.garmin.com/connect-iq/device-reference/marqgolfer/)
* [Montana® 7 Series](https://developer.garmin.com/connect-iq/device-reference/montana7xx/)
* [Oregon® 7 Series](https://developer.garmin.com/connect-iq/device-reference/oregon7xx/)
* [Rino® 7 Series](https://developer.garmin.com/connect-iq/device-reference/rino7xx/)
* [Venu®](https://developer.garmin.com/connect-iq/device-reference/venu/)
* [Venu® 2](https://developer.garmin.com/connect-iq/device-reference/venu2/)
* [Venu® 2 Plus](https://developer.garmin.com/connect-iq/device-reference/venu2plus/)
* [Venu® 2S](https://developer.garmin.com/connect-iq/device-reference/venu2s/)
* [Venu® 3](https://developer.garmin.com/connect-iq/device-reference/venu3/)
* [Venu® 3S](https://developer.garmin.com/connect-iq/device-reference/venu3s/)
* [Venu® 4 41mm](https://developer.garmin.com/connect-iq/device-reference/venu441mm/)
* [Venu® 4 45mm / D2™ Air X15](https://developer.garmin.com/connect-iq/device-reference/venu445mm/)
* [Venu® Mercedes-Benz® Collection](https://developer.garmin.com/connect-iq/device-reference/venud/)
* [Venu® Sq](https://developer.garmin.com/connect-iq/device-reference/venusq/)
* [Venu® Sq 2](https://developer.garmin.com/connect-iq/device-reference/venusq2/)
* [Venu® Sq 2 Music](https://developer.garmin.com/connect-iq/device-reference/venusq2m/)
* [Venu® Sq. Music Edition](https://developer.garmin.com/connect-iq/device-reference/venusqm/)
* [Venu® X1](https://developer.garmin.com/connect-iq/device-reference/venux1/)
* [vívoactive®](https://developer.garmin.com/connect-iq/device-reference/vivoactive/)
* [vívoactive® 3](https://developer.garmin.com/connect-iq/device-reference/vivoactive3/)
* [vívoactive® 3 Mercedes-Benz® Collection](https://developer.garmin.com/connect-iq/device-reference/vivoactive3d/)
* [vívoactive® 3 Music](https://developer.garmin.com/connect-iq/device-reference/vivoactive3m/)
* [vívoactive® 3 Music LTE](https://developer.garmin.com/connect-iq/device-reference/vivoactive3mlte/)
* [vívoactive® 4](https://developer.garmin.com/connect-iq/device-reference/vivoactive4/)
* [vívoactive® 4S](https://developer.garmin.com/connect-iq/device-reference/vivoactive4s/)
* [vívoactive® 5](https://developer.garmin.com/connect-iq/device-reference/vivoactive5/)
* [vívoactive® 6](https://developer.garmin.com/connect-iq/device-reference/vivoactive6/)
* [vívoactive® HR](https://developer.garmin.com/connect-iq/device-reference/vivoactive-hr/)
MenuDevice Reference

2. How to simply read pressure info? - Connect IQ App Development Discussion - Connect IQ - Garmin Forums
   URL: https://forums.garmin.com/developer/connect-iq/f/discussion/245448/how-to-simply-read-pressure-info
   How to simply read pressure info? - Connect IQ App Development Discussion - Connect IQ - Garmin Forums

- State Verified Answer
- Replies 24 replies
- Subscribers 18 subscribers
- Views 6795 views
- Users 0 members are here

Options

Related

# How to simply read pressure info?

Hello, may I please ask for help?

at beginning of code I set

using Toybox.Sensor;

and then in function onUpdate(dc) I am trying to read pressure with

var status = Sensor.getInfo();

var pres = status.pressure;

But at runtime I get error

Error: Permission RequiredDetails: Module 'Toybox.Sensor' not available to 'Watch Face'

What can I do please?

- Sign in to reply
- Cancel

## Top Replies

- Set the permission for that. You can do that in a watchface. In eclipse, click the manifest file and there is a tab for permissions.

## All Replies

Just that. You can't use Sensor in a watch face itself. You can use it in a watch face's background service.

Or you can get the pressure by way of SensorHistory.getPressureHistory() and look at the newest sample or Activity.getActivityInfo().ambientPressure.

Thanks for quick answer. I am trying to get pressure with Activity.Info.meanSeaLevelPressure;. However, it returns null. I suspect that GPS needs to function because of altitude. I started activity on watch, waited to get GPS lock but it still displays null.

I would prefer to get pressure from garmin weather info, is that possible?

Thanks, Jan

The garmin weather info doesn't include pressure.

When you tested meanSeaLevelPressure, was that on a watch or in the sim? What device? It's got to be one with a baro altimeter.

Tactix Delta, it does have barometer. I did not test it for long time and not outdoors, I will try later. Thank you very much for answers.

I tried var p = SensorHistory.getPressureHistory({});

but get runtime error:

Error: Permission RequiredDetails: Permission for module 'Toybox.SensorHistory' required

I tried var p = SensorHistory.getPressureHistory({});

but get runtime error:

Error: Permission RequiredDetails: Permission for module 'Toybox.SensorHistory' required

Set the permission for that. You can do that in a watchface. In eclipse, click the manifest file and there is a tab for permissions.

Thanks very much, it worked. My watch is now showing pressure taken from history :-)

We are using Activity.getActivityInfo().ambientPressure, meanSeaLevelPressure and rawAmbientPressure , and none of them seem to match the value of the pressure at GARMIN app, or the readings other watchfaces do. What are we missing??

Many things just use SensorHistory.getPressureHistory() and the newest sample.

3. Retrieve ambient pressure in foreground - Connect IQ App Development Discussion - Connect IQ - Garmin Forums
   URL: https://forums.garmin.com/developer/connect-iq/f/discussion/288741/retrieve-ambient-pressure-in-foreground
   Retrieve ambient pressure in foreground - Connect IQ App Development Discussion - Connect IQ - Garmin Forums

- Replies 11 replies
- Subscribers 18 subscribers
- Views 1953 views
- Users 0 members are here

Options

Related

# Retrieve ambient pressure in foreground

Toybox.Sensor.getInfo().ambientPressure needs the permission Toybox.Sensor - I don't have added this permission yet because until now I used the pressure history.

I realised that ambientPressure is the value I want to display and not the one from the history and want to change this now.

1) it seems like ambientPressure value can't be retrieved from history, correct?

2) I realised that Toybox.Sensor also needs the background permission, does this mean I can only read the ambientPressure in the background?

Actually I don't want to add 2 permissions for this single data value to my watchface, is there no alternative way to get the current pressure (or last in one from history)?

- Sign in to reply
- Cancel

With a watch face, you can only access Sensor data in a background service.

Try Activity.getActivityInfo().ambientPressure in the foreground

Be sure to handle devices without a baro altimeter

In the sim I can access ambientPressure without an exception but it returns null (without adding the necessary permissions though)... But you say, the foreground access won't work on a real device anyway, that's the important information for me. Btw, adding background + sensor permission approx. halves the available memory for a watchface (ERROR: PRG generated exceeds the memory limit of 'background' applications for device id 'fenix6xpro': 63883 bytes) - is this something I have to accept or can I circumvent this side effect?

Can't I alternatively convert pressure to ambientPressure with the history data?

In the sim, are you simulating data? Try Activity.Info on a real device with a baro if you have doubts.

Once you add background permission, you want to make sure you use the (:background) annotation where needed, otherwise it will try to load the entire WF when the background runs, inclusing when onAppInstall() or onAppUpdate() are called.

Now that I simulate data it shows a value - thanks. Even without adding additional permissions.

Oh, now I remember that in need to add :background annotations where needed to avoid my whole WF is running in the background - thanks.

So actually you say something different than I though - that real devices with baro allow to access Activity.getActivityInfo().ambientPressure in the foreground? So I just have to add the permissions, make sure my WF is running in foreground and it will work on a real device? Or will it work without the additional permissions in the foreground on a real device (as this is what I see in the sim)?

hi, no permission is need for Activity.getActivityInfo().ambientPressure

when Jim said "Be sure to handle devices without a baro altimeter" I think he means to check if the device has a Baro with

if(Activity.getActivityInfo() has :ambientPressure){...}

if you use this method, you don't need :Background annotation or permission.

Thanks, that answers all open questions. The unsure phrase for me was "you can only access Sensor data in a background service"

yes the module Sensor. but Activity is available from foreground.

Don't forget to check null statment

thanks for clarifying that. Btw, isn't the null check enough for class variables? I actually though the :has must only be used for functions...

hi, no it is not enough, if you try for exemple Activity.getActivityInfo().ambientPressure on a F45, it will crash since FR45 does not have ABC sensor.

see the API doc, you have lots of exemple of :has

You want to do the has check too. Devices like the fr45, fr55, fr245 and venu sq don't have a baro altimeter.

4. Ambient Pressure and Mean Seal Level Pressure Mismatch - Connect IQ App Development Discussion - Connect IQ - Garmin Forums
   URL: https://forums.garmin.com/developer/connect-iq/f/discussion/324960/ambient-pressure-and-mean-seal-level-pressure-mismatch
   Ambient Pressure and Mean Seal Level Pressure Mismatch - Connect IQ App Development Discussion - Connect IQ - Garmin Forums

- Replies 4 replies
- Subscribers 19 subscribers
- Views 1459 views
- Users 0 members are here

Options

- Share
- More
- Cancel

Related

# Ambient Pressure and Mean Seal Level Pressure Mismatch

I've been seeing a discrepancy between the watch-calculated mean sea level pressure and true calculations based on the watch-observed ambient pressure. Based on the actual mean sea level pressure in the area, the value returned from meanSeaLevelPressure appears inaccurate. Here are more specific details from the simulator using simulated data:

- Activity.Info.meanSeaLevelPressure returns a value of 102154.98 Pa (This is the seemingly incorrect value, should be 101045 Pa).
- Activity.Info.ambientPressure returns a value of 87026.59 Pa
- Activity.Info.altitude returns a value of 1242.70 m
- SensorHistory.getTemperatureHistory (the last value in the iteration) returns a temperature of 25.5 C

Using that ambient pressure (87026 Pa) and altitude (1242 m), the mean sea level pressure should be 101045 Pa1, or 99957 Pa2 with a Temperature correction. The returned meanSeaLevelPressure is substantially off using the Garmin API. There should be only a couple areas where that error could occur

1. The altitude used in meanSeaLevelPressure is substantially (roughly 100m) different than that of Activity.Info.altitude .
2. The temperature correction used in meanSeaLevelPressure is different than returned by SensorHistory.getTemperatureHistory , however the documentation of meanSeaLevelPressure only suggests it is corrected for altitude
3. The formulas used to calculate meanSeaLevelPressure in the API have an error.

Does anyone have any more insight into the specifics of the calculations and data Activity.Info.meanSeaLevelPressure utilizes? I'm consistently seeing errors in my watch face from actual measurements to the displayed data using the API data. Is there anything I may be missing?

---

References for calculations:

1) Elevation, Station (QFE) and Sea Level (QNH) Pressure Calculator (sensorsone.com)

2) Mean sea level pressure calculator (converter) (wind101.net)

- Sign in to reply
- Cancel

This is something you really want to look at on a real device and not the sim. To compute MSL pressure it needs ambient presume and elevation, and based on device there are different ways to calibrate the altitude/elevation. You can enter a specific value, use GPS, or DEM.

And then there's the case where you can be in the same location, but the weather, therefore ambient pressure, changes over time

And then even on a real device, getXyzHistory isn't real time, but is only saved every few minutes (you can tell how often by using the "when" values of two adjacent samples. In the sim some of this data is "canned" and doesn't change over time

Here for example are graphs of getPressureHistory and getTemperatureHistory in the sim. Both are canned and never change:

Thats a great thought --- I'll work on building a quick test app for my actual watch and update the post with that data if I'm seeing the same issue

Update with actual device data (still seeing the same issue as the sim, been monitoring the data for a couple hours):

Using the device measured ambient pressure and altitude, the non-temperature corrected value for MSL Pressure should be 98803.0 Pascals. Although that seems close, it is noticeably off when using inHg values for aviation.

The Garmin API meanSeaLevelPressure converts to an altimeter setting of 29.09 inHg. Using widely accepted calculations from the measured ambientPressure results in 98803.0 Pascals results in an altimeter setting of 29.18 inHg [actual value from weather service is 29.17 inHg].

What is interesting is the Garmin Barometer widget also shows the "correct" calculated value of 29.18 inHg. All this to say that the meanSeaLevelPressure value that is returned from the Garmin API neither matches the Garmin Barometer widget data, nor widely accepted calculation methods. Unless they're using some other method or pulling data from elsewhere, it seems like there's an error in the meanSeaLevelPressure calculations in Toybox.Activity.

I thought altitude was based on GPS reading .. my Mk1 is new to me and i am noticing that the altitude changes over a range of 10 m at my desk near the beach . currently 40m . assumed it was based on tide change (i keep the GPS on) .. . the pressure detection i assume is the same as the one used for depth on a dive which has to be a manometer of sorts (not calculated) & a critical datapoint.

- - Cancel
- - Up 0 Down
- Sign in to reply
- Cancel
- - Cancel
- - Up 0 Down
- Sign in to reply
- Cancel
- - meanSeaLevelPressure returns 98517.5 Pascals (still doesn't match typical calculations, should be 98803.0 Pascals)
- ambientPressure returns 88806.8 Pascals
- altitude returns 890.6 meters [actual altitude at location is 886.5 meters, this is pretty accurate]
- getTemperatureHistory returns 26.7 C
- - Cancel
- - Up 0 Down
- Sign in to reply
- Cancel
- - Cancel
- - Up 0 Down
- Sign in to reply
- Cancel

5. Using the simulator to test Edge 1030 internal barometer readings? - Connect IQ App Development Discussion - Connect IQ - Garmin Forums
   URL: https://forums.garmin.com/developer/connect-iq/f/discussion/399918/using-the-simulator-to-test-edge-1030-internal-barometer-readings
   Using the simulator to test Edge 1030 internal barometer readings? - Connect IQ App Development Discussion - Connect IQ - Garmin Forums

- State Not Answered
- Replies 17 replies
- Subscribers 19 subscribers
- Views 2679 views
- Users 0 members are here

Options

Related

# Using the simulator to test Edge 1030 internal barometer readings?

I am attempting to use the Edge 1030 internal barometer pressure information within my Connect IQ app.

Connect IQ Device Simulator 7.3.0

I set up the test using:

---------------

import Toybox.Sensor;

private var _info = null;

private var _barometer = Lang.Float;

_info = Sensor.Info;

_barometer = _info.pressure;

System.println(_barometer) // this prints 'null'

------------

My problem starts when I want to test the _barometer object with an actual simulated value. I don't know how to do this.

Running: Simulation -> Activity Data

doesn't seem to supply the _barometer with an actual value.

If I change the above code to:

System.println(_barometer.toString()) // throws errors

Any direction on this would be appreciated. Relatively new to Monkey C and Connect IQ

- Sign in to reply
- Cancel

## Top Replies

I had tried creating an instance of the class

In general, the correct way to create an instance of a class would be to use the new keyword.

e.g. var sensorInfo = new Sensor.Info();

The fact…

- The posted code isn't quite right.private var _info = null;private var _barometer = Lang.Float; // [1]_info = Sensor.Info; // [2] _barometer = _info.pressure;[1] it doesn't make sense to initialize…

## All Replies

Maybe Activity.Info.ambientPressure does the trick:

### var ambientPressure as Lang.Float or Null

The ambient pressure in Pascals (Pa).

This returns ambient (local) barometric pressure as measured by the pressure sensor. The data is smoothed by a two-stage filter to reduce noise and instantaneous variation.

Hadn't looked at this API yet. Produces the same results in the simulator though:

_info = Activity.Info;;

_barometer = _info.ambientPressure;

System.println(_barometer); // null value output to debug console

System.println(_barometer.toString()); // 'Encountered app crash'

Other readings have suggested that the internal barometer is unavailable in the simulator (which makes ensuring the object works as expected difficult while testing) and to just assign a dummy float as the barometric value in simulation. Really hoping this isn't the case and I can get some pressure values within the simulator.

If you have a real device, you could try recording an activity and using that as the data source during simulation.

But for what it's worth, I tried simulating activity data with both fr955 and edge1050, and I was able to get a value from Activity.Info.ambientPressure.

1) I create a simple data field project

2) My view's compute() function looks like this:

`function compute(info as Activity.Info) as Numeric or Duration or String or Null {``   return info.ambientPressure;`` }`

3) I run the app in the simulator and press the play button () in Simulator > Activity Data. (Yes, the UI here can be confusing - this has been a problem since the beginning, even though the UI has changed quite a bit.)

3a) Before pressing play:

3b) Press play:

3c) After pressing play:

_barometer = _info.pressure;

System.println(_barometer) // this prints 'null'

System.println(_barometer.toString()) // throws errors

_barometer = _info.ambientPressure;

System.println(_barometer); // null value output to debug console

System.println(_barometer.toString()); // 'Encountered app crash'

It's expected that if you call toString() (or any other method) on a null value, your app will crash, since methods can only be called on a valid object.

Since it's valid for either Sensor.Info.pressure or Activity.Info.ambientPressure to be null (according to the API docs / type info), this is a possibility you have to account for in your code, even when it runs on a real device.

The above procedure was successful on both SDK 7.4.3 (the latest) and 7.3.0.

Since it's valid for either Sensor.Info.pressure or Activity.Info.ambientPressure to be null (according to the API docs / type info), this is a possibility you have to account for in your code, even when it runs on a real device.

For example, native Garmin data fields will often display "--" when a value is null / unavailable / not applicable.

I'll try this a bit more. I knew how to turn on the 'Activity Data' within the simulator but not about the creation of the compute() function.

Just need to figure out how to show the return within my existing app. Using the return from the compute() function still throws errors when I attempt either System.println() or dc.drawText() when passing either _barometer.format("%.2f") or _barometer.toString() as paramters.

It's expected that if you call toString() (or any other method) on a null value, your app will crash, since methods can only be called on a valid object.

As flowstate has mentioned: you have to check for null before using the value in any method:

if ( _barometer != null ) { dc.drawText(x, y, font, _barometer.format(“%.2f“), center);} else { dc.drawText(x, y, font, “ - - “ , center);}

BTW: „return value“ in function compute() works only in simple datafields, whereas dc.drawText() works in onUpdate() only in complex datafields.

ps. This is an answer to mmcleod

The reminder to check for the null value first is appreciated, made testing easier.

Ran tests on the object using both compute() and dc.drawText() within onLayout(). So far my _barometer object remains null.

This has been tested using both Activity.Info and Sensor.Info objects. Activity Data in the simulator UI is running.

Everyone's tips are appreciated.

Not sure why simulated pressure data works for the fr955 and Edge1050, and not the Edge1030 I am running.

> Not sure why simulated pressure data works for the fr955 and Edge1050, and not the Edge1030 I am running.

I just tried edge1030 and it works fine.

> I knew how to turn on the 'Activity Data' within the simulator but not about the creation of the compute() function.

The compute[] function is only relevant for a simple datafield, as in my example. If you create a simple data field project, the compute[] function will automatically be added for you [with a default return value such as 0.0]. Since your project did not have a compute[] function, I assume it is not a simple datafield.

It's only a proof of concept but I was able to display barometric pressure in an app as follows:

1] Create a simple data field project:

- Open command palette [CTRL-SHIFT-P / CMD-SHIFT-P]

- Select "Monkey C: New Project"

- Enter project name

- Select Data Field

- Select Simple

- Select API level [this shouldn't matter, just pick the lowest one]

- Select the products to support

2] Modify the compute[] function [which should be generated as part of the new project] as follows:

`// The given info object contains all the current workout``// information. Calculate a value and return it in this method.``// Note that compute() and onUpdate() are asynchronous, and there is no``// guarantee that compute() will be called before onUpdate().``function compute(info as Activity.Info) as Numeric or Duration or String or Null {``   // See Activity.Info in the documentation for available information.``   return info.ambientPressure; // <==== add this line [and remove the existing line starting with "return..."]``}`

Note that you don't need any special logic to handle null here because a simple data field is allowed to return null [in which case it will display nothing for the value], and because a Numeric value [such as a Float pressure value] will automatically be formatted as shown above.

Ofc in your real app, you will probably want special null-handling logic as in mcinner1's example, and you will probably want precise control over the formatting.

But this is just a test, so returning the value itself [Float or null] without any special formatting should be fine.

3] Run the data field in the simulator

You should see the same results as I described above [except that the data field label won't be "pressure" unless you also change the part of the code that sets the label, which isn't really necessary for the test]

Once you have satisfied yourself that pressure data is indeed being simulated and displayed by your app, you can move on to trying to figure out why it isn't being displayed in your real app.

flowstate the above mock project works and displays the pressure data. This worked using the above assumption of 'Data Field' rather than an 'App' for the project. The above template works for both Activity.Info and Sensor.Info objects.

Going to figure out why it isn't working in my app.

Device Reference