• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Best Practice to customize by device

RichardU

Lurker
I am using Tasker for several phones, tablets, etc. Most of my Profiles, Tasks are the same from one to the next. So I have a system to edit my Tasker Profiles on one device, then propagate to the other devices.

But sometimes, I want each device to act differently. So I would like for my single set of Profiles to know which device it is on, and I can set variables accordingly.

Is there a best practice for detecting the name of the current device, and when would that run?

Thanks, Richard
 
Device ID / Manufacturer / Model / Product
%DEVID / %DEVMAN / %DEVMOD / %DEVPROD
The ID, manufacturer, model and product name of the device.
Note: ID is not a unique identifier for the device, but rather for the hardware of the device. See also: %DEVTID.

taken from here
 
Nice list. Thanks, but I don't see anything to uniquely identify the device that would work for both phones and tablets. Any other ideas? Could I store a unique file on each device and somehow detect the differences?
 
As it says ... %DEVTID ... try ...

Show
A1: Popup [ Title: Text:%DEVTID Background Image: Layout:Popup Timeout (Seconds):5 Show Over Keyguard:On ]


... on my Droid Maxx it shows the MEID.

Yes instead you could have a global variable and set a different value in it for each device and then check it when you needed to know.

... Thom
 
I'm confused on the operation of Backup. If you hit Data / Backup, on Phone A it creates a file in the Tasker directory called: userbackup.xml. If you copy that file to Phone B in the Tasker directory, and then hit Data / Restore, I would expect that Phone B would look exactly like Phone A, but apparently Variables are not backed up by Data / Backup. Is that correct?
 
Local variables not in the current scope can't be, but I would think that global variables should be.
 
Back
Top Bottom