![]() |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
Let's say one wants to have wifi enabled and mobile data disabled in some locations, and otherwise have wifi disabled and mobile data enabled. One way to do this is to have defined areas/locations (e.g. by cell IDs, just like in Situations currently) and on top of that events like "left area" and "entered area". Then, when entering a specific area, mobile data would be dropped and wifi enabled, and the opposite would happen upon leaving. I'm not quite sure how much an unused wifi draws power, but IMO at least maintaining mobile data when it is not needed is a power hog that can and should be eliminated. This would enable, in addition to the above example, having ringer volume turned up when leaving home (to be able to notice it better while in noisier surroundings) and other such things. Some cases can be managed by having a generic situation (with a high ringer volume) which then is overridden by more specific ones, but that approach makes it necessary to have extra situation(s) just for the baseline/default condition(s). Additionally, to handle the area borders nicely, as the phone might alternate between cells in and outside of the specified area, there would need to be a sort of a dampening to avoid rapid switching between situations... something like a configurable timer attached to the enter/leave area event so that when initially entering the area, the timer starts, and if and only if the condition still holds after the timer runs out, the situation is triggered (and similarly for leaving an area). Edit: good to hear the timed manual situation is on TODO list. I'm a bit new to the Sailfish way of doing UI and can't come up with any good suggestions right now... |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
Situations model is more about states than enter & exit events. That is, if you configure a situation with some settings, those settings will be active during the situation and be automatically reverted back when the situation ends (there are of course some exceptions with actions that cannot be reverted reliably/easily or at all, like launching an app). And then there is of course the normal phone state when no situation is active. So, if you want to have wifi disabled and mobile data enabled by default, first make sure you don't have any situation active (just to make sure situations is not already in some state for those settings) and configure your phone settings like you want them to be. Then create situations for different locations and make them enable wifi and disable mobile data. This way you will have wifi on and mobile data off in those locations and elsewhere vice versa. So you don't necessarily need a baseline situation since your normal phone settings are the baseline. Does this make any sense? |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
Let me elaborate: Let's say I want to have wifi enabled (and mobile data disabled) at home and the other way around anywhere else. I then set up these three situations:
It is not that straightforward, but I hope it helps, because I've been happily using this scenario ever since Situations came out for Jolla. EDIT: It would work much better if the wifi condition in Situations checked connected networks only, because sometimes the wifi has a low signal and disconnects (but is still visible) and I end up without an internet connection. If the condition was as I suggest, it would seamlessly switch between wifi and mobile data in such situations. |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
While trying to get this set up, I noticed one thing that's missing: Even though cell ID sets (areas) are named, I can't re-use one that has been defined already, I need to record a new one... |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
One application that I used to use on Android was Tasker. It was a fantastic application for this sort of thing, esp in early versions of Android. It might be worth trawling for ideas...I never tried Llama, so can't compare them. |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
Well, I'll try these new tricks I've today learned here, if they work for me it'll certainly increase the value of the app for me. I'll also try to figure out if there is a pattern with the intermittent failures to switch situations which are based on cell IDs. Since the cells the phone is using somewhat vary, sometimes it's just that there's a new cell ID and it gets fixed by briefly turning on recording, but sometimes the only way is to manually turn on or off the cell ID based situation. Anything that I could try to check when I notice such a failure, except checking if the background process is still running? |
Re: Situations app - bugs, questions, answers, help etc..
Technically the cell id recognition of the app should be quite reliable and stable. But the problem is indeed the possible variation of cells the phone is connected to over time.
I have myself recorded well over 10 cells at my home. This also covers quite a large physical area, so it can get quite inaccurate as a positioning method at least in some places. What can be done to get the best coverage in short time is to leave the recording on and go to system settings and switch between 2, 3 & 4G manually, wait long enough and possibly also make some calls. |
Re: Situations app - bugs, questions, answers, help etc..
My configuration is as follows:
1. At home: if cell tower found - turn on wifi, turn off bluetooth, mobile data, profile normal 2. At work: if cell tower found - turn off wifi and bluethooth, turn on mobile data, profile silent 3. Driving: if not at home or work and my car bluetooth found Only problem is my phone is not evaluating when locked. As soon as I double tap, it changes the situation profile to the correct one. I am using v2.4.48, for openrepos. Any ideas? |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
But of course currently there is no autostart built in the Sailfish application because of the Jolla Store rules which makes this a bit incomplete feature on Jolla... |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Bugs are always possible ;) But recognizing 0 cells sounds strange if you did have network coverage. Under the hood cell condition is using org.ofono interface to read and get notified of cell changes. It should be quite solid, but who knows...
Yes, the current network cell features & UI in Situations is quite limited. It's mainly designed for ease of implementation and use, and more advanced features have been on the backlog already for quite some time. Hopefully I get some time to implement them at some point. |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
I did not mean "Device lock", when I said the when the phone is locked. I just meant when the screen is off. Device lock is not enabled on my phone. As soon as I double tap to wake the phone up, situations app evaluates and does what it is supposed to do, depending on where I am. It works on all situations profiles correctly. Is there a log or something I can send you that may help you trouble shoot? Thanks for this great app. Even with this issue, it works great. I just have to wake the phone up when I want it to change the profile. |
Re: Situations app - bugs, questions, answers, help etc..
This morning again the situation failed to change after leaving home...
My config goes like this:
The cell ID sets consist of two non-adjanced physical areas, so basically the situation should've changed once on my way to the office and another time when I reached it. Now it did finally change after I modified the "At home" situation (added the missing wifi AP condition) which I guess triggered not only re-evaluation of that situation but also re-evaluation of all other rules since "At work" also got activated immediately. The phone was locked (device lock, display off) while I was on my way, but unlocking it had no effect. Also, before leaving home I was experimenting with the "baseline" thing: I closed Situations app (swipe from top), went to settings and set things up as I want them to be when there's no situation active (or Situations is not running) and restarted Situations. The active situations were correct after start-up, but they didn't seem to affect the settings (e.g. mobile data was not turned off). Should I have also killed the background process (via Terminal) to have Situations completely shut down? Is the GUI process actually even needed for the rules to be effective? Anyway, as I noticed that the settings were incorrect for the active situations, I manually deactivated "At home", which automatically activated "Near home" as it should (and I guess "At home" got automatically activated shortly after that). Thus, the app seemed to be running ok just before I left home. |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
The UI does not need to be running at all for Situations to work - there is a separate background process doing all the work. You can disable the app (including the backround process) via the settings page but it is not the same as abruptly stopping and restarting the app. To do that you need to kill the background process. |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
No logs, I need to enable them with separate test builds if needed. |
Re: Situations app - bugs, questions, answers, help etc..
One problem I have regarding this great app :)
I have a flight mode turned on with a timing schedule. But it has been almost always the case that in the morning, the flight mode is indeed turned off, it seems apparently back to normal but while wifi is back on, the cells are just grey :( I need then to go to sailfish utilities, restart connections, and then after 1-2 sec, I have the cells on. This is probably not caused by your app but this is for information and in case that this is related to something your know.... |
Re: Situations app - bugs, questions, answers, help etc..
Situations updated today to v2.4.50. Some changelog:
- Updated app icon to Sailfish style - Updated plugins & implemented autoupdate on application updates - Attempt to increase wakeup timer robustness - Fix to restart mechanism on application updates - Fix to suppressed Wifi scanning The plugin update & related changes have all the ingredients for a big catastrophe on existing installations - hopefully everything goes well though. Edit: Probably should mention the new Location condition available on Features page also here. |
Re: Situations app - bugs, questions, answers, help etc..
Uh, after the update it seems that cell ID based situations are not triggered anymore :( Or well, at least the one that should be active now doesn't get activated, not even by killing the app (well, it killed itself when I disabled it, is that supposed to happen?) or by trying to modify the situation condition (which seemed to do the trick before the update).
Tried creating a new situation with just cell ID condition, but so far it hasn't recorded any cells even though I have proper coverage here ATM. edit: I'd go for remove & reinstall (as I've backed up .local/share/harbour-situations2application), unless there's something that could first be tried to figure out why it broke... @hhaveri? |
Re: Situations app - bugs, questions, answers, help etc..
Hej,
I just noticed that when a Situation is triggered by an 'Accessory' that is my car kit, when the phone receives a call, it starts switching on and off the given Situation, as far as the call is received or declined. When BT is the condition, the same car kit is connected, everything works fine. Only the power hogging nature of the BT condition is the problem. LVPVS out. |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Quote:
But alright, the app seems to work ok now, situation triggering works as well as recording cell IDs. BTW, I'm using this autostart solution. Haven't had any issues so far. |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
|
Re: Situations app - bugs, questions, answers, help etc..
Hej,
@hhaveri, it is like 5-7 times a second. I guess, it is only the processing speed of the phone and the number of "What"s that limits it. LVPVS out. |
Re: Situations app - bugs, questions, answers, help etc..
Sadly I have been still having issues with cell ID based situations even after the app update, but it also might be that I have figured out the reason (but let me first describe the issues)...
Each of the previous three mornings when arriving at the office I've had incorrect situation active. This morning it claimed I'd still be around my home, which is over 3 km away from the office and surely no cells are reachable from both locations. Yesterday morning it just didn't seem to notice arriving at the cell ID based area "office". What is common to these cases now is that if I add a new situation and try to record cell IDs, none are found, even though there's 3G with good signal available. Also, after activating the correct situation (which has mobile data -> on and wifi -> off) things seem to get fixed and when returning home I have no issues even though also then cell ID based conditions are being used. I have one question related to this about the GUI: When manually enabling a situation, the green icon is first a bit yellowish, turning deeper green only after a while when the incorrectly active situation gets disabled by the app. Does this tell something about the issue? Also, I noticed that after the correct situations is activated, there is a popup notification telling that mobile data connection is (only then) established, even though mobile data has been enabled ever since I've left the coverage area of my home wifi AP. And here's when we might be getting at the roots of the issue... There's an open guest wifi AP available at the office, and I only just this morning realised that I had saved a connection to it thus making the phone automatically try to connect to it. However, there's browser based authentication on the AP, and before passing that phase there's no internet connectivity available. Sailfish does recognise the case correcly, firing up the browser with the AP login page opened. However, I wonder if this semi-connected state could be confusing Situations or the API it is using? After all, there's sort of a wifi connection active, which can block using mobile data properly, but I fail to see a direct reason why this would block things with cell IDs... I'll get back to this next week to let you know if "forgetting" the open wifi AP makes things work ok. |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
I have one CellID-based situation. It activates when around home. It switches mobile data off and wlan on. I can say it pretty much does what it should. Have you tried uninstalling the app, removing the remnants of its data and installing it again? LVPVS out. |
Re: Situations app - bugs, questions, answers, help etc..
The "no cells found when trying to record" is definitely connected to this problem. I don't know if it is something in Situations or something in org.ofono or something somewhere else that breaks but for some reason Situations just does not get any cell updates or cannot even read current cell when this happens. Would be interesting to know if any other app can read the cell in this case.
You could also try removing actions from your situations one by one to see if any of them is directly or indirectly causing the issue. When a situation is activated manually, the color of the circle on the left is yellow indicating that it is not turned on by automation. Green means that automation also thinks the situation should be active (and that automation takes over the control of that situation even if it was manually activated). |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
I can't immediately think of other native apps that would allow testing cell ID reading, any suggestions? There would be plenty of options with Android apps but AFAIK they can't access that information on SFOS at all. Quote:
Quote:
If all other fails, I'll go for uninstall, clean-up and reinstall, but I'd hate to do that even though the rule-set is not that complicated. I might also try with tweaking the actions as @hhaveri suggested, but there're pretty much only mobile data on/off, wifi on/off and ringer volume that are being set (no bluetooth or app launching etc), and of those only volume control can be dropped off without changing the test case altogether... |
Re: Situations app - bugs, questions, answers, help etc..
Hej,
@zagrim, You might be right about the hotspot... I am not using wlan as a 'When'. I have a gut-feeling that it would be at least as power-hungry as Bluetooth is. I am testing GPS-based Situations, but I have some doubts about its power efficiency, as well. I have also went through this uninstall-cleanup-reinstal-reconfigure procedure once. It was a real pain. I have 9 Situations of which one is a base-line Situation, thus always active, and one temporarily disabled (as audio accessory-triggering has some issues). So yes, I, too, hate the thought of cleaning up... LVPVS out. |
Re: Situations app - bugs, questions, answers, help etc..
Quote:
GPS condition updates the location in practice continuously, so it eats as much power as if Maps application was on. As many other features, this might also be optimized in the future... |
Re: Situations app - bugs, questions, answers, help etc..
Thanks! :) I just finished removing my GPS-based 'When's... ;)
LVPVS out. |
All times are GMT. The time now is 09:55. |
vBulletin® Version 3.8.8