Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
07/21/04 08:50
Read: times


 
#74541 - RE: Memory devices for 8051_Compress?
Responding to: ???'s previous message
well why not just

temp=get_temp()
if temps!=prev_temp
{
store number of occurence of the temp
store 8/16 bit coded new temp
n=0
}
else
{
n++;
}

with a nice shutdown method like
store n

and a nice starting method that does
store current_temp
n=0
prev_temp = current_temp

simple log format, low size
depending of characteristic precision or timespan of the same temps you could choose 8 bit

if you like to compress a litle bit more you could always do a memory alloc like that

| 8/16 bit temp | 1 long flag | 7 bit if (!long) /15 bit if (long)|

the principle is extendable to any precision, data type ... remember that the first bit of a float or long float is sign bit so you can use it to store wether it is a float or a long float (i m no HW guru but there are some tricks in my magic bag)

Glances
Benjamin

List of 16 messages in thread
TopicAuthorDate
Memory devices for 8051            01/01/70 00:00      
   RE: Memory devices for 8051            01/01/70 00:00      
   RE: Memory devices for 8051            01/01/70 00:00      
      Memory devices for 8051_Compress?            01/01/70 00:00      
         RE: Memory devices for 8051_Compress?            01/01/70 00:00      
         RE: Memory devices for 8051_Compress?            01/01/70 00:00      
         Run-Length Encoding            01/01/70 00:00      
         RE: Precious Memory?            01/01/70 00:00      
             Memory Clarifications - Erik & Andy            01/01/70 00:00      
               OTish .....            01/01/70 00:00      
                  RE: OTish .....            01/01/70 00:00      
                     RE: OTish .....            01/01/70 00:00      
      RE: Memory devices for 8051            01/01/70 00:00      
         RE: Memory devices for 8051            01/01/70 00:00      
            RE: Memory devices for 8051            01/01/70 00:00      
               RE: Memory devices for 8051            01/01/70 00:00      

Back to Subject List