Main Site Documentation

SPIDER + Display T35 : WPF : Text.ForeColor = Colors.Green; doesn't work (White, Yellow, Cyan are OK)



I’ve a problem to display green textes with NinaB font : White, Yellow, Cyan are OK but not Green !

Definition of Textes

[b] #region Creation Line PowerSupply
/* PowerSupply */
str_Text_Line_02_Text_01 =
new Text(Resources.GetFont(Resources.FontResources.NinaB), "PowerSupply : ");
str_Text_Line_02_Text_01.TextAlignment = TextAlignment.Left;
str_Text_Line_02_Text_01.ForeColor = Colors.Cyan;
Canvas.SetLeft(str_Text_Line_02_Text_01, 0);
Canvas.SetTop(str_Text_Line_02_Text_01, int_Height_Line_02);

        /* OK/AL */
        str_Text_Line_02_Text_02 =
            new Text(Resources.GetFont(Resources.FontResources.NinaB), "??");
        str_Text_Line_02_Text_02.TextAlignment = TextAlignment.Left;
        str_Text_Line_02_Text_02.ForeColor = Colors.White;
        Canvas.SetLeft(str_Text_Line_02_Text_02, 100);
        Canvas.SetTop(str_Text_Line_02_Text_02, int_Height_Line_02);
        #endregion Creation Line PowerSupply<Fin>[/b]

My timer is checking Status

[b] #region Methode Evenementielle du Timer
void GEPp_Timer_Display_001_Tick(GT.Timer timer)
/* Updating Dates*/
str_Text_Line_01_Text_02.TextContent = DateTime.Now.ToString(“yyyy’_'MMdd”);
str_Text_Line_01_Text_04.TextContent = DateTime.Now.ToString(“HH’:‘MM’:'ss”);

        /* Displaying Status*/
        if (bool_PowerSupply == false)
            str_Text_Line_02_Text_02.ForeColor = Colors.Yellow;    
            str_Text_Line_02_Text_02.TextContent = "AL";

str_Text_Line_02_Text_02.ForeColor = Colors.White; // Working :stuck_out_tongue:
bold]/str_Text_Line_02_Text_02.ForeColor = Colors.Green;/[/b] // Doesn’t Work !!! :frowning:
str_Text_Line_02_Text_02.TextContent = “OK”;
/Next code taken off for clarity/
#endregion Methode Evenementielle du Timer

If I use str_Text_Line_02_Text_02.ForeColor = Colors.White; OK appears in White,
If I use str_Text_Line_02_Text_02.ForeColor = Colors.Yellow; OK appears in Yellow,
If I use str_Text_Line_02_Text_02.ForeColor = Colors.Cyan; OK appears in Cyan,

If I use str_Text_Line_02_Text_02.ForeColor = Colors.Green; Nothing appears at all ??

P.S. : Version of course


If you display a full color image then will it look right or it will look like missing colors?


I have 6 Icone, 3 of them have green Colors and it is displayed correctly.
No problem with green pictures


textes in Green Color are very useful to indicate normal status on Display …


[italic]SOLVED :


It seams to be a bug of the SPIDER’s SDK :

Doesn’t Work :
str_Text_Line_02_Text_02.ForeColor = Colors.Green;

Works perfectly well on T35 display:

str_Text_Line_02_Text_02.ForeColor = ColorUtility.ColorFromRGB(0x00, 0xFF, 0x00); //Lime


static Color myLime_Color = ColorUtility.ColorFromRGB(0x00, 0xFF, 0x00);

str_Text_Line_02_Text_02.ForeColor = myLime_Color; //Lime
str_Text_Line_02_Text_02.TextContent = “OK”;

str_Text_Line_02_Text_03.ForeColor = myLime_Color; //Lime
str_Text_Line_02_Text_03.TextContent = “Running”;

For who wants to have ALL RGB colors, if it can help somebody…:

#region Couleur RGB

DarkOliveGreen----------> 0x55 0x6B 0x2F
DarkOrange ---------->0xFF 0x8C 0x00
DarkOrchid---------->0x99 0x32 0xCC
DarkRed---------->0x8B 0x00 0x00
DarkSalmon---------->0xE9 0x96 0x7A
DarkSeaGreen---------->0x8F 0xBC 0x8B
DarkSlateBlue---------->0x48 0x3D 0x8B
DarkSlateGray---------->0x2F 0x4F 0x4F
DarkTurquoise---------->0x00 0xCE 0xD1
DarkViolet---------->0x94 0x00 0xD3
DeepPink---------->0xFF 0x14 0x93
DeepSkyBlue---------->0x00 0xBF 0xFF
DimGray---------->0x69 0x69 0x69
DodgerBlue---------->0x1E 0x90 0xFF
Firebrick---------->0xB2 0x22 0x22
FloralWhite---------->0xFF 0xFA 0xF0
ForestGreen---------->0x22 0x8B 0x22
Fuchsia---------->0xFF 0x00 0xFF
Gainsboro---------->0xDC 0xDC 0xDC
GhostWhite---------->0xF8 0xF8 0xFF
Gold---------->0xFF 0xD7 0x00
Goldenrod---------->0xDA 0xA5 0x20
Gray---------->0x80 0x80 0x80
Green---------->0x00 0x80 0x00
GreenYellow---------->0xAD 0xFF 0x2F
Honeydew---------->0xF0 0xFF 0xF0
HotPink---------->0xFF 0x69 0xB4
IndianRed---------->0xCD 0x5C 0x5C
Indigo---------->0x4B 0x00 0x82
Ivory---------->0xFF 0xFF 0xF0
Khaki---------->0xF0 0xE6 0x8C
Lavender---------->0xE6 0xE6 0xFA
LavenderBlush ---------->0xFF 0xF0 0xF5
LawnGreen ---------->0x7C 0xFC 0x00
LemonChiffon---------->0xFF 0xFA 0xCD
LightBlue---------->0xAD 0xD8 0xE6
LightCoral---------->0xF0 0x80 0x80
LightCyan---------->0xE0 0xFF 0xFF
LightGoldenrodYellow---------->0xFA 0xFA 0xD2
LightGreen ---------->0x90 0xEE 0x90
LightGray---------->0xD3 0xD3 0xD3
LightPink---------->0xFF 0xB6 0xC1
LightSalmon---------->0xFF 0xA0 0x7A
LightSeaGreen---------->0x20 0xB2 0xAA
LightSkyBlue---------->0x87 0xCE 0xFA
LightSlateGray---------->0x77 0x88 0x99
LightSteelBlue---------->0xB0 0xC4 0xDE
LightYellow---------->0xFF 0xFF 0xE0
Lime---------->0x00 0xFF 0x00
LimeGreen ---------->0x32 0xCD 0x32
Linen---------->0xFA 0xF0 0xE6
Magenta---------->0xFF 0x00 0xFF
Maroon ---------->0x80 0x00 0x00
MediumAquamarine---------->0x66 0xCD 0xAA
MediumBlue---------->0x00 0x00 0xCD
MediumOrchid---------->0xBA 0x55 0xD3
MediumPurple---------->0x93 0x70 0xDB
MediumSeaGreen---------->0x3C 0xB3 0x71
MediumSlateBlue---------->0x7B 0x68 0xEE
MediumSpringGreen---------->0x00 0xFA 0x9A
MediumTurquoise---------->0x48 0xD1 0xCC
MediumVioletRed---------->0xC7 0x15 0x85
MidnightBlue---------->0x19 0x19 0x70
MintCream---------->0xF5 0xFF 0xFA
MistyRose---------->0xFF 0xE4 0xE1
Moccasin---------->0xFF 0xE4 0xB5
NavajoWhite---------->0xFF 0xDE 0xAD
Navy---------->0x00 0x00 0x80
OldLace---------->0xFD 0xF5 0xE6
Olive ---------->0x80 0x80 0x00
OliveDrab---------->0x6B 0x8E 0x23
Orange---------->0xFF 0xA5 0x00
OrangeRed---------->0xFF 0x45 0x00
Orchid---------->0xDA 0x70 0xD6
PaleGoldenrod---------->0xEE 0xE8 0xAA
PaleGreen---------->0x98 0xFB 0x98
PaleTurquoise---------->0xAF 0xEE 0xEE
PaleVioletRed---------->0xDB 0x70 0x93
PapayaWhip---------->0xFF 0xEF 0xD5
PeachPuff---------->0xFF 0xDA 0xB9
Peru---------->0xCD 0x85 0x3F
Pink---------->0xFF 0xC0 0xCB
Plum---------->0xDD 0xA0 0xDD
PowderBlue---------->0xB0 0xE0 0xE6
Purple---------->0x80 0x00 0x80
Red---------->0xFF 0x00 0x00
RosyBrown---------->0xBC 0x8F 0x8F
RoyalBlue---------->0x41 0x69 0xE1
SaddleBrown---------->0x8B 0x45 0x13
Salmon---------->0xFA 0x80 0x72
SandyBrown---------->0xF4 0xA4 0x60
SeaGreen ---------->0x2E 0x8B 0x57
SeaShell---------->0xFF 0xF5 0xEE
Sienna---------->0xA0 0x52 0x2D
Silver---------->0xC0 0xC0 0xC0
SkyBlue----------> 0x87 0xCE 0xEB
SlateBlue---------->0x6A 0x5A 0xCD
SlateGray---------->0x70 0x80 0x90
Snow ---------->0xFF 0xFA 0xFA
SpringGreen---------->0x00 0xFF 0x7F
SteelBlue---------->0x46 0x82 0xB4
Tan---------->0xD2 0xB4 0x8C
Teal---------->0x00 0x80 0x80
Thistle---------->0xD8 0xBF 0xD8
Tomato---------->0xFF 0x63 0x47
Turquoise---------->0x40 0xE0 0xD0
Violet---------->0xEE 0x82 0xEE
Wheat---------->0xF5 0xDE 0xB3
White---------->0xFF 0xFF 0xFF
WhiteSmoke---------->0xF5 0xF5 0xF5
Yellow---------->0xFF 0xFF 0x00
#endregion Couleur RGB


Thanks. We will look into this. i think this is a bug int eh gadgeteer core




Can you please provide a complete yet simple example that shows this error? We are no able to reproduce on our end.


Sorry for Delay,
I will simplify the project & send it by eMail to you…
PS: it is a part of an professionnal project, some icons are copyrighted, Please do not transmit the project,


Switching On and Off the Button on Slot_8 will generate Yeelow or Lime texte (AL or OK)


I’ve bought FEZHydra to test if my display’s bug persists, (and also for test)
But I can’t deploy it to FEZHydra (?)

FEZHydra is powered & OnBoard Led is flashing but :
VS2010 Prof. can’t deploy even a simple application as : Debug.Print(“Program Started”); (the default program).

It detects FEZHydra [Transport : USB Device : FEZ Hydra_FEZHydra ]
But : I’ve a deployment error ! :
Error 1 An error has occurred: please check your hardware.

What did I make as mistake ?

I’ve started MF Deployment Tool & erased FEZHydra : It did it correctly (
Cannot find any entrypoint!
Waiting for debug commands…
Now, the LED does not flash any more, but still :
Error 1 An error has occurred: please check your hardware.

(Can you also send me a link to send you the simple Display projet with my bug?)


For FEZHydra, Here is the Device Capabilities :

HalSystemInfo.halVersion: 4.1.2821.0
HalSystemInfo.halVendorInfo: Microsoft Copyright © Microsoft Corporation. All rig
HalSystemInfo.oemCode: 255
HalSystemInfo.modelCode: 0
HalSystemInfo.skuCode: 65535
ClrInfo.clrVersion: 4.1.2821.0
ClrInfo.clrVendorInfo: Microsoft Copyright © Microsoft Corporation. All rig
ClrInfo.targetFrameworkVersion: 4.1.2821.0
SolutionReleaseInfo.solutionVersion: 4.1.2821.0
SolutionReleaseInfo.solutionVendorInfo: Microsoft Copyright © Microsoft Corporation. All rig
SoftwareVersion.BuildDate: Dec 6 2011
SoftwareVersion.CompilerVersion: 410561
FloatingPoint: True
SourceLevelDebugging: True
ThreadCreateEx: True
LCD.Width: 320
LCD.Height: 240
LCD.BitsPerPixel: 16
AppDomains: True
ExceptionFilters: True
IncrementalDeployment: True
SoftReboot: True
Profiling: False
ProfilingAllocations: False
ProfilingCalls: False
IsUnknown: False


There is know issue with USB on hydra that is fixed already and SKD will be out in few days to cover it and many other improvements.


Hello again,
Concerning my display’s bug : This is really a problem with Green color ! :
As I’m devopping WPF projects for PC, I’ve replaced :
Colors.Green by Utility.ColorFromRGB(0x00, 0xFF, 0x00) which is not green but Lime, a color I’m using currently…

I tried with real equivalent Green color : ColorUtility.ColorFromRGB(0x00, 0x80 , 0x00); //Green it doen’t work same than Colors.Green !!!

To sum up :
Doesn’t Work on T35 display:
str_Text_Line_02_Text_02.ForeColor = Colors.Green;
str_Text_Line_02_Text_02.ForeColor = ColorUtility.ColorFromRGB(0x00, 0x80 , 0x00); //Green

Works perfectly well on T35 display:
str_Text_Line_02_Text_02.ForeColor = ColorUtility.ColorFromRGB(0x00, 0xFF, 0x00); //Lime


Thanks for answer with USB hydra’s problem, I will wait…


Isn’t this green? So you see lime instead? This will be easy once you compare to hydra. Maybe there is a hardware problem.


I tried with a standard WPF appl .Net Framework for PC :
On a black window’s background :
Green is very dark compare to Lime which is a “light” green.

On T35 display .NETMF :
Lime is very clear & “very visible” but Green is not visible at all independly of the instruction : ColorUtility.ColorFromRGB(0x00, 0x80 , 0x00) is not better than Colors.Green;