{'fraction_non_alphanumeric': 0.02531863589390286, 'fraction_numerical': 0.010334137099552188, 'mean_word_length': 4.398884239888424, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Stroke therapy using an interactive game with accelerometer and gyroscope sensor device

Stroke is one of the diseases that have a long-term impact on people who suffer it. Patients are feared not only for the “sudden attacks,” but also for the after-effect due to the disease itself. The paralysis of certain limbs is very disturbing and even inhibits the activity of a patient’s life. The process of rehabilitation usually takes a long time, and the patients experience boredom easily. In the rehabilitation process, there are several tools needed by post-stroke patients, such as the use of motion aids and using memory exercise aids such as brain games. Here in this study, accelerometer sensors and gyroscope sensors were used to create a post-stroke therapy game. With this stroke therapy game, patients are expected to be happier to perform the process of stroke therapy and to make stroke therapy more fun, interactive, and can be done at home or elsewhere.


Introduction
Stroke, or cerebrovascular accident (CVA), is the loss of brain function due to the disruption that comes from the lack of blood supply to the brain. The disruption can be caused by ischemia (lack of blood flow) by blockage or bleeding. As a result, Stroke affected areas cannot function, which can lead to an inability to move one part of the body, the inability to understand, and the inability to speak [1][2][3]. Stroke is one of the diseases that have a long-term impact on people who experience it. Not only are the "sudden attacks" feared, but also the after-effects. The condition of paralysis in certain limbs will certainly be very disturbing and even inhibit the activity of one's life.
Post-stroke patients require continued therapy to restore their physical state. Therefore, patients are encouraged to follow the physical rehabilitation process continuously. This rehabilitation process is required to restore the patient's condition as before, and improve the quality of life.
The process of rehabilitation takes a long time so that patients experience boredom easily. In the rehabilitation process, there are several tools needed by post-stroke patients, such as the use of motion aids and using memory exercise aids such as brain games.
Physical exercises that will be applied by a stroke patient should follow some basic rules so that the results are optimal. Some things to consider when doing physical exercise as follows: It focuses on strength training, balance, and stability. On this basis, we proposed to make a therapy system to petrify ICI_ME 2020 IOP Conf. Series: Materials Science and Engineering 1003 (2020) 012157 IOP Publishing doi:10.1088/1757-899X/1003/1/012157 2 therapy in post-stroke patients by making Game of Unity that can be controlled by Arduino and using Accelerometer and Gyroscope sensor.
The movement to be accommodated in the game is to the left, right, forward, and backward. The movement will hold the balance when the game was played. Start the exercise with a warm-up first so that the muscles and joints are not stiff. The purpose of this thesis is to develop a stroke therapy system with the game to be more fun, interactive, and can be used at home.

Sensors and Processor
IoT is the network of physical gadgets, vehicles, home apparatuses, and different things implanted with hardware, programming, sensors, actuators, and availability, which empower these things to associate and trade information making open doors for more straightforward joining of the physical world into PC based frameworks [10]. Internet of Things cases are chosen since the topic grows quicker than enactment [11]. There are some sensors used in the game therapy system, named: Accelerometer and gyroscope. To process the sensor input and control the game, we utilized Arduino UNO and Unity Engine as software development tools.
The accelerometer is a sensor used to measure the acceleration of an object. The accelerometer can measure dynamic and static acceleration. Dynamic acceleration measurement is the measurement of acceleration in moving objects, whereas static acceleration is the measurement of the acceleration of the earth's gravity [4].
The gyroscope is a device for measuring or maintaining orientation, which is based on the principles of angular momentum. Mechanically, a gyroscope is shaped like a spinning wheel or a disc where the free shaft takes each orientation. Although this orientation is not fixed, the changes in response to external torques are much less and take place in different directions when compared with no angular momentum, which is associated with high levels of rotation and moment inertia [5,6].
The Arduino module is programmed using an Arduino Software (IDE) called sketches. Sketches are written in a text editor and saved with a .ino file extension. Arduino IDE is a software used to write and compile and is also used to upload programs to the Arduino board. Arduino IDE uses a language developed as its programming language. Results or output from Arduino can be observed using a serial monitor on IDE [7].
Unity Engine is a game engine that continues to grow. Game Engine is one game engine with a proprietary source license. Still, for development, the license is divided into 2, which is free (free) and paid according to the target device of application development. Unity does not restrict the publication of the application, unity users with a free license can publish applications that are created without having to pay license fees or pay to the unity developer [8].

System Design
The stroke therapy game is expected to help the patient to do therapy in a more easily and more eager, especially with the hands. Arduino controls this game, which is equipped with a gyroscope sensor and an accelerometer sensor. In general, the system was designed in Figure 1 below.  Figure 1, it is shown that the accelerometer sensor and gyroscope sensor transmit data in the form of X, Y, and Z-axis. Then Arduino Nano processes the data from the sensor. After Arduino Nano processes data, then it sends the data to PC via mini USB cable. PC processes the data into ASCII code (American Standard Code for Information Interchange). Then the ASCII code is accepted by Unity and used to move the player in the Left, Right, Middle, and Leap. After the patients move their hand left or right, then the game must receive more input from the sensor to make the next move. This process takes place continuously, as illustrated by the flowchart of Figure  2.

Hardware Design
In the hardware design, we used the MPU-6050 sensor module in which contains an accelerometer and gyroscope sensor included. These sensors act as input and provide information on whether the patient has moved his hand or not. Whenever the patient has moved his hand, there will be a change between the x, y, and Z-axes. This information will then be sent and processed by Arduino Nano.
MPU-6050 is a device in which there are an accelerometer and gyroscope in one PCB. This sensor is a power-saving device and has a high Accuracy. This sensor utilizes I2C communication for interfaces with Arduino. MPU-6050 is one of the products manufactured by Invensense company [2]. The MPU-6050 can be seen in figure 3 below.
For the processing module, Arduino Nano was occupied with processing data received from sensor MPU-6050. The result will then be sent via USB cable and then received by PC. After that, it is converted to ASCII code used to move the player in the game, as illustrated in Figure 1 above.

Figure 3. MPU-6050
Arduino is a platform of physical computing that is open source. The word "platform" here is an appropriate word choice. Arduino is not just a development tool, but it is a combination of sophisticated hardware, programming languages, and an Integrated Development Environment (IDE). IDE is very powerful software for writing programs, compile it into binary code and upload it into memory microcontroller [9].
The controller used by patients and become a tool to control the game can be seen in Figure 4.

Game Design
In designing the scenario of the game, we used Unity with C# programming language run on the Windows operating system. The game was designed to assist the patient in undergoing the process of stroke therapy, doing some movement on their hand. This game has a simple user interface that the nurse or even patient itself can use it easily.  Figure 5 shows the home interface of the game before the game is played. The nurse/patient can choose the level in the game. It is recommended to start the game from the lowest level of level 1. Since level one and level 2 is a warm-up session of the game, as shown in Figure 6.
At level 1, this patient just moves his hand to the right course. Level 1 functioned as a warm-up at the beginning of the game, and to train the patient to get used to using this game therapy tool. At level 1, the speed of the player has constantly been determined and cannot be changed.
In Figure 6, it can be seen that there are two buttons above the player display. Button, it serves as a regulator to control the player in the game. The Button consists of control 1 and controls 2. Control 1 has a function to change the player control to the left and right slide, while control 2 has the function to change the player control to turn left and turn right.
At level 3, the movement begins to increase to the right, to the left and kept in the middle. The hurdle becomes 3 kinds. Level 3 is also still using a constant speed and cannot be changed.
At level 4, this barrier is more diverse; the patient not only moves his hand to the left and right. But the patient also moves his hands in a twist. This rotate function is to jump on the player in Unity. In this level 4, game player speed is not constant but can be accelerated and can be slowed depending on the willingness of the patient, as can be seen in Figure 7. The game scenario and characteristic of each level can be seen in the table below:

Result and Discussion
As a result of therapy games for a stroke patient, we did some tests for each movement. First, we tested the system with the right movement. This test was done by moving the right hand and trying to see if the tool with the game works well. This experiment was conducted ten times, and the results are listed in Table 2. From Table 2, it can be seen that there was no failure of this tool. When the tool is moved to the right, then the player gives up the right. Next, we tested the system with the left movement. Left motion testing was done by moving the left hand. This test was also done as much as ten times. The results can be seen in Table 3 below.
Furthermore, we did a test on the jumping movement. This test is done by moving the hands upward when the player will leap the game. The results of this test are shown in Table 4 as follows. In this test, failure occurs as much as 2 times. That is on the 7th trial and the 9th experiment. The failure that occurs is the player late responding to the jumping movement. Table 2. Test results of the right movement Table 3 Test results of the Left movement Last, we tested the system for leaning movement to the right and left. This test was done by tilting the right hand and left hand individually. Its function was to move the right hand or left hand, which is making the player move to the right or left. The result is shown in Table 5 and Table 6.
To ensure the usability of the game in a different set of computer systems, we ran the game application using several computer specifications. The results of this test are shown in Table 7 as follows.