sprint() calls itoa anyway!! So you are kinda using it!!
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
void TransformTime(void)
{
hours = (((hours & 0xF0) >> 4)*10 + (hours & 0x0F)) & 0x3F; // Transform hours
year = (year & 0xC0) >> 6; // Transform year
day = (((day & 0x30) >> 4)*10 + (day & 0x0F)) & 0x3F; // Transform day
month = (((month & 0x10) >> 4)*10 + (month & 0x0F)) & 0x3F; // Transform month
}
Correct.Ian Rogers with this format I no longer need itoa is that correct?
You're as bad as me..... 16 not 6As I said in post 7 to go from binary to bcd add (bin/10)*6.
I.E
bcd=bin+((bin/10)*6);
OR
num+=(num/10)*6;
Mike.
Let's see,You're as bad as me..... 16 not 6
typedef unsigned char bool;
union
{
struct
{
bool pumptimer1:1; /*using the bits to flag if */
bool pumptimer2:1; /*a run timer is in use*/
bool pumptimer3:1;
bool pumptimer4:1;
bool pumptimer5:1;
bool pumptimer6:1;
bool pumptimer7:1;
bool pumptimer8:1;
};
}pmptmr; //pump timer status
++bb;
timer 0x01 <<bb; //bit shift to the left "bb" times
if (pmptmr && timer &= On)
{
I2C1_MasterRead(*pdata,3,RTCC,*pflag);
}