I'm brand new to 4DGL and the PICASO, so go easy on me! Here's what I'm trying to do:
I'm using a gen4-uLCD-24PT and I'm trying to display an engine's RPM on a cool gauge object using ViSi (not ViSiGenie).

The actual engine RPMs run from 0 - about 4500, but because of the small screen size we're using, I couldn't have the gauge go from 0 - 5000, the digits looked way to crammed in there. So I'm having to display the RPMs in thousands of RPMs (i.e. a real engine RPM of 3250 should set the needle's position to 3.25). I want the digit field at the bottom of the gauge to display the raw number (i.e a real RPM of 3250 should display 3250, not 3.25). How do I go about doing this?
I'm trying to find and read through the documentation for the cool gauge, and from what I've found, I'm making the following assumptions (obviously correct me if I'm wrong!):
- I think that when I inserted a cool gauge into my project, that Workshop automatically generated a bunch of image frames for the gauge with the needle at various positions?
- I think I need to access those images via img_SetWord(hndl, iRevButton, IMAGE_INDEX,FRAME_NUMBER) where "FRAME_NUMBER" is the correct image based on my actual value?
Assuming that's right, how do I calculate what frame number corresponds to my raw value? I don't know enough yet to know how many frames were generated.
How do I set the text value to my raw value separately from the RPM / 1000 value that needs to be set for the needle?
If my assumptions are wrong, I'd appreciate knowing how to do this!
If it matters, these are the properties of the cool gauge object
Coolgauge
Name RPMGauge
Alias Coolgauge1
Arc.Color 0xFFEFE0
Arc.Opacity 200
Arc.StartAngle 135
Arc.StopAngle 405
Threshold.Center 25
Threshold.Color 0xFFD0AF
Threshold.EndValue 100
Threshold.Opacity 200
Threshold.Span 25
Threshold.StartAngle 135
Threshold.StartValue 0
Threshold.SweepAngle 270
Threshold.ThresholdKind Angle
Arc.Width 0.03
CircleEndValue 360
CircleStartValue 0
DialText RPM
Digit.Alignment Right
Digit.BackGroundColor 0xFFEFE0
Digit.BackGroundOpacity 30
Digit.Color WHITE
Digit.Visible Yes
DivisionColor WHITE
DivisionCount 5
DivisionWidth 2
EqualDimensions Yes
Font.Color WHITE
Font.Effects []
Font.Name Tahoma
Font.Size 14
Font.Style []
Height 167
Innercircle.Color BLACK
Gloss.Color clWhite
Gloss.Opacity 72
Innercircle.Opacity 200
Left 28
Logarithmic No
LogarithmicBase 10
MaximumValue 5
MinimumValue 0
Needle.Color WHITE
Needle.InnerCenterColor WHITE
Needle.InnerCenterColorTo 0xFFD0AF
Needle.InnerCenterOpacity 255
Needle.OuterCenterColor 0xFFD0AF
Needle.OuterCenterColorTo WHITE
Needle.OuterCenterOpacity 255
Needle.ShineColor 0xFFEFE0
Needle.ShineColorTo 0xD0D0D0
OuterCircle.Color 0xFFD0AF
OuterCircle.Opacity 100
OuterCircle.Width 0.03
OuterRim.Color 0x908070
OuterRim.Opacity 255
OuterRim.Width 2
ShowValues Yes
SubDivisionColor WHITE
SubDivisionCount 1
SubDivisionWidth 2
TextRendering ClearType
Top 0
ValueFont.Color WHITE
ValueFont.Effects []
ValueFont.Name Tahoma
ValueFont.Size 11
ValueFont.Style []
ValueFormat 0
Width 167
OnChanged ''
end
I'm using a gen4-uLCD-24PT and I'm trying to display an engine's RPM on a cool gauge object using ViSi (not ViSiGenie).
The actual engine RPMs run from 0 - about 4500, but because of the small screen size we're using, I couldn't have the gauge go from 0 - 5000, the digits looked way to crammed in there. So I'm having to display the RPMs in thousands of RPMs (i.e. a real engine RPM of 3250 should set the needle's position to 3.25). I want the digit field at the bottom of the gauge to display the raw number (i.e a real RPM of 3250 should display 3250, not 3.25). How do I go about doing this?
I'm trying to find and read through the documentation for the cool gauge, and from what I've found, I'm making the following assumptions (obviously correct me if I'm wrong!):
- I think that when I inserted a cool gauge into my project, that Workshop automatically generated a bunch of image frames for the gauge with the needle at various positions?
- I think I need to access those images via img_SetWord(hndl, iRevButton, IMAGE_INDEX,FRAME_NUMBER) where "FRAME_NUMBER" is the correct image based on my actual value?
Assuming that's right, how do I calculate what frame number corresponds to my raw value? I don't know enough yet to know how many frames were generated.
How do I set the text value to my raw value separately from the RPM / 1000 value that needs to be set for the needle?
If my assumptions are wrong, I'd appreciate knowing how to do this!
If it matters, these are the properties of the cool gauge object
Coolgauge
Name RPMGauge
Alias Coolgauge1
Arc.Color 0xFFEFE0
Arc.Opacity 200
Arc.StartAngle 135
Arc.StopAngle 405
Threshold.Center 25
Threshold.Color 0xFFD0AF
Threshold.EndValue 100
Threshold.Opacity 200
Threshold.Span 25
Threshold.StartAngle 135
Threshold.StartValue 0
Threshold.SweepAngle 270
Threshold.ThresholdKind Angle
Arc.Width 0.03
CircleEndValue 360
CircleStartValue 0
DialText RPM
Digit.Alignment Right
Digit.BackGroundColor 0xFFEFE0
Digit.BackGroundOpacity 30
Digit.Color WHITE
Digit.Visible Yes
DivisionColor WHITE
DivisionCount 5
DivisionWidth 2
EqualDimensions Yes
Font.Color WHITE
Font.Effects []
Font.Name Tahoma
Font.Size 14
Font.Style []
Height 167
Innercircle.Color BLACK
Gloss.Color clWhite
Gloss.Opacity 72
Innercircle.Opacity 200
Left 28
Logarithmic No
LogarithmicBase 10
MaximumValue 5
MinimumValue 0
Needle.Color WHITE
Needle.InnerCenterColor WHITE
Needle.InnerCenterColorTo 0xFFD0AF
Needle.InnerCenterOpacity 255
Needle.OuterCenterColor 0xFFD0AF
Needle.OuterCenterColorTo WHITE
Needle.OuterCenterOpacity 255
Needle.ShineColor 0xFFEFE0
Needle.ShineColorTo 0xD0D0D0
OuterCircle.Color 0xFFD0AF
OuterCircle.Opacity 100
OuterCircle.Width 0.03
OuterRim.Color 0x908070
OuterRim.Opacity 255
OuterRim.Width 2
ShowValues Yes
SubDivisionColor WHITE
SubDivisionCount 1
SubDivisionWidth 2
TextRendering ClearType
Top 0
ValueFont.Color WHITE
ValueFont.Effects []
ValueFont.Name Tahoma
ValueFont.Size 11
ValueFont.Style []
ValueFormat 0
Width 167
OnChanged ''
end
Comment