MAX7219 as Volts/Amps Displayer

Status
Not open for further replies.

imranahmed

Advanced Member level 3
Joined
Dec 4, 2011
Messages
817
Helped
3
Reputation
6
Reaction score
3
Trophy points
1,298
Location
Karachi,Pakistan
Activity points
6,492
Please let me know that about combine amp and volt meter Arduino UNO based.

I want to display amperes and voltages on seperate 3 digits 7-segment display

3 digits for amps and 3 digits for volts and using 2 channel of ADC.

But how to display using MAX7219 ,can anyone interesed to tell me?

Only hint I need.
 

There is any arduino library available for displaying float values comes from adc

on 7-segment display by using MAX7219 with arduino.
 

Then why don't you use that ? I have a non Arduino C Code for displaying two 3 digit values on eight 7 Segment displays. I am using it for a stabilizer which displays IN volts and OUT volts. I will post it in a day or two. I have to find it on my disk.
 

I think he means there is no library available for displaying float values comes from adc ??
 

Is there any arduino library for displaying ADC float values by using MAX7219.
 

I have c code which displays float values on MAX7219 based 8 digit 7 Segment displays. I will post it soon. You can convert it to Arduino code.
 
I wrote this code using Arduino UNO MAX7219 library and want to display 8.03
it cannot display 8.03 but it displays 8.05 when I write 8.06 it displays 8.08

Not exact value display??
What can I do for fix this issue?


Code:
int CTones=0 , CTtens=0 ,CThundreds=0; 
unsigned int CTdv1=0;
float CT_SET = 8.03;
    
    if(CT_SET >= 0 && CT_SET <= 10)
    {
    CTdv1 = CT_SET * 100;  
    dp0 = 1;     
    dp1 = 0; 
    dp2 = 0; 
    CTones = (byte)CTdv1%10;
    CTtens = (byte)(CTdv1/10)%10;
    CThundreds = (byte)(CTdv1/100)%10;   
    lc.setDigit(0,2,(byte)CTones,dp2);
    lc.setDigit(0,1,(byte)CTtens,dp1);
    lc.setDigit(0,0,(byte)CThundreds,dp0);    
    } 
    else if(CT_SET >= 10 && CT_SET <= 99)
    {
    CTdv1 = CT_SET * 10;  
    dp0 = 0;
    dp1 = 1;  
    dp2 = 0;
    CTones = (byte)CTdv1%10;
    CTtens = (byte)(CTdv1/10)%10;
    CThundreds = (byte)(CTdv1/100)%10;   
    lc.setDigit(0,0,(byte)CThundreds,dp0);
    lc.setDigit(0,1,(byte)CTtens,dp1);
    lc.setDigit(0,2,(byte)CTones,dp2);
    } 
    else if(CT_SET >= 100 && CT_SET <= 999)
    {
    CTdv1 = CT_SET * 1;
    dp0 = 0;
    dp1 = 0;  
    dp2 = 0;  
    CTones = (byte)CTdv1%10;
    CTtens = (byte)(CTdv1/10)%10;
    CThundreds = (byte)(CTdv1/100)%10;   
    lc.setDigit(0,0,(byte)CThundreds,dp0);
    lc.setDigit(0,1,(byte)CTtens,dp1);
    lc.setDigit(0,2,(byte)CTones,dp2);
    }
    else if(CT_SET > 999)
    {
    lc.setChar(0,0,'-',false);
    lc.setChar(0,1,'-',false);
    lc.setChar(0,2,'-',false);
    }     
    else if(CT_SET < 0)
    {
    lc.setChar(0,0,'-',false);
    lc.setChar(0,1,'-',false);
    lc.setChar(0,2,'-',false);
    }
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…