PackagesCanonicalsLogsProblems
    Packages
    de.gematik.hddt@1.0.0-rc
    https://gematik.de/fhir/hddt/StructureDefinition/hddt-continuous-glucose-measurement
description: Profile for capturing continuous glucose measurements from real-time monitoring devices (esp. rtCGM). \n\nThis profile defines the exchange of raw measurement data for the Mandatory Interoperable Value (MIV) \\\"Continuous Glucose Measurement\\\" which is technically defined \nby the ValueSet _hddt-miv-continuous-glucose-measurement_. This MIV is e.g. implemented by real-time Continuous Glocose Monitoring devices (rtCGM) and Automated Insulin Delivery systems (AID) that control \nan insulin pump from rtCGM data. Future non-invasive measuring methods will expectedly be linked with this MIV and therefore use this profile for sharing data with DiGA, too.\n\n**Obligations and Conventions:**\n\nDevices for continuously measuring glucose values may produce data with a sample rate of more than 1000 values per day (e.g. current\nrtCGM provide measures for glucose in interstitial fluid with up to one value per minute). For sharing such data efficently, this profile\nmakes use of the FHIR [sampledData](https://hl7.org/fhir/R4/datatypes.html#SampledData) data type. Sampled data is portioned into\nchunks of a fixed size (for an exception see below), with the chunk size being set by the resource server (e.g. such that 24 h of measurements fit into a single chunk). If a DiGA\nrequests data for a period where the end time is earlier that the expected end time of the current chunk, the resource server only fills up the chunk \nup to the requested end time and sets the `Observation.status` to _incomplete_ while `Observation.effectivePeriod` captures the \nfull period of the chunk (see section \\\"Retrieving Data\\\" in the HDDT specification for details on chunks and missing data). \n\nEach Continuous Glucose Measurement MUST either hold a reference to a _Sensor Type And Calibration Status_ [DeviceMetric](https://hl7.org/fhir/R4/devicemetric.html) resource or to a \n_Personal Health Device_ [Device](https://hl7.org/fhir/R4/device.html) resource (eXclusive OR). A reference to _Sensor Type And Calibration Status_ MUST be provided \nfrom the Observation resource if the sensor for continuous measuring needs to be calibrated (either automatically or by the user) \nor if the sensor may change its calibration status over time. A change in `DeviceMetric.calibration.state` or a change of `Device.status` to _inactive_ finalizes the\ncurrent chunk and therefore is the only reason why a chunk may be smaller than the defined fixed size. \n\n**Constraints applied:**  \n- `code` is constrained to the ValueSet that represents the MIV _Continuous Glucose Measurement_\n- `effective[x]` is restricted to `effectivePeriod` and constrained as mandatory. Both a starting time and an end tme MUST be given.\n- `value[x]` is restricted to _valueSampledData_. The elements `valueSampledData.origin.unit`, `valueSampledData.origin.system`, and `valueSampledData.origin.code` are mandatory. `valueSampledData.origin.system` is restricted to UCUM. `Observation.valueSampledData` MAY only be omitted in case of an error that accured with the measurement. In this case, `Observation.dataAbsentReason` MUST be provided.\n- `device` is set to be mandatory in order to provide the DiGA with information about the sensor's calibration status and with information about the static and dynamic attributes of the Personal Health Device.
package_name: de.gematik.hddt
derivation: constraint
name: HddtContinuousGlucoseMeasurement
type: Observation
elements:
  value[x]:
    elements:
      origin:
        elements:
          unit: {short: Unit of continuous glucose measurement, index: 10}
          system:
            pattern: {type: Uri, value: 'http://unitsofmeasure.org'}
            index: 11
          code:
            short: UCUM code for unit of measurements
            binding: {strength: required, valueSet: 'http://hl7.org/fhir/ValueSet/ucum-units'}
            index: 12
        required: [system, code]
      data: {index: 13}
    required: [data]
  value:
    short: Series of glucose measurements
    mustSupport: true
    choices: [valueSampledData]
    index: 8
  effective[x]:
    elements:
      start: {index: 5}
      end: {index: 6}
    required: [start, end]
  valueSampledData: {type: SampledData, short: Series of glucose measurements, mustSupport: true, choiceOf: value, index: 9}
  status: {short: Status of the continuous glucose measurements chunk, index: 0}
  effective:
    short: Time interval covered by the CGM measurement chunk
    choices: [effectivePeriod]
    index: 3
  code:
    short: Type of continuous glucose measurement
    binding: {strength: required, valueSet: 'https://gematik.de/fhir/hddt/ValueSet/hddt-miv-continuous-glucose-measurement'}
    index: 1
  device:
    type: Reference
    short: Reference to personal health device or its sensor type and calibration status
    refers: ['https://gematik.de/fhir/hddt/StructureDefinition/hddt-personal-health-device', 'https://gematik.de/fhir/hddt/StructureDefinition/hddt-sensor-type-and-calibration-status']
    index: 15
  dataAbsentReason: {index: 14}
  effectivePeriod: {type: Period, short: Time interval covered by the CGM measurement chunk, choiceOf: effective, index: 4}
package_version: 1.0.0-rc
class: profile
kind: resource
url: https://gematik.de/fhir/hddt/StructureDefinition/hddt-continuous-glucose-measurement
base: http://hl7.org/fhir/StructureDefinition/Observation
version: 1.0.0-rc
required: [device, effectivePeriod, effective]