Android Reef Angel Status

Community contributed apps
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Android Reef Angel Status

Post by rimai »

The new libs on dev branch have the lights on/off commands already :)
I also created dedicated functions for it.

Code: Select all

ReefAngel.LightsOn();
ReefAngel.LightsOff();
Roberto.
User avatar
cosmith71
Posts: 1432
Joined: Fri Mar 29, 2013 3:51 pm
Location: Oklahoma City

Re:

Post by cosmith71 »

binder wrote: good requests.
what did you have in mind for the graphical representations? like a slider bar or something else?
Yes, slider bars. Something similar to what's on the portal.

--Colin
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Android Reef Angel Status

Post by rimai »

Uh... Ohh...
You will also like to know that I created the override for the PWM channels, so if you ever make this graphical representation, can we have long-press to override the values??? :)
I created override for all light channels :) (standard dimming, expansion dimming, AI and Radion)
It's all in the new libs :twisted:
Roberto.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Post by binder »

rimai wrote:Uh... Ohh...
You will also like to know that I created the override for the PWM channels, so if you ever make this graphical representation, can we have long-press to override the values??? :)
I created override for all light channels :) (standard dimming, expansion dimming, AI and Radion)
It's all in the new libs :twisted:
exactly.

so from what it sounds like, all the "cool" features will be in the next library release. guess I better get snapping and implement these features.
User avatar
DrewPalmer04
Posts: 818
Joined: Tue May 29, 2012 2:12 pm
Location: Christopher, IL

Re: Android Reef Angel Status

Post by DrewPalmer04 »

Basically.... I'm just jealous of you android users :( lol
Out for now...but not over.

VISIT: Ethernet Module/Wifi Alternative
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

DrewPalmer04 wrote:Basically.... I'm just jealous of you android users :( lol
iOS seems harder and more complicated to me. :(
I did start going through an online class at Stanford about iOS development but I've only gotten through 1 assignment. Ideally, I want to create an iOS app similar to my android app (even though there is the existing iOS app). Unfortunately, I'm slow. :(
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

cosmith71 wrote: Commands screen as a "swipe to" like status and main relay
I've got something working now. It's simply a stripped down version of the commands page. The commands page will still exist though. You will swipe left from the main Status page. The only command that is not implemented is the Version command. I'm not sure how necessary or important it is to have it on that screen. It's probably not a commonly used command. Does it need to be on this page??

Here's a screenshot:
commands, swipe to the left
commands, swipe to the left
commands_swipe.png (21 KiB) Viewed 5879 times
User avatar
cosmith71
Posts: 1432
Joined: Fri Mar 29, 2013 3:51 pm
Location: Oklahoma City

Re: Android Reef Angel Status

Post by cosmith71 »

That's perfect! Nice big buttons for the important things.

I think I used the Version command once to see what it did. I think it's great like it is.

Thanks!
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

I've been working on a new layout and look for the individual pages. I've come up with this one so far....I still need to change the layout for the PWM channels, but at least this is a start. I've increased the text size and made the layout more "solid" in terms that it does not change much when you change the labels around. I've also added a subtitle to indicate what value you are actually displaying. You will see what I mean when you look at the screen shot. It also flows better if you have items hidden (like me). So there's not going to be this abnormal space where the T3 label was. :) Feedback is always welcome.
New Status Layout
New Status Layout
NewStatusLayout.png (39.75 KiB) Viewed 5873 times
I'm working on the Relay pages next....
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

And the new Relay box layout....
New Relay Layout
New Relay Layout
NewRelayLayout.png (42.39 KiB) Viewed 5870 times
There's a subtitle that contains the actual port and the layout is more uniform no matter how long the label is. Also, the relay override mask button is on the opposite side to keep the layout consistent.
User avatar
cosmith71
Posts: 1432
Joined: Fri Mar 29, 2013 3:51 pm
Location: Oklahoma City

Re: Android Reef Angel Status

Post by cosmith71 »

Looks good. I like the uniformity and the port names along with the labels.

--Colin
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

And to finish things up, here's the rest of the new layouts....
New Custom Layout
New Custom Layout
NewCustomLayout.png (36.49 KiB) Viewed 5884 times
New IO Layout
New IO Layout
NewIOLayout.png (30.26 KiB) Viewed 5884 times
New AI Layout
New AI Layout
NewAILayout.png (24.92 KiB) Viewed 5884 times
New Vortech Layout
New Vortech Layout
NewVortechLayout.png (24.29 KiB) Viewed 5884 times
New Radion Layout
New Radion Layout
NewRadionLayout.png (27.78 KiB) Viewed 5884 times
New Dimming Layout
New Dimming Layout
NewDimmingLayout.png (32.22 KiB) Viewed 5884 times
topjimmy
Posts: 139
Joined: Tue May 08, 2012 8:16 am

Re: Android Reef Angel Status

Post by topjimmy »

binder wrote:
topjimmy wrote:How do I set up and "Away" profile? What IP do I use?
open up the settings page and input your ip address. since you probably just have a dynamic home ip address, what most people use is a free dynamic dns address for their network. using something like no-ip.com and running their application to automatically update their ip when/if it ever changes. also, you must open up port 2000 on your router to allow access to your network from the outside world. i know there are other topics on the forum that discuss this already.

I used the same ip and port as the portal, which works, but the app gets an error 13?
Image
User avatar
DrewPalmer04
Posts: 818
Joined: Tue May 29, 2012 2:12 pm
Location: Christopher, IL

Re: Android Reef Angel Status

Post by DrewPalmer04 »

Binder: do you have to have a dev license for android apps? I'm considering converting to the android side of the world lol. My iPhone is slowing down and driving me crazy.
Out for now...but not over.

VISIT: Ethernet Module/Wifi Alternative
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

topjimmy wrote: I used the same ip and port as the portal, which works, but the app gets an error 13?
sometimes if you try to connect too fast, the controller does not respond or if you have multiple connections being made at the same time it will error out at times.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

topjimmy wrote: I used the same ip and port as the portal, which works, but the app gets an error 13?
sometimes if you try to connect too fast, the controller does not respond or if you have multiple connections being made at the same time it will error out at times.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

DrewPalmer04 wrote:Binder: do you have to have a dev license for android apps? I'm considering converting to the android side of the world lol. My iPhone is slowing down and driving me crazy.
yes and no. yes if you want to publish on the google play store for people to install and update. the license is a one time $25 fee (unless they raised it).
no if you want develop your own apps and only install them on your phone manually. you cannot distribute these on the play store. they can be the normal releases but just not on the play store. you also must allow your phone to install apps from unknown sources.

the main thing is the dev license just gives you the ability to distribute your apps on the play store.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

I've been making more changes to the layout to use the new actionbar layout across all devices. I moved the refresh button to the actionbar and removed it from the main layout. The "only" problem with this is that the profiles are not easily switched unless I add a drop down list in the actionbar.
ActionBar Layout
ActionBar Layout
ActionBarLayout.png (44.13 KiB) Viewed 5820 times
What do you guys think?
Is there a need for an easy way to change profiles?
User avatar
cosmith71
Posts: 1432
Joined: Fri Mar 29, 2013 3:51 pm
Location: Oklahoma City

Re: Android Reef Angel Status

Post by cosmith71 »

I never change profiles.

--Colin
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

Hopefully the "final" release of the layout and last time I post a picture for a while. :mrgreen:
I now am making use of the ActionBar along with an Indicator for all the pages to be viewed. IMO, it looks pretty sweet. :D
Completed Layout
Completed Layout
AwesomeLayout.png (29.33 KiB) Viewed 5811 times
User avatar
cosmith71
Posts: 1432
Joined: Fri Mar 29, 2013 3:51 pm
Location: Oklahoma City

Re: Android Reef Angel Status

Post by cosmith71 »

Lol@ "AwesomeLayout.png" :D

Looks great!
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Android Reef Angel Status

Post by rimai »

I like it :)
Evolution uses the same bar.
Roberto.
phrusher
Posts: 65
Joined: Fri May 25, 2012 12:22 am

Re: Android Reef Angel Status

Post by phrusher »

Looks great! The two changes I've been really looking forward to are swipe to commands and the refresh moved up to the action bar :D (I never switch profiles either). What is the flash symbol next to refresh?

As an additional request for future update, when setting update interval to Manual (never) the service should be stopped. There is no reason for the service to be active if only manual updates are preformed. Or an optional solution could be to keep the service and just update whenever the screens turns on with BroadcastReceiver and ACTION_SCREEN_ON. That would be pretty sweet.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

phrusher wrote:Looks great! The two changes I've been really looking forward to are swipe to commands and the refresh moved up to the action bar :D (I never switch profiles either). What is the flash symbol next to refresh?
The flash symbol is for the Internal Memory. If you have a large enough screen, it displays memory next to it. There's also the History icon that looks like a list. Thanks for the feedback! :)
phrusher wrote:As an additional request for future update, when setting update interval to Manual (never) the service should be stopped. There is no reason for the service to be active if only manual updates are preformed. Or an optional solution could be to keep the service and just update whenever the screens turns on with BroadcastReceiver and ACTION_SCREEN_ON. That would be pretty sweet.
There are actually 2 services that are associated with the app. One is the auto update service and the other is just listener / communication service. If auto update is set to manual, the auto update service is cancelled. It's actually an alarm that the android service sends a message to run at the specified interval. The communication service is just sitting there doing nothing but sleeping and waiting for commands to be sent to it. It has to be there for the auto update service and for any app that wishes to communicate with the controller.
When I simplified the communications, just that service communicates with the controller. So all the parts of the app just send a message to the service to grab the latest data from the controller and update the database. When it's updated, then it sends a message back to the app that it's updated and to update it's data.
I don't think I would like having the service update every time I turn my screen on. That would be a little excessive to me. :) Although, I "could" put that feature in for you if you would like to have it. ;-)

I will take a look at the service code and see if there's an easy way to only start it if it's not on Manual. Then if it is on Manual, start it when you launch an update/send a command/update the memory/etc and then shut it down when the app pauses or when the command finishes.
I did do a quick google search on this topic just before I posted my reply which caused me to change it before I posted it. :)
I honestly had not given it much thought about the service sitting there running because I mostly deal with an update interval of 4 hours, so it's always running and that didn't seem to bother me.
However, I know I wrote most of my app with the ability to check and see if the service was running and if it was not running to start it up. So the functionality that you are mentioning, should definitely be doable and fairly simple to implement. With that being said, I'm going to give it a little closer look to see if there's a better way for me to handle the running service even if auto updating is enabled. I may just do this in a multi-part update pattern where I handle the Manual case first to keep it off unless you are using the app for updating and then work on the rest later because if somebody wants the app to update automatically, they are going to want it to run in the background.
I found this post: http://stackoverflow.com/questions/2545 ... ed-or-to-l
I am reading it through plus the associated articles and posts with it. So updates to how this works will be made. This will go along with me improving the performance of my app and also simplifying it to allow for the bigger updates I plan on making in the future. It's just part of the every evolving and expanding nature of the apps. Thanks for mentioning this to me and pointing it out!! I will see what I can do. :)
User avatar
cosmith71
Posts: 1432
Joined: Fri Mar 29, 2013 3:51 pm
Location: Oklahoma City

Re: Android Reef Angel Status

Post by cosmith71 »

Everything looks awesome! Can't wait for the release (hint hint)!

--Colin
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Post by binder »

cosmith71 wrote:Everything looks awesome! Can't wait for the release (hint hint)!

--Colin
I'm testing it on my phone and tablet. There still is a couple items I need/want to implement before the release.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Android Reef Angel Status

Post by binder »

Since my last post about removing the ability to switch profiles with the change to an ActionBar layout, I did some more thinking and experimenting. I figured out a way to add the profile switching back. I implemented the List navigation in the actionbar. In the actionbar, the "Home" profile will always be visible. If you have an Away profile enabled, then you will have "Home" and "Away" visible in the navigation list. All you must do is simply change the list to switch profiles.

The only downside is that I removed the application title from the status bar. I didn't feel that it was a big deal because most people would rather have functionality instead of seeing the name of the app. You still see the icon, but not the title.

Here's a screenshot to show you what it looks like now.
Navigation List
Navigation List
NavList.png (34.85 KiB) Viewed 5959 times
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Android Reef Angel Status

Post by rimai »

I like it :)
Roberto.
phrusher
Posts: 65
Joined: Fri May 25, 2012 12:22 am

Re: Android Reef Angel Status

Post by phrusher »

binder wrote:In the actionbar, the "Home" profile will always be visible. If you have an Away profile enabled, then you will have "Home" and "Away" visible in the navigation list. All you must do is simply change the list to switch profiles.
Looks great! Just to make sure, it still remembers if Away is my preferred profile?

Regarding the background service it sounds like the best solution is the one you are proposing. Check if its running or else start it up and shut it down after the response or it timeouts. The benefit of this is that the same code could be used on both manual and timer so it might result in slightly better maintainability. It's not super important since the service is hardly using any resources (only around 3MB on phone, 16MB on tab) but it's always a bit annoying with all the apps that don't require a service still start them :)

You can hold on with the "update on screen start". Manual might be sufficient and most people probably turn on the screen rather frequently and it might be spamming the controller unless some time buffer is implemented. Maybe later though :)

Now release it already or I have to get the source and compile it myself :P
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Android Reef Angel Status

Post by binder »

phrusher wrote:
binder wrote:In the actionbar, the "Home" profile will always be visible. If you have an Away profile enabled, then you will have "Home" and "Away" visible in the navigation list. All you must do is simply change the list to switch profiles.
Looks great! Just to make sure, it still remembers if Away is my preferred profile?

Regarding the background service it sounds like the best solution is the one you are proposing. Check if its running or else start it up and shut it down after the response or it timeouts. The benefit of this is that the same code could be used on both manual and timer so it might result in slightly better maintainability. It's not super important since the service is hardly using any resources (only around 3MB on phone, 16MB on tab) but it's always a bit annoying with all the apps that don't require a service still start them :)

You can hold on with the "update on screen start". Manual might be sufficient and most people probably turn on the screen rather frequently and it might be spamming the controller unless some time buffer is implemented. Maybe later though :)

Now release it already or I have to get the source and compile it myself :P
yes, it remembers what profile you have selected, just like it currently does. i dont plan or try to break existing functionality unless i absolutely have to.

i still have to get the stopping service functionality fixed before i can release it. i made some big behind the scenes changes and am testing it to make sure things still work properly. i also need to see if i can speed up the app as well because it runs slow in the emulator.

i was going to try to get a few more features in before i release but i think im gonna hold off until next release for the next 2 significant features (saved custom memory locations and parameter notifications). :-)
Post Reply