## 5 Design  
The design stage has been defined by the route of the patient from entry to hospital until departure. This is necessary so that all RFID systems can provide data relating to the patient's care attendance in the prescription-validation-preparation/dosage-dispensation-administration process of medication in the Day Hospital. The steps for doctors and patients to follow are as follows:  
* If the doctor prescribes medicine for the first time using the RFID in the Day Hospital protocol, it is necessary for the hospital commission in charge to authorize the administration of the medicine to the patient. * Once authorized, the treatment of the patient can begin with the doctor explaining the procedures with informed consent and once accepted, an Aeroscout active WIFI tag is given to the patient. * The doctor links, in Mobile View, the patient's medical history number with the MAC address of the tag which locates it to subsequently obtain traceability of the patient within the system (see Figure 1). This means that for each administration programmed by the doctor, the whereabouts of the patient can be identified in real time: the arrival and exit from hospital and real-time location of the patient in each of the controlled areas: medication treatment room in the Day hospital, waiting room, cafeteria, etc. * The doctor will, from time to time, program future administrations under the date tag for administrations within the RFID protocol of the Day Hospital (an application which has been developed by the CHUAC Computer Service for the professionals involved) to manage these tasks. * Prior to the arrival of the patient to hospital, the pharmacist will have prepared the instructions for the preparation of the prescribed medicine for that patient in the tag \"Validation\" of the RFID protocol of the Day Hospital. * For each of the programmed administrations, the patient should attend the doctor's surgery to confirm that his/her state of health is suitable for the treatment to be administered and, if it is, the doctor will notify the pharmacy through the tag \"Confirmation of Treatment\" under the RFID protocol of the Day Hospital. * The pharmacy personnel prepares and identifies with precision the intravenous mixture to administer to the patient using the \"Preparation of Medication\" tag in the RFID protocol of the Day Hospital (see Figure 2) and the RFID system for the preparation of medication of the Pharmacy Service. The medicine will then be placed in the RFID transporter cart and by using theRFID system for tracking medication, the location of the medicine can be identified during its transport from the Pharmacy to the Day Hospital. When the cart finally arrives at the Day Hospital, the orderly deposits the medication in the RFID tray to control delivery and, then, the nursing staff will administer the medicine to the patient using the \"RFID system for the administration of medication\". They identify the patient through the patient medical history number (NHC), read the medication tag and by using the mobile application and its series of alerts, confirm that they are going to administer the prescribed medicine to the correct patient in the correct conditions for administration (dose, route, scheduling, infusion rate, expiry date, etc.). The number of patients involved has increased on a weekly basis given that the objective is to include all those patients with medicines prescribed by the day hospital and considered to be of high-risk and elevated cost. The most important incidents that have been detected so far relate to problems reading the bar code of the MAC tag (poor orientation of the reader); errors in the placement of the adhesive of the RFID tags on the intravenous mixtures developed by health personnel. These problems have diminished gradually in line with the learning experience gained by the personnel involved. It is important to note that the system is ready to be easily extended to any other prescribed treatment service at CHUAC.