Basic float switch question

New members questions
Post Reply
User avatar
aspec
Posts: 7
Joined: Mon Nov 18, 2013 9:06 am
Location: GA/USA

Basic float switch question

Post by aspec »

I have not looked into the RA Wizard to see if this is possible yet, but I am wondering the following:

I want to setup a single float switch in my ATO reservoir so that when it's low on water it can send me an alert on my phone (via SMS/text/email... something) and turn off a certain relay socket (keep the pump from running when there is no water).

Is this covered in the wizard or will I need to do some research and write this code myself?

And finally, regarding the single float switch... I've looked at the user manual and can not determine how to position a single float switch for proper operation. Do I want the threads/nut side of the switch UP (fig A below) or DOWN (fig B below)?

Image


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

Re: Basic float switch question

Post by rimai »

For this purpose, you can mount whichever way you wish.
Use this for A:

Code: Select all

ReefAngel.Relay.Set(Port1,!ReefAngel.LowATO.IsActive);
Or this for B:

Code: Select all

ReefAngel.Relay.Set(Port1,ReefAngel.LowATO.IsActive);
Then, you can set the portal to alert you using the ATOLOW as a trigger.
Just keep in mind that the portal only receives data every 5 minutes.
Roberto.
User avatar
aspec
Posts: 7
Joined: Mon Nov 18, 2013 9:06 am
Location: GA/USA

Re: Basic float switch question

Post by aspec »

Perfect, thanks Roberto.
---
AJ
User avatar
aspec
Posts: 7
Joined: Mon Nov 18, 2013 9:06 am
Location: GA/USA

Re: Basic float switch question

Post by aspec »

Roberto,

The code won't verify with your suggestion above.

sketch_nov24b.cpp: In function 'void loop()':
sketch_nov24b:72: error: could not convert 'ReefAngel.ReefAngelClass::LowATO.RA_ATOLowClass::IsActive' to 'bool'
sketch_nov24b:72: error: in argument to unary !



Any ideas?
---
AJ
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Basic float switch question

Post by binder »

rimai wrote:For this purpose, you can mount whichever way you wish.
Use this for A:

Code: Select all

ReefAngel.Relay.Set(Port1,!ReefAngel.LowATO.IsActive);
Or this for B:

Code: Select all

ReefAngel.Relay.Set(Port1,ReefAngel.LowATO.IsActive);
Then, you can set the portal to alert you using the ATOLOW as a trigger.
Just keep in mind that the portal only receives data every 5 minutes.
aspec wrote:Roberto,

The code won't verify with your suggestion above.

sketch_nov24b.cpp: In function 'void loop()':
sketch_nov24b:72: error: could not convert 'ReefAngel.ReefAngelClass::LowATO.RA_ATOLowClass::IsActive' to 'bool'
sketch_nov24b:72: error: in argument to unary !



Any ideas?
change it to this:

Code: Select all

ReefAngel.Relay.Set(Port1,ReefAngel.LowATO.IsActive() );
add in parentheses to the functions

Sent from my Nexus 7
Post Reply