-3
\$\begingroup\$

I have using arduino Uno . I have used serial in parallel out to display the parameter. Here i am pasting the piece of code.

Totally i have 8 digit of 7 segment display.Dissect & Dissect2 split the value and place into segment

Currently i have test condition under current fault. with below piece of function I could able to display 001.3 on top and UC-F at bottom.

I am looking for C function where i could able to display like R01.3 on top and UC-F on bottom.someone help me coding to display character like mentioned.

const unsigned char Variable[28] = {0x03,0x9F,0x25,0x0D,0x99,0x49,0x41,0x1F,0x01,0x09,0x11,0x83,0x31,
                                      //0  //1  //2  //3  //4  //5  //6  //7  //8  //9  //A  //U  //P
                                     0xD1,0xE3,0x89,0x63,0xE1,0xF5,0xC1,0x61,0x71,0xF3,0xFD,0xD5,0x85,0xFF,0x91};
                                      //h  //L  //Y  //C  //t  //r  //b   //E //F  //I  //-  //n //d  //blank //H



 float Rph_Current=13.0;
 float Yph_Current=0.0;
 float Bph_Current=1.0;





void Split(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] = Variable[Temp];
    }
}



void Split_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] = Variable[Temp];
    }

}


//*********************************************************************************
//              Current   scaling
//********************************************************************************
void current_scaling(unsigned int current) {
    if(current>=10000) {
        Dec_pt = 0;
        temp=current/10;
        Split(temp);
    } else {
        Dec_pt = 1 ;
        Split(current);
    }
}

void Faults(unsigned char Chr1,unsigned char Chr2,unsigned char Chr3,unsigned char Chr4,unsigned char Chr5,unsigned char Chr6,unsigned char Chr7,unsigned char Chr8) {

    LEDBuffer_1[0] = Variable[Chr1];
    LEDBuffer_1[1] = Variable[Chr2];
    LEDBuffer_1[2] = Variable[Chr3];
    LEDBuffer_1[3] = Variable[Chr4];
    LEDBuffer_1[4] = Variable[Chr5];
    LEDBuffer_1[5] = Variable[Chr6];
    LEDBuffer_1[6] = Variable[Chr7];
    LEDBuffer_1[7]=  Variable[Chr8];

}

void Display_par() {
    Disply_Par=1;

    switch(Disply_Par) {

        case 1: 
            Faults(18,0,0,0,11,16,23,21);
            //             (r,0,0,0,U,C,-,F)   
            Display_Current(18,Rph_Current);
            // current_scaling(Rph_Current);
            UnderCurr_Flag=0;
            break;

        case 2:
            Split_2(OL_Point);
            Faults(20,0,0,0,0,14,23,21); //Overload Error
            break;

        default :
            break;




    }

}
\$\endgroup\$

put on hold as unclear what you're asking by Lundin, Blup1980, Dwayne Reid, RoyC, JRE Jan 12 at 23:34

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • 2
    \$\begingroup\$ What do you expect people here to do? This is not a code writing service. Also pay attention to tags. microchip does not fit here, but arduino probably does. Finally, please read stackoverflow.com/help/how-to-ask \$\endgroup\$ – domen Jan 9 at 14:58