# idea for displaying value on 4 digit 7 segment display

Dear all,

I am using 4 digit 7 segment display . I am using INC and DEC key to change value. I have one parameter wanted to display 25000. Since i have only 4 segment how i can display the value

here is part of code
I could able to display 9999 as 999.9 in my display. after 9999 and 25000 value i would like to remove decimal and display only digit.

int NCRT_Mod=0;
int NCRT=0;

``````     if (NCRT > 0 && NCRT <= 9999) {
NCRT = NCRT + 200;
Dec_pt = 1;
Dissect_2(NCRT);
} else if (NCRT > 9999 && NCRT <= 25000) {
NCRT_Mod = NCRT / 10;
NCRT_Mod = NCRT_Mod + 200;
Dissect_2(NCRT_Mod);

}
if (NCRT > 25000)
NCRT = 5;

void Dissect_2(unsigned int Value) // Spliting of process value in digits form
{
unsigned char a, Temp;
for (a = 4; a >= 1; a--) {
Temp = Value % 10;
Value = Value / 10;
LEDBuffer_1[a - 1] = DISPTABLE[Temp];
}

}
``````

why not display the value but divided by 10?

if for the range 0 - 25000, display reads 0 - 2500

so for example if you had set your value to 1, your display would show 0.1...

Scientific notation? 25000 -> 25 * 10^3 -> "25E3" . You only get two significant digits for values over 9999 but you can go up to 99,000,000,000 ("99E9"). With one significant digit you get close to a googol: 9E99