## 3 Results and Discussion  
### Workflow from Data Acquisition to Location Tracking  
#### 3.1.1 Signal Processing of Physiological Parameters  
As illustrated in the Methods section, the Adafruit Python library and the WFDB libraries were used on BBB to obtain the vital signs and physiological samples from the sensor modules. The signals acquired from the vital signs sensors were noisy, so they had to be filtered using signal processing utilities in the MATLAB signal processing toolbox. The BBB hardware support package enabled the execution of MATLAB scripts on the BBB hardware for some functions. Alternatively, the MATLAB Coder tool could emit C programs for the corresponding MATLAB scripts for the target processor (Texas Instruments Sitara ARM Cortex A8), hosted on BBB. The motion artefact were removed using the stationary wavelet transform 'level 5' decomposition and'sym4' wavelet (code Expression (2)) with the MATLAB Stationary Wavelet Transform De-noising tool, as shown in Figure 4, which shows corrected waveform overlaying the noisy waveform. The signal-noise ratio observed was 27.83 dB. The maximal overlap discrete wavelet transform (MODWT) using the modwt function in MATLAB could enhance the R-peaks in the ECG waveform acquired from the ECG sensor, which helped to reconstruct a frequency-localized version of the waveform using only the wavelet coefficients. The coefficients correspond to the approximate frequency passbands, which could maximize QRS energy. The findpeaks function in MATLAB enabled in isolation of the R-peaks in the waveform for vital signs readings as seen in MATLAB code Expression (2):  
\[ \begin{array}{l}\text{wtrans}=\text{modwt(ecgsig,5);}\\ \text{wtrec}=\text{zeros(size(wtrans));}\\ \text{wtrec(4:5,:)}=\text{wtrans (4:5,:);}\\ \text{y}=\text{imodwt(wtrec,'sym4');}\\ \text{y}=\text{abs(y)}\text{.}^{2};\\ \text{[qrspeaks, locs]}=\text{findpeaks(y, tm,'MinPeakHeight', 0.1, 'MinPeakDistance',0.150);}\\ \end{array}  \tag{2}\]  
Figure 3: SMART FHIR server architecture showing the RESTful Web services that could be accessed from an embedded system hardware (Beaglebone Black). In order to demonstrate the filtering mechanism, samples from MIMIC II Numerics (Record 033n) database were read into MATLAB. These samples could have very well been gathered, using the composite sensor kit, from a real human subject undergoing traumatic experience and/or injury. The samples were filtered using parameters set in MATLAB code Expressions (3) using a fourth-order Kaiser Window:  
%E.g. ecg033 array(;,2) contained the Physiological samples for MIMIC II record 033n  
\[\text{Hd}=\text{designfilt}(\text{`lowpassfir',FilterOrder',20,`CutoffFrequency',150,} \tag{3}\]  
'DesignMethod','window','Window',(@kaiser,4),'SampleRate',1024);  
y1 = filter(Hd,ecg033 array(:,2));  
The filtering mechanism induces phase lag, and in order to eliminate the lag, group delay had to be introduced according to Expression (4). A Savitzky-Golay filter (sgolay) was used as a smoothing algorithm with order = 3 and frame length = 51, as in Expression (4):  
\[\text{fvtool(Hd,'Analysis','grpdelay');} \tag{4}\] \[\text{sgf}=\text{sgolayfilt}(\text{ecg033 array(:,2),3,51});\] (5) \[\text{y1}=\text{filtilt}(\text{Hd,ecg033 array(:,2)}); \tag{6}\]  
The respiration rate and systolic blood Pressure could be calculated for real human subjects from the composite sensor kit using the ECG and PPG waveforms and the PTT. Since the objective was to calculate the trauma measures for trauma patients, vital signs samples from the MIMIC II Numerics database (e.g., MIMIC Numerics record = 033n) were used for statistical analysis. The spectral image, Figure 5, of the respiratory rate signal for the patient (MIMIC Numerics Record = 033n) admitted to ICU clearly showed two episodes of'significant drop in respiratory rate', which agrees with the patient condition of respiratory rate failure. Figure 4: Noise removal in the ECG signal using stationary wavelet transforms 1-D (MATLAB) using ‘sym4’ wavelet and level ‘5’ decomposition.