Can someone tell me how to make a rectangle indicator that shows the state of certain things.
For example, Red = off, Green = On
I want this for:
Wi-fi
Bluetooth
Cell Data
NFC
Charging
I think its possible but could not find a post that gives an example of the text/parameters.
Thanks in advance!
sleepingsword said:
Can someone tell me how to make a rectangle indicator that shows the state of certain things.
For example, Red = off, Green = On
I want this for:
Wi-fi
Bluetooth
Cell Data
NFC
Charging
I think its possible but could not find a post that gives an example of the text/parameters.
Thanks in advance!
Click to expand...
Click to collapse
Only wifi, cell data and charging are possible without external tools. For the other ones you would need Tasker to send the values because Zooper has no internal variables for their states.
The general solution for this type of indicator would be to add a Rect module and then set an Advanced Parameter on it that changes the color depending on the state of whatever setting you want to have indicate by it. For the build-in variables you should check this page for their possible states and the associated meaning. As an example, here is the Advanced Parameter for a Rect module to indicate the state of wifi:
Code:
[c]$#NWSTATE#>=1?ff00ff00:ffff0000$[/c]
To understand the structure of these conditionals, please see this page.
Perfect, just what I needed. Thanks kwerdenker.
sleepingsword said:
Perfect, just what I needed. Thanks kwerdenker.
Click to expand...
Click to collapse
Sure, no problem
Happens to me as well and now I'm looking for the solution in a custom rom
Related
I want to use the numerical values of #BLEV# (battery level) and #WCHUM# (weather, current humidity) in calculations. In the first case to change the dimension of a rectangle, in the second case to calculate the rotation of a pointer in an analog gauge.
Both values are supplied by ZW as percentiles, complete with the "%" character which renders them unusable in a calculation. I have tried using $(#BLEV#)$ and $(#WCHUM#)$ - which works to remove the units in #WCTEMP# and #WCPRESS# - but it won't work in these two cases.
Is there a solution?
TIA
Terry
gritpipethin said:
I want to use the numerical values of #BLEV# (battery level) and #WCHUM# (weather, current humidity) in calculations. In the first case to change the dimension of a rectangle, in the second case to calculate the rotation of a pointer in an analog gauge.
Both values are supplied by ZW as percentiles, complete with the "%" character which renders them unusable in a calculation. I have tried using $(#BLEV#)$ and $(#WCHUM#)$ - which works to remove the units in #WCTEMP# and #WCPRESS# - but it won't work in these two cases.
Is there a solution?
TIA
Terry
Click to expand...
Click to collapse
Try using #BLEVN# and #WCHUMN#. I know the batt Lev one works, so I'm assuming that just adding 'N' at the end of a variable will output the numerical value only.
Hope this helps.
Cheers.
Majik Mushroomz said:
Try using #BLEVN# and #WCHUMN#. I know the batt Lev one works, so I'm assuming that just adding 'N' at the end of a variable will output the numerical value only.
Hope this helps.
Cheers.
Click to expand...
Click to collapse
#BLEVN# works beautifully (and I should have found that myself), but #WCHUMN# is not, as they say, a happening thing.
Thanks.
Thanks for your time. Two questions, #1: I've been around here and throughout other sites, and found (it seems) dozens of different options but none have seemed to work regarding getting an object to follow a CIRCULAR progress bar. In this case, I have a simple clock that I would like to have a sunrise icon and sunset icon (each) move around the outside the clock at the appropriate time. I have tried multiple codes and combos to no avail. I have successfully managed to achieve this result on a straight prog bar using [oy]$(-34+(#BLEVN#*2.70))$[/oy]. Those are, of course, my coordinates plugged in. I've found so many different "Oh, do this, this'll work" codes that don't work, I won't bore you with them (including this one http://forum.xda-developers.com/showthread.php?t=2563932). At any rate, any help would be appreciated.
#2: Is it possible to set up a 12 hour progress bar clock that handles just am and/or just pm?
Thanks again.
#1 Take a look at the Zooper standard analog Clock
#2 Use the 24h. For am use min 0 max 12 and for pm use min 12 max 24
Sent from GT-I9505 via Tapatalk
ibashmuck said:
Thanks for your time. Two questions, #1: I've been around here and throughout other sites, and found (it seems) dozens of different options but none have seemed to work regarding getting an object to follow a CIRCULAR progress bar. In this case, I have a simple clock that I would like to have a sunrise icon and sunset icon (each) move around the outside the clock at the appropriate time. I have tried multiple codes and combos to no avail. I have successfully managed to achieve this result on a straight prog bar using [oy]$(-34+(#BLEVN#*2.70))$[/oy]. Those are, of course, my coordinates plugged in. I've found so many different "Oh, do this, this'll work" codes that don't work, I won't bore you with them (including this one http://forum.xda-developers.com/showthread.php?t=2563932). At any rate, any help would be appreciated.
#2: Is it possible to set up a 12 hour progress bar clock that handles just am and/or just pm?
Thanks again.
Click to expand...
Click to collapse
#1: Moving things circular is a bit different from moving this along a straight line. For circles you need three parameters in Zooper: thie radius of your circle ([ar][/ar]), the sweep angle of said circle ([as][/as]) and finally the rotation ([r][/r]). The first one is static and the other two depend on what you are trying to do. You need to determine the size of your circle in degrees (360 for full, 180 for half etc.) and then determine in how many steps you need to cut that size. For something that moves with the minutes of the hour it would be 60 for instance. Then your amount of degrees per minute is 360/60 and if you multiply that with the numbers of minutes #Dm#, you get your current position and rotation. So for something to move around a circle based on the minutes of the hour you would need these advanced parameters:
[r]<whatever size>[/r]
[as]$(360/60*#Dm#)$[/as]
[ar]$(360/60*#Dm#)$[/ar]To apply this to your idea, you need to figure out in how many steps you want your circle to be broken down to (I would guess 12) and then what's your variable you want to multiply with (#ARK# maybe). With these values it should position the symbol on the hour of the sunrise.
I hope this helps you out and if not, don't hesitate to ask
#2: I think so but you probably would have to work with some advanced parameter conditionals to check whether it's currently am or pm. This depends on what exactly you are trying to do. If you can give me more details I can try to think something up.
kwerdenker said:
#1: Moving things circular is a bit different from moving this along a straight line. For circles you need three parameters in Zooper: thie radius of your circle ([ar][/ar]), the sweep angle of said circle ([as][/as]) and finally the rotation ([r][/r]). The first one is static and the other two depend on what you are trying to do. You need to determine the size of your circle in degrees (360 for full, 180 for half etc.) and then determine in how many steps you need to cut that size. For something that moves with the minutes of the hour it would be 60 for instance. Then your amount of degrees per minute is 360/60 and if you multiply that with the numbers of minutes #Dm#, you get your current position and rotation. So for something to move around a circle based on the minutes of the hour you would need these advanced parameters:
[r]<whatever size>[/r]
[as]$(360/60*#Dm#)$[/as]
[ar]$(360/60*#Dm#)$[/ar]To apply this to your idea, you need to figure out in how many steps you want your circle to be broken down to (I would guess 12) and then what's your variable you want to multiply with (#ARK# maybe). With these values it should position the symbol on the hour of the sunrise.
I hope this helps you out and if not, don't hesitate to ask
#2: I think so but you probably would have to work with some advanced parameter conditionals to check whether it's currently am or pm. This depends on what exactly you are trying to do. If you can give me more details I can try to think something up.
Click to expand...
Click to collapse
Thanks for the response. That's actually the first parameter that I found and tried to work with, and, like then, I still can't get it to work. My "hour clock" numbers are:
x= 60
y= -210
w= 520
Using #Dh#, min 0, max 12
Putting numbers into the codes you gave...
[as]$(360/12*#ARh#)$[/as]
[ar]$(360/12*#ARh#)$[/ar]
...(or even #ARK#) still sends the icon low and to the left, as you can see in the second screen shot (I've enlarged it to show it's position better). I'm living up to my namesake with this, I know, but my guess is I'm missing one small bit that's throwing me off. Apologies, of course.
Hello Everyone,
I have a problem with my amami and I doubt I am the only one but for some reason people do hardly complain: the brightness even at lowest possible setting is still too bright.
I had this back when I had original FW and I am having the same issue with CM11 (latest nightlies). Using manual control or auto-brightness doesn't make much difference, i.e. in a totally dark room the ambient light sensor reports 0Lux and the screen is still too bright.
I found a workaround already (the ScreenFilter app that people recommend all over the internet) but it sucks because it heavily reduces the picture quality, i.e. visibly reduces contrast and especially the gray color resolution. And it also doesn't reduce power consumption like real brightness value change would do.
I looked around for possible solutions and there is a trick with writting a new value of current limit to Linux settings (some mA value between 0 and 20 to some max_current file in procfs). And this really helps but also impacts the maximum brightness, the screen is hardly ready in sun light with reduced current.
Is there a silver bullet? I am thinking about writing an app for that but it would require SU permissions and is kinda dirty to implement. Can anyone recommend a better solution?
have you tried the xposed Modul "minimum brightness" ?
Install Lux Brightness. from play store.
You can overboost it or make the screen so dark that you can't even see it.
Another great screen mod is Twilight which basically dims the screen red based on clock so it helps fall sleep faster when using phone before bed.
New Folder said:
Install Lux Brightness. from play store.
Click to expand...
Click to collapse
Yes, another vote for Lux. It lets you set brightness to negative levels, mine is usually around -50%. https://play.google.com/store/apps/details?id=com.vito.lux&hl=en
Vote for Lux here too.
Nothing comes close
camaro322hp said:
Yes, another vote for Lux. It lets you set brightness to negative levels, mine is usually around -50%. https://play.google.com/store/apps/details?id=com.vito.lux&hl=en
Click to expand...
Click to collapse
Thanks for the hint. I tried the Lite version and AFAICS it simply uses the same trick as ScreenFilter and other "sub-zero" regulators, putting an alpha overlay on top of the image stack.
You can identify this kludge easily by looking at the button areas, they don't get darker anymore. And you can see the black level not getting real black, i.e. the power consumption is not reduced.
However, Lux seems to be one of the better toys because of the plugin interface. Unfortunately there is no HW plugin for Sony devices but judging by the quick look at the Nexus-4 plugin (it's open source!!) it should be possible to adopt this method to Z1 as well. So, maybe when someone could eventually implement that.
xposed Modul "minimum brightness" works, i tested it for you. you can make the screen dim to complete black with your normal display brightness slider without grey or black overlay. it just sets down the minimum brightness level to 1 or 0 (default is 10 or 20), so it should also work with enabled auto brightness
chertVdetali said:
I looked around for possible solutions and there is a trick with writting a new value of current limit to Linux settings (some mA value between 0 and 20 to some max_current file in procfs). And this really helps but also impacts the maximum brightness, the screen is hardly ready in sun light with reduced current.
Click to expand...
Click to collapse
As far as i remember, /proc is only used to call upon information, not to set specific values. What you are looking for is placed within /sys.
To be precise in /sys/devices/leds-qpnp-ee125e00/leds/wled:backlight/. There you will find a file called max_current with which you can easily control the brightness and set it to a very low level. Note that this actually dims the screen and not just applies a filter like most apps do...
One drawback is that the value will change again after you restarted the device. I set up a little flow with Automate β that takes care of this for me. I find this solution a lot better than all the screen filter apps.
This is true for CyanogenMod 11 and GreatDevs Kernel. It might be different on Stock. I know that the path for my Nexus 7 is sys/class/leds/lcd-backlight.
I hope this helps you a little bit.
rob rich said:
xposed Modul "minimum brightness" works, i tested it for you. you can make the screen dim to complete black with your normal display brightness slider without grey or black overlay. it just sets down the minimum brightness level to 1 or 0 (default is 10 or 20), so it should also work with enabled auto brightness
Click to expand...
Click to collapse
I am wondering how you can claim that the result is complete black. Calling this black is like saying "TN monitors have good black values" (I know such people, they change their mind quickly when they see my Eizo with a VA panel at night).
No, seriously, the default was already 10 (see config.xml in cm11 repo) and the difference between 1 and 10 is hardly visible. It's still way too bright for work without eye strain in the darkness.
@Wooaarr: thanks, this is apparently the way to go, I just need to find time to configure it. And yes, of course, the file is in sysfs and not procfs (automated typing, when I grew up with Linux there was no sysfs out there ).
chertVdetali said:
I am wondering how you can claim that the result is complete black. Calling this black is like saying "TN monitors have good black values" (I know such people, they change their mind quickly when they see my Eizo with a VA panel at night).
No, seriously, the default was already 10 (see config.xml in cm11 repo) and the difference between 1 and 10 is hardly visible. It's still way too bright for work without eye strain in the darkness.
@Wooaarr: thanks, this is apparently the way to go, I just need to find time to configure it. And yes, of course, the file is in sysfs and not procfs (automated typing, when I grew up with Linux there was no sysfs out there ).
Click to expand...
Click to collapse
when i disable autobrightness and push the slider to the left my screen goes completely off, so you wanna say that screen off isnt black? funny
chertVdetali said:
Thanks for the hint. I tried the Lite version and AFAICS it simply uses the same trick as ScreenFilter and other "sub-zero" regulators, putting an alpha overlay on top of the image stack.
You can identify this kludge easily by looking at the button areas, they don't get darker anymore. And you can see the black level not getting real black, i.e. the power consumption is not reduced.
However, Lux seems to be one of the better toys because of the plugin interface. Unfortunately there is no HW plugin for Sony devices but judging by the quick look at the Nexus-4 plugin (it's open source!!) it should be possible to adopt this method to Z1 as well. So, maybe when someone could eventually implement that.
Click to expand...
Click to collapse
Interesting information, I did not know that. You are correct, the navigation buttons are brighter than the rest of the screen at negative values. I had noticed that before but didn't know why. Works well enough for me though.
rob rich said:
when i disable autobrightness and push the slider to the left my screen goes completely off, so you wanna say that screen off isnt black? funny
Click to expand...
Click to collapse
Well, you claim that it works for me because you tested it on your device. So... yeah, why not, I could say what you mentioned above just following the same logics. :silly:
I know that xposed in combination with some modules should allow you to change some of the statusbar icon colours.....
What I'd ideally like.....
Battery Colour to change from Green to Yellow to Red at determined charge points.
Bluetooth Icon to be Blue
Wifi Network to be one set of colours
3G/4G Network to be a different set of colours
Probably a couple of others I can't immediately think of.
I've google and read over the last few days and while there are some modules that allow some features from the list above there seems little granularity (i.e. I can change ALL the statusbar colours in one module, but not selectively some...) or some don't allow the changes I want at all.
I realise after reading that some of the icons are app installed pics, rather then text graphics and you'd need to change the underlying pic to change the colour.....
But is there a way to do ALL that I want above?
If you're asking why it's simple.....when you're busy and in a hurry the human brain recognises cues from colours far easier and faster then from graphics...we've been wired that way for generations.
HELP!!!
hello, i've made my first widget that shows battery level with a progress bar (ram level and cpu frequency with other bars).
Now I want that the color of bar change when value is under a certain number (for example: normally is green, below 60 is yellow, below 40 is orange and below 20 is red).
I've wrote this and working: $#BLEVN#<60?[cf]#fffce109[/cf]
the logic of this is (pseudocode): if(battery.value < 60) { bar.color=yellow}
the logic that i want realize is three "if" concatenate or a "switch" (i refear to programming language).
I've tried to concatenate three of this expression but not working.
Anyone know if it can do?
thanks
newuser22 said:
hello, i've made my first widget that shows battery level with a progress bar (ram level and cpu frequency with other bars).
Now I want that the color of bar change when value is under a certain number (for example: normally is green, below 60 is yellow, below 40 is orange and below 20 is red).
I've wrote this and working: $#BLEVN#<60?[cf]#fffce109[/cf]
the logic of this is (pseudocode): if(battery.value < 60) { bar.color=yellow}
the logic that i want realize is three "if" concatenate or a "switch" (i refear to programming language).
I've tried to concatenate three of this expression but not working.
Anyone know if it can do?
thanks
Click to expand...
Click to collapse
Use && (and) to link conditions. Since you have 3 different colors you will need 3 separate conditional statements making sure only 1 statement is true at any time. so it would look something like this:
$#BLEVN#<60&&#BLEVN#>39?yellow$$#BLEVN#<40&&#BLEVN#>19?orange$$#BLEVN#<20?red$
jr67 said:
Use && (and) to link conditions. Since you have 3 different colors you will need 3 separate conditional statements making sure only 1 statement is true at any time. so it would look something like this:
$#BLEVN#<60&&#BLEVN#>39?yellow$$#BLEVN#<40&&#BLEVN#>19?orange$$#BLEVN#<20?red$
Click to expand...
Click to collapse
thanks it working , my error was exactly that with certain values more than one condition was true.