Patent ID: 7953492

Claim:
A method of storing data for an implantable medical device (IMD), the method comprising: digitizing values of a physiologic waveform to obtain data points, wherein the sampled data points make up a sampled data set; providing a truncated entropy encoding codeword set in the device for probable data values and including a prefix codeword indicating that a predetermined amount of data following the prefix codeword is unencoded; assigning a data point value to an exit code, wherein the exit code indicates that a predetermined amount of data following the exit code is annotation data; employing the device to parse the sampled data set of the waveform to select ones of the data points and replace the selected ones of the data points with codewords; employing the device to analyze the waveform to identify an occurrence of one or more predetermined events; storing the codewords and those ones of the data points which were not replaced with codewords in the device; employing the device to annotate the stored data if one or more of the predetermined events occurs, wherein the annotation includes storing the prefix codeword, followed by the exit code, followed by the annotation data at a point in time of the occurrence if a codeword is expected and storing the exit code followed by the annotation data at the point of time of the occurrence if a codeword is not expected; and employing a transceiver to telemeter the stored data out of the implanted medical device.