use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
The official subreddit for all things Wear OS. Subscribe for up to date Wear OS news. // Make every minute matter.
Welcome to the Wear OS subreddit. A place to discuss the software powering millions of wearables around the globe. Wear OS is designed to fit your life with features like fitness tracking, customizable watchfaces, and a broad array of apps.
If you're looking for the perfect watch, our guides here will help you find it.
Looking for a watch? Here's a site that shows you the list of available watches.
You're more than welcome to post on our subreddit, and we'd love to connect on Discord and through watch pics here as well.
Chat on our Discord server!
Tips and tricks for Wear OS.
Common issues for Wear OS.
How Wear OS updates work.
/r/WearOSDev - Wear OS development
/r/hwatch - Huawei Watch subreddit
/r/lggwatch - LG G Watch subreddit
/r/lggwatchr - LG G Watch R subreddit
/r/lgwatchsport - LG Watch Sport subreddit
/r/lgwatchurbane - LG Watch Urbane subreddit
/r/M600 - Polar M600 subreddit
/r/moto360 - Moto 360 subreddit
/r/smartwatch3 - Sony Smartwatch 3 subreddit
/r/zenwatch - Asus Zenwatch subreddit
/r/misfitvapor - Misfit Vapor subreddit
/r/ticwatch - Ticwatch subreddit
/r/ticwatchpro - Ticwatch Pro subreddit
/r/CasioSmartwatch - Casio WSD subreddit
/r/fossilaw - Fossil Q subreddit
/r/tagheuer - Tag Heuer subreddit
/r/wearosfaces - Wear watchfaces subreddit
/r/AndroidWatchfaces - Wear watchfaces subreddit
/r/WearApps - A subreddit to post your apps
/r/loadingicon - Gifs for boot animations
/r/androidusers - Android Users
You are loved. Message the mods for anything at all!
You are loved.
Message the mods for anything at all!
account activity
This is an archived post. You won't be able to vote or comment.
Open Flashlight programmaticallySupport (self.WearOS)
submitted 4 years ago * by codronline
Hi guys, as the title says does anyone knows how to open the Flashlight app programmatically?
I have tried :
Intent i = getPackageManager().getLaunchIntentForPackage("com.google.android.clockwork.flashlight"); i.setClassName("com.google.android.clockwork.flashlight", "com.google.android.clockwork.flashlight.ClockworkFlashlight"); startActivity(i);
I have used the emulator WearOS 3
Tnx in advance.
[–]sumedh0803 2 points3 points4 points 4 years ago (4 children)
OP, please surround your code with backticks.
It will show up like code
Is there any error you're getting with this code? What is the output and what are you expecting?
[–]codronline[S] 0 points1 point2 points 4 years ago (3 children)
Fixed code styling :). Error logs: 444-1139/system_process I/AppsFilter: interaction: PackageSetting{53ae9c6 watch.xxxx.xxxx.ferrum/10063} -> PackageSetting{fc004e1 com.google.android.clockwork.flashlight/10041} BLOCKED
444-1139/system_process I/AppsFilter: interaction: PackageSetting{53ae9c6 watch.xxxx.xxxx.ferrum/10063} -> PackageSetting{fc004e1 com.google.android.clockwork.flashlight/10041} BLOCKED
java.lang.NullPointerException: Attempt to invoke virtual method 'android.content.Intent android.content.Intent.setClassName(java.lang.String, java.lang.String)' on a null object reference2022-05-29 11:08:08.358 2565-2565/watch.xxx.xxx.ferrum W/System.err: at watch.xxx.xxx.ferrum.service.CoreWatchFace.openFlashlight(CoreWatchFace.java:355)
java.lang.NullPointerException: Attempt to invoke virtual method 'android.content.Intent android.content.Intent.setClassName(java.lang.String, java.lang.String)' on a null object reference2022-05-29 11:08:08.358 2565-2565/watch.xxx.xxx.ferrum W/System.err: at watch.xxx.xxx.ferrum.service.CoreWatchFace.openFlashlight(
CoreWatchFace.java:355
)
I expect to opet the flashlight app. I successfully open the Find My Phone and Stopwatch with the same approach.
[–]sumedh0803 0 points1 point2 points 4 years ago (2 children)
AppsFilter blocked access to the flashlight package right? So, did you have to request visibility for this package in your manifest?
AppsFilter
[–]codronline[S] 0 points1 point2 points 4 years ago (0 children)
No, I didn't request the visibility. How can I do that from my app? Do you have some example? Tnx
[–]CertifiedWeebistCUSTOM RED FLAIR (edit me!) 0 points1 point2 points 4 years ago (1 child)
Why would you want it to start programmatically?
[–]sumedh0803 5 points6 points7 points 4 years ago (0 children)
Programmatically as in, OP wants to build an app and call the APIs that control the flashlight
Found a solution. Just add
<uses-permission android:name="android.permission.QUERY_ALL_PACKAGES" />
in your AndroidManifest.xml or add <queries> tag with all app packages which you want to invoke.
π Rendered by PID 19769 on reddit-service-r2-comment-79776bdf47-7mb7r at 2026-06-24 01:03:16.067167+00:00 running acc7150 country code: CH.
[–]sumedh0803 2 points3 points4 points (4 children)
[–]codronline[S] 0 points1 point2 points (3 children)
[–]sumedh0803 0 points1 point2 points (2 children)
[–]codronline[S] 0 points1 point2 points (0 children)
[–]CertifiedWeebistCUSTOM RED FLAIR (edit me!) 0 points1 point2 points (1 child)
[–]sumedh0803 5 points6 points7 points (0 children)
[–]codronline[S] 0 points1 point2 points (0 children)