## 3 Proposed OCC IoMT Platform (Design and Implementation)
### Transmitter  
The transmitter section utilizes an 8 \(\times\) 8 LED matrix with OOK modulation. During the OOK modulation process in OCC, data transmission is managed through LEDs, altering the light intensity between two states: the LED is on to represent the \"1\" bit and off for the \"0\" bit. In operation, the 8 \(\times\) 8 LED matrix consistently generates light patterns based on the sequence of bits received, which are then captured by an optical camera serving as  
Figure 3: Block diagram of the IoMT OCC platform.  
the receiver. Algorithm 1 outlines OOK algorithm steps for mapping data received from each sensor onto the \(8\times 8\) LED matrix, which is subsequently modulated. The initial phase involves configuring pin parameters for the pulse oximeter sensor and LED matrix \(8\times 8\) and initializing serial communication. In this research, we utilized the MAX30102 sensor as the pulse oximeter sensor and the LED matrix is configured through Neopixel library. Moreover, anchor, LED ID, and sequence number are also initialized before transmitting the data. The program then enters a continuous main loop, reading oxygen saturation, heart rate, and temperature values from the MAX30102 sensor. In addition, it monitors the status of the panic button, detecting if it has been pressed.  
```
1: Define pins and settings for LED matrix \(8\times 8\) and a pulse oximeter sensor.
2: Initialize LED matrix \(8\times 8\), Serial communication, and pulse oximeter sensor.
3: Initialize anchor, LED ID, and sequence number to each patient.
4:functionReadOS, ReadHT, ReadT,
5: Read oxygen saturation, heart rate and temperature value from pulse oximeter sensor
6:return oxygen saturation, heart rate and temperature
7:endfunction
8:functionDectoBin(b)
9: Convert integer b to binary string
10:return Convert
11:endfunction
12:Main Loop:
13:while true do
14:if Serial available then
15: Read data until a newline character
16:endif
17: Clear LED matrix \(8\times 8\) and define array a with preset values for pixel indices
18: Read status of the panic button
19: Read oxygen saturation, heart rate, and temperature data from respective sensors
20: Convert the status of the panic button, oxygen saturation values, heart rate values, and temperature values to binary strings
21:for each bit in binary strings do
22:if bit is '1' then
23: Update array a with corresponding pixel indices
24:endif
25:endfor
26: Set LED matrix \(8\times 8\) status ON/OFF based on updated array a
27: Show updated pixel status ON/OFF on LED matrix \(8\times 8\)
28:endwhile
```  
**Algorithm 1** Pseudocode--\"Transmitter\"  
Subsequently, data from the MAX30102 sensor and the panic button status are transformed into a binary format. For each value of oxygen saturation, heart rate, temperature, and status of the panic button, a corresponding binary representation is created. Based on these binary representations, the \"a\" array is updated to determine which pixels in the LED matrix will switch states (on/off). Thus, each index corresponds to one pixel on the LED matrix. Following this modification, the on/off states of the LED matrix pixels are aligned with the refreshed values in the array. Furthermore, as initialized in the beginning, the sequence number (SN) along with an anchor and LED ID is assigned to the \"a\" array. Each process is repeated in the main loop. This process encompasses additional procedures for reading sensor values, including the panic button state, and functions for converting integer values into binary strings. The comprehensive pseudocode delineates the procedures for accessing, processing, and visualizing data on the NeoPixel matrix based on the sensor inputs and panic button state, thereby providing a unique identifier for each connected patient.