Curt:
I uploaded and this works like a charm...thanks for you help...screen shot below
Don't know why, but my relay box is lined up opposite the way other people's seem to be...relay 1 is on the top right corner and relay 2 is on the top left, if you have the data cable port pointing down...
Circles, min/max pde
Re: Circles, min/max pde
- Attachments
-
- RA screen.jpg (62.47 KiB) Viewed 9643 times
Re: Circles, min/max pde
Nice. Glad it works for you.
screenshot looks great!
screenshot looks great!
Re: Circles, min/max pde
I just finished adding this into the libraries. I made some tweaks to it for better and improved functionality. I merged the reverse displaying into one function and made it adhere to the standard color scheme / coordination. I also renamed some of the functions to add more clarity to them. This will be in the 0.9.4 release.
Here are the functions added to the LCD library (RA_NokiaLCD):
To use, you would simply do exactly like you would for the standard outlet box:
This will display the outlet in "normal" fashion
And reversed:
There are no numbering on the circles. If you want the labels, you gotta add them in yourself and use code like on the initial post.
Regardless, I just wanted to share that this will be an option for the next release of the libraries.
Here are the functions added to the LCD library (RA_NokiaLCD):
Code: Select all
void DrawCircleOutline(byte x, byte y, byte radius, byte bordercolor);
void FillCircle(byte x, byte y, byte radius, byte fillcolor);
void DrawCircleOutletBox(byte x, byte y, byte RelayData, bool reverse = false);
This will display the outlet in "normal" fashion
Code: Select all
// Normal display like this:
// Outlets in 2 columns
// 1 2
// 3 4
// 5 6
// 7 8
byte TempRelay = ReefAngel.Relay.RelayData;
TempRelay &= ReefAngel.Relay.RelayMaskOff;
TempRelay |= ReefAngel.Relay.RelayMaskOn;
ReefAngel.LCD.DrawCircleOutletBox(10,10,TempRelay);
Code: Select all
// Reversed display
// Outlets in 2 columns
// 2 1
// 4 3
// 6 5
// 8 7
byte TempRelay = ReefAngel.Relay.RelayData;
TempRelay &= ReefAngel.Relay.RelayMaskOff;
TempRelay |= ReefAngel.Relay.RelayMaskOn;
ReefAngel.LCD.DrawCircleOutletBox(10,10,TempRelay,true);
Regardless, I just wanted to share that this will be an option for the next release of the libraries.
- jsclownfish
- Posts: 378
- Joined: Mon Oct 24, 2011 7:52 pm
- Location: Saint Louis
Re: Circles, min/max pde
Thanks Curt! It will be nice to have these available for custom screens.
-Jon
-Jon
Re: Circles, min/max pde
hi i would love to able to use this custom screen but i am not sure as how to do this i don't understand what i should put where in the libraries, i am new to this
i have read this http://curtbinder.info/ragen/docs/RA_Custom_Menu.pdf and added
#define CUSTOM_MENU
to the features file
and this to the RA_NOKIALCD
void DrawCircleOutline(byte x, byte y, byte radius, byte bordercolor);
void FillCircle(byte x, byte y, byte radius, byte fillcolor);
void DrawCircleOutletBox(byte x, byte y, byte RelayData, bool reverse = false);
what else do i need to do ?
i have read this http://curtbinder.info/ragen/docs/RA_Custom_Menu.pdf and added
#define CUSTOM_MENU
to the features file
and this to the RA_NOKIALCD
void DrawCircleOutline(byte x, byte y, byte radius, byte bordercolor);
void FillCircle(byte x, byte y, byte radius, byte fillcolor);
void DrawCircleOutletBox(byte x, byte y, byte RelayData, bool reverse = false);
what else do i need to do ?
Re: Circles, min/max pde
You shouldn't need to do any of that anymore afaik. I believe you just need to define the functions in your INO DrawCustomMain and DrawCustomGraph and start drawing your screens. I'd say look at my code but it's not a good beginner reference. Take a look at some people's posted INO files for some examples.