{"id":183424,"date":"2024-09-06T14:23:46","date_gmt":"2024-09-06T14:23:46","guid":{"rendered":"https:\/\/innovationspace.ansys.com\/knowledge\/?post_type=topic&#038;p=183424"},"modified":"2025-04-04T16:23:22","modified_gmt":"2025-04-04T16:23:22","slug":"traffic-light-control-with-scade-guest-article-student-cinvestav","status":"publish","type":"topic","link":"https:\/\/innovationspace.ansys.com\/knowledge\/forums\/topic\/traffic-light-control-with-scade-guest-article-student-cinvestav\/","title":{"rendered":"Traffic Light Control with SCADE (Guest Article &#8211; Student &#8211; Cinvestav)"},"content":{"rendered":"<h3  id=\"GUEST-ARTICLE-STUDENT-TRAFFIC-LIGHT-CONTROL-WITH-SCADE\">Guest Article &#8211; Student &#8211; Traffic Light Control with SCADE<\/h3>\n<p>This article is a guest contribution from <a href=\"https:\/\/www.cinvestav.mx\/\">Cinvestav<\/a>. It was written by a student group as part of Masters-level, semester long <a href=\"https:\/\/www.ansys.com\/academic\/students\/ansys-scade-student\">SCADE academic program<\/a> course.<\/p>\n<p>It explains the design and simulation of a system that controls the traffic light system of a four-way intersection with emergency vehicle priority.<\/p>\n<p>If you are an academic and are interested in teaching an engineering curriculum backed by Ansys tools, please have a look at our <a href=\"https:\/\/www.ansys.com\/academic\/educators\/funded-curriculum\">Ansys Funded Curriculum<\/a> page.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 700px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-banner-3.jpg\" \/><\/p>\n<h3  id=\"SUMMARY\">Summary<\/h3>\n<p>The Intelligent Traffic Light System project addresses the need for improved emergency vehicle response times in urban environments. By utilizing transmitters and receivers to detect the presence of emergency vehicles (e.g., ambulances or patrol cars) in specific lanes, the system dynamically adjusts traffic light timings. Specifically, it prioritizes the passage of emergency vehicles by turning the light green for the lane in which they are present, facilitating their passage through intersections.<\/p>\n<p>This project was developed with the ANSYS SCADE Suite software, and its principal objective is to demonstrate the feasibility and advantages of integrating intelligent traffic management systems to prioritize emergency vehicle access while maintaining efficient overall traffic flow. The system&#8217;s sensors detect emergency vehicles and adjust the light sequence accordingly, ensuring that emergency response times are minimized without disrupting normal traffic operations. Through this adaptive mechanism, the project aims to enhance urban mobility and safety, setting a new standard for intelligent traffic management in modern cities.<\/p>\n<h3  id=\"SYSTEM-DESCRIPTION\">System Description<\/h3>\n<h4  id=\"SYSTEM-INTERFACE\">System Interface<\/h4>\n<p>The system receives the signals of two sensors for each lane; one of them named as <code>beforeSensor<\/code> as it is placed before its corresponding lane Traffic Light, when it is triggered, it means the presence of a new emergency vehicle in that specific Lane. The other sensor is named <code>afterSensor<\/code>, referring to it being placed after its corresponding Traffic Light, when it is triggered, the system takes it as the exit of an emergency vehicle, not necessarily from its own Lane. In exchange, the system delivers the red, green and yellow lights of each Traffic Lane, always having one of those three lights on, but never having more than one green light on at the same time.<\/p>\n<p>Here is a simple diagram that explains the expected placement of traffic lights and sensors in the environment planned for the system:<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-020-sensor-diagram-1.png\" \/><\/p>\n<p>The next image explains the system&#8217;s interface, having already explained its inputs and<\/p>\n<p>outputs:<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-system-ios-1.jpeg\" \/><\/p>\n<h4  id=\"SYSTEM-BEHAVIOR\">System Behavior<\/h4>\n<p>The traffic light system incorporates sensors capable of detecting emergency vehicles and adjusting the traffic signal pattern to ensure that the emergency vehicle&#8217;s lane has priority over the other ones. This system&#8217;s behavior provides a solution for emergency response while preserving the normal operation when no emergency vehicles are detected. Some of the principal functionalities of the Traffic Light Intersection are:<\/p>\n<ul>\n<li>The system shall work on a 4-lane intersection with 4 traffic lights, one for each lane.<\/li>\n<li>The emergency vehicles shall use transmitters that the sensors placed on the street can detect.<\/li>\n<li>The system shall use sensors placed before and after the traffic lights to detect the presence of emergency vehicles in dedicated lanes.<\/li>\n<li>The system shall detect the presence of an emergency vehicle when it triggers a sensor placed before the traffic light.<\/li>\n<li>The system shall consider that an emergency vehicle has passed when it triggers a sensor placed after a traffic light.<\/li>\n<li>The system shall prioritize the passage of emergency vehicles by turning green the traffic light when these vehicles are present.<\/li>\n<\/ul>\n<h4  id=\"ARCHITECTURE\">Architecture<\/h4>\n<p>The system is designed with several interconnected blocks. Each block performs a critical role in controlling and coordinating the traffic lights, ensuring efficient traffic flow and appropriately prioritizing emergency vehicles. Internal communication between these blocks is critical in determining the current status of each traffic light and dynamically adjusting it according to traffic conditions and signals received from emergency vehicles.<\/p>\n<p>The system architecture diagram shows how these blocks interact with each other to manage emergency vehicle detection, prioritization and synchronization of traffic light changes.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-architecture-diagram-1.jpeg\" \/><\/p>\n<p>Below is a diagram illustrating the existing components of the system and the relationships between their inputs and outputs. This diagram provides a clear view of how each block within the system interacts with the others, showing the necessary connections and data flows for its operation.<\/p>\n<p>Each block in the diagram represents an essential part of the system, and their interactions reflect the logical sequence of operations that allow the prioritization of emergency vehicles in the intelligent traffic light system. By understanding these relationships, one can better grasp the overall design of the system and the mechanisms that ensure its efficiency and effectiveness.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-component-diagram.jpeg\" \/><\/p>\n<h3  id=\"SOFTWARE-REQUIREMENTS\">Software Requirements<\/h3>\n<p>There are twenty Software Requirements, which have been categorized in the functions the software will have to fulfill under different circumstances. These categories are:<\/p>\n<ul>\n<li>Standard behavior: This section of requirements describes the normal state of the system in which no emergency is present, it details the behavior of each traffic light independently by using states.<\/li>\n<li>Single emergency behavior: This section of requirements describes the system when only one emergency is currently occurring, so the lane of this emergency must be prioritized.<\/li>\n<li>Multiple emergencies behavior: This section of requirements describes the behavior of the system when there are two or more emergency vehicles at the same time in different lanes, these emergencies are attended in order of their arrival, because these lanes must be vacated as quickly as possible, the time limit to pass is not as long as when there is only one emergency.<\/li>\n<li>Emergencies Attended: This section of requirements describes the process that is carried out when an emergency has finished: it can be either because an ambulance has already left a lane or the time limit for it to pass has elapsed.<\/li>\n<\/ul>\n<p>Once the software requirement categories are specified, some examples of the requirements of each of them will be listed:<\/p>\n<p><strong>Standard behavior<\/strong><\/p>\n<p>REQ TL_SB_01: When it&#8217;s booted for the first time, the system shall display red at the four traffic lights by default.<\/p>\n<p>REQ TL_SB_03: While one of the traffic lights is on green or yellow light, the rest of the traffic lights shall maintain a red light until commanded.<\/p>\n<p>REQ TL_SB_08: When there are no current emergencies and the system detects one emergency vehicle incoming, the traffic light that&#8217;s currently on green light shall change immediately to a yellow light and after 5 seconds it shall turn into a red one.<\/p>\n<p><strong>Single emergency behavior<\/strong><\/p>\n<p>REQ TL_SEB_01: The system shall be able to detect in which lane an input sensor has been activated by an emergency vehicle.<\/p>\n<p>REQ TL_SEB_03: The system shall be able to detect an emergency vehicle only once, even if the vehicle stays in front of the sensor for a long period of time.<\/p>\n<p>REQ TL_SEB_04: When there are no current emergencies and the system detects one emergency vehicle, the system shall focus on setting the emergency lane into a green light.<\/p>\n<p>REQ TL_SEB_05: While there is one current emergency, the time of each green light of all traffic lights shall be 80 seconds.<\/p>\n<p><strong>Multiple emergencies behavior<\/strong><\/p>\n<p>REQ TL_MEB_01: The system shall register the lanes where there&#8217;s been an unattended emergency.<\/p>\n<p>REQ TL_MEB_02: While there is more than one emergency, the time of each green light of all traffic lights shall be 60 seconds.<\/p>\n<p><strong>Emergencies attended elements<\/strong><\/p>\n<p>REQ TL_EA_01: When a post-signal emergency vehicle is received and there are multiple emergencies, the traffic light currently in green shall change to yellow and then to red. REQ TL_EA_02: When a post-signal emergency vehicle is received and there are multiple emergencies, the system shall focus on the next emergency to attend and set the corresponding lane into a green light.<\/p>\n<p>REQ TL_EA_03: When the time limit for emergency vehicles has elapsed and there are multiple emergencies, the system shall focus on the next emergency to attend and set the corresponding lane into a green light.<\/p>\n<h3  id=\"SOFTWARE-MODEL-DESCRIPTION\">Software Model Description<\/h3>\n<p>The next part of the article will describe in detail which operators were used to provide a solution compliant of the project&#8217;s system and software requirements.<\/p>\n<h4  id=\"CONSTANTS-AND-DATA-TYPES\">Constants and Data Types<\/h4>\n<p><strong>DATA TYPES<\/strong><\/p>\n<p>SCADE Suite&#8217;s data types can be broadly divided between two kinds: predefined and user defined.<\/p>\n<p>The following table depicts the Traffic Light System user-defined data types:<\/p>\n<table>\n<tbody>\n<tr>\n<td><strong>Type<\/strong><\/td>\n<td><strong>Definition<\/strong><\/td>\n<td><strong>Enum Values<\/strong><\/td>\n<\/tr>\n<tr>\n<td><strong>EmergencyState<\/strong><\/td>\n<td><code>enum<\/code><\/td>\n<td><code>[NORMAL, SINGLE_EMERGENCY, MULTIPLE_EMERGENCIES]<\/code><\/td>\n<\/tr>\n<tr>\n<td><strong>LaneNumber<\/strong><\/td>\n<td><code>enum<\/code><\/td>\n<td><code>[LANE1, LANE2, LANE3, LANE4, NONE]<\/code><\/td>\n<\/tr>\n<tr>\n<td><strong>LightType<\/strong><\/td>\n<td><code>enum<\/code><\/td>\n<td><code>[RED, YELLOW, GREEN]<\/code><\/td>\n<\/tr>\n<tr>\n<td><strong>Emergencies<\/strong><\/td>\n<td><code>LaneNumber^4 (array)<\/code><\/td>\n<td><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><strong>CONSTANTS<\/strong><\/p>\n<p>Constant values that will be consistently used within a system are documented in this section, as depicted in the following Table.<\/p>\n<table>\n<tbody>\n<tr>\n<td><strong>Name<\/strong><\/td>\n<td><strong>Data Type<\/strong><\/td>\n<td><strong>Value<\/strong><\/td>\n<\/tr>\n<tr>\n<td><strong>FREQUENCY<\/strong><\/td>\n<td><code>int64<\/code><\/td>\n<td><code>50000000<\/code><\/td>\n<\/tr>\n<tr>\n<td><strong>GREEN_LIGHT_DEF<\/strong><\/td>\n<td><code>int64<\/code><\/td>\n<td><code>10<\/code><\/td>\n<\/tr>\n<tr>\n<td><strong>SENSOR_MIN<\/strong><\/td>\n<td><code>float32<\/code><\/td>\n<td><code>3.5<\/code><\/td>\n<\/tr>\n<tr>\n<td><strong>TIME_LIMIT_MULTIPLE<\/strong><\/td>\n<td><code>int64<\/code><\/td>\n<td><code>10<\/code><\/td>\n<\/tr>\n<tr>\n<td><strong>TIME_LIMIT_SINGLE<\/strong><\/td>\n<td><code>int64<\/code><\/td>\n<td><code>15<\/code><\/td>\n<\/tr>\n<tr>\n<td><strong>YELLOW_LIGHT_DEF<\/strong><\/td>\n<td><code>int64<\/code><\/td>\n<td><code>5<\/code><\/td>\n<\/tr>\n<tr>\n<td><strong>EMPTY_EMERGENCY<\/strong><\/td>\n<td><code>Emergencies<\/code><\/td>\n<td><code>[NONE, NONE, NONE, NONE]<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4  id=\"SOFTWARE-MODEL-OPERATORS\">Software Model Operators<\/h4>\n<p><strong>CALL GRAPH<\/strong><\/p>\n<p>The tree of the model operators is shown in the call diagram below, the operator<\/p>\n<p>&#8220;TopIntersection&#8221; is the root operator.<\/p>\n<p>1. TrafficLight<br \/>\n1.1 TopIntersection<br \/>\n1.2 BasicBlocks<\/p>\n<p>1.2.1 Counter<br \/>\n1.2.2 EdgeDetector<\/p>\n<p>1.3 INOUT_Handler<\/p>\n<p>1.3.1 InputRegulator<br \/>\n1.3.2 OutputHandler<br \/>\n1.3.3 StateToRGB<\/p>\n<p>1.4 Emergency_Handler<\/p>\n<p>1.4.1 DetectEmergencies<br \/>\n1.4.2 EmergencyVehicleDetector<br \/>\n1.4.3 WhichLane<\/p>\n<p>1.5 EmergenciesList_Handler<\/p>\n<p>1.5.1 AddToListEmergencies<br \/>\n1.5.2 AttendNextEmergency<br \/>\n1.5.3 DeleteFromListEmergencies<br \/>\n1.5.4 EmergencyListHandler<br \/>\n1.5.5 EmergecyStateCalculator<\/p>\n<p>1.6 TrafficLights_Handler<\/p>\n<p>1.6.1 SM_TrafficLightState<br \/>\n1.6.2 TrafficLightHandler<\/p>\n<p>1.7 Intersection_Controller<\/p>\n<p>1.7.1 IntersectionController<br \/>\n1.7.2 SM_TrafficState<\/p>\n<p><strong>TOP INTERSECTION OPERATOR<\/strong><\/p>\n<p>This operator is the interface of the system, in other words, it contains its inputs and outputs, which have been already explained earlier.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-top-intersection.png\" \/><\/p>\n<p><strong>INTERSECTION CONTROLLER OPERATOR<\/strong><\/p>\n<p>This module connects the system&#8217;s principal operators, its main function is to integrate the different<\/p>\n<p>modules to ensure that they work together effectively.<\/p>\n<p><em>DetectEmergencies <\/em>receives the outside sensors and delivers the flags that denote when and from which lane an emergency vehicle has been detected. <em>EmergenciesListHandler <\/em>updates the list of emergencies unattended whenever an emergency vehicle has been detected entering or exiting the intersection.<\/p>\n<p><em>SM_TrafficState <\/em>and <em>TrafficLightsHandler <\/em>work in a symbiotic, reciprocating way. The first one is a state machine that receives the current state of the traffic lights and sends the signals in charge of changing them, the second one receives these signals and acts correspondingly, sending back the current state of the traffic lights. These states are also sent outside of the system by <em>OutputHandler<\/em>.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 300px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-intersection-controller-operator-1.png\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 300px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-intersection-controller-operator-2.png\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 300px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-intersection-controller-operator-3.png\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 300px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-intersection-controller-operator-4.png\" \/><\/p>\n<p><strong>SM_TRAFFIC STATE OPERATOR<\/strong><\/p>\n<p>All traffic lights need a signal to know when to change from red to green or green to red, so this module controls when these signals are activated, this module is necessary to synchronize all the lights and make sure that each change is executed correctly.<\/p>\n<p>This module has a state machine with 4 main states <em>LightLane1<\/em>, <em>LightLane2<\/em>, <em>LightLane3 <\/em>and <em>LightLane4<\/em>, a transition state <em>Emergency<\/em>_<em>Lane <\/em>and a state that sets every light to red in special cases.<\/p>\n<p>Every main state represents one of the four traffic lights, inside of every state, its own signal to go to green is activated and the signals of the other traffic lights are deactivated, also the signals to go to red of every traffic light is deactivated, this is for be prepared to activate these signals in other states.<\/p>\n<p>The normal behavior of the system is a cyclic clockwise order, this means that every traffic light has a turn to be green and only changes to the next traffic light when the current traffic light has just changed to red.<\/p>\n<p>When an emergency is detected, the system uses the transition state, this state is a connection between all states and set every light to red before entering to any other state, and similar to this transition state, every main state has a state that sets their own light to red, and continues only when all the lights are red.<\/p>\n<p>This module has an array that contains the list of emergencies and a signal that indicates when a new emergency has been detected.<\/p>\n<p>This module has an output that indicates the current state of each traffic light, it can be RED, YELLOW or GREEN.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-sm-traffic-state-1.png\" \/><\/p>\n<p><strong>TRAFFIC LIGHT HANDLER OPERATOR<\/strong><\/p>\n<p>This module controls the inputs and outputs of the state machine of each traffic light, it has all the inputs that every traffic light needs, the signal <em>goGreen <\/em>to set the green light, the signal <em>goRed <\/em>to set the red light and the <em>emergencyState <\/em>signal that indicates if there is a current emergency in the system.<\/p>\n<p>Also, it has every state of all the traffic lights as a output and a signal that indicates if a traffic light green time limit has elapsed to delete an emergency in that case by the output <em>deleteEmergency<\/em>.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-traffic-light-handler.png\" \/><\/p>\n<p><strong>STATE MACHINE TRAFFIC LIGHT OPERATOR<\/strong><\/p>\n<p>This module controls the state of one traffic light, it contains a state machine with red, yellow and green states. The initial and main state is the Red state, it only goes to green state when it is indicated with the <em>goGreen <\/em>input signal, it stays in that state for a period of time set by the current state of the system using the <em>emergencyState <\/em>input, if there is an emergency, the time in green will be longer, if there is more than one emergency, the time in green returns to normal, the green state can be interrupted by the input signal <em>goRed<\/em>, is important to specify that before set the traffic light to red, it is set to yellow first. The traffic light is going to turn red again after a period set by the constant <em>YELLOW<\/em>_<em>LIGHT<\/em>_<em>DEF<\/em>. Also, this module can send a signal when the green time has done using the <em>emergencyGreenDone <\/em>output.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 200px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-sm-traffic-light-1.png\" \/><\/p>\n<p><strong>EMERGENCY STATE CALCULATOR OPERATOR<\/strong><\/p>\n<p>This module performs the task of determining the state of the system, the system can be in three states, <em>NORMAL<\/em>, <em>SINGLE<\/em>_<em>EMERGENCY <\/em>and <em>MULTIPLE<\/em>_<em>EMERGENCIES<\/em>, this is especially useful for determining the green light time period at any time.<\/p>\n<p>The module has the list of emergencies as an input, if the firs element is empty, the current state is NORMAL, if the first element is not empty, the current state is SINGLE_EMERGENCY, and if the first and second element are not empty, the current state is MULTIPLE_EMERGENCIES.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-emergency-state-calculator.png\" \/><\/p>\n<p><strong>ATTEND NEXT EMERGENCY OPERATOR<\/strong><\/p>\n<p>This module has the function of signaling when the system must focus on the next emergency to be attended. This flag can be raised either when there were no emergencies and one has just appeared, or when there are multiple emergencies, and one has already been handled, leaving room for the system to focus on the next one.<\/p>\n<p>The module receives the list of emergencies, analyses the current and last number of emergencies in the system and sets a flag to <em>true <\/em>when one of the cases already mentioned happens.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-attend-next-emergency.png\" \/><\/p>\n<p><strong>EMERGENCY LIST HANDLER OPERATOR<\/strong><\/p>\n<p>This module has the function to manipulate the system&#8217;s list of emergencies, adding or erasing one as received signals command it. It receives the boolean inputs <em>emergencySignal<\/em>, <em>mustEraseEmergency <\/em>and <em>emergencyDoneSignal. <\/em>If the first one has a <em>true <\/em>value, the module will enable <em>AddToListEmergencies <\/em>and add the value of <em>emergencyLane <\/em>at the end of the List. If <em>mustEraseEmergency <\/em>or <em>emergencyDoneSignal <\/em>are true, the module will enable DeleteFromListEmergencies allowing the list to erase its first element and roll the other ones.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-emergency-list-handler-1.png\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-emergency-list-handler-2.png\" \/><\/p>\n<p><strong>DELETE FROM LIST EMERGENCIES OPERATOR<\/strong><\/p>\n<p>This module, whenever it is enabled, has the function to delete the first emergency from the emergencies list. It receives the list and takes only its last three elements, adding a new one with the value of <em>NONE <\/em>at the end of it. Simulating the behavior of a FIFO list.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 300px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-delete-emergency.png\" \/><\/p>\n<p><strong>ADD TO LIST EMERGENCIES OPERATOR<\/strong><\/p>\n<p>This module has the function of registering the next emergency that is detected, it will save the line in which the emergency occurs knowing where it was saved in order of how the emergencies are arriving.<\/p>\n<p>It imitates a FIFO list behavior so the system can always access the first element to attend the next emergency or check if there are any emergencies at the moment.<\/p>\n<p>This module has the current list of emergencies as an input and a data type<\/p>\n<p><em>emergencyLane<\/em>, that indicates the line where the emergency was detected.<\/p>\n<p>The module has an array output that indicates the new list of emergencies with the last emergency detected added.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-add-emergency-1.png\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 200px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-add-emergency-2.png\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 200px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-add-emergency-3.png\" \/><\/p>\n<p><strong>DETECT EMERGENCIES OPERATOR<\/strong><\/p>\n<p>This module uses the <em>EmergencyVehicleDetector <\/em>block to constantly monitor all sensors, and when a signal is detected from some of them, an <em>emergencySignal <\/em>or <em>emergencyDoneSignal <\/em>is sent to warn that an emergency was detected, also the module sends on which line it was detected a vehicle on the sensor before the traffic light using the <em>emergencyLane <\/em>output.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 200px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-detect-emergencies-1.png\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 200px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-detect-emergencies-2.png\" \/><\/p>\n<p><strong>EMERGENCY VEHICLE DETECTOR OPERATOR<\/strong><\/p>\n<p>This module has four inputs that represents four sensors, the input of every sensor is modulated to have a boolean response instead a voltage level using the <em>inputRegulator <\/em>block, if there is any change detected, the module sends an output signal Alert and a data indicating the lane in which the emergency was detected.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 300px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-emergency-vehicle-detector.png\" \/><\/p>\n<p><strong>WHICH LANE OPERATOR<\/strong><\/p>\n<p>This module receives four boolean signals and sends a data type <em>LaneNumber <\/em>to indicate which of the four signals is activated.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-which-lane.png\" \/><\/p>\n<p><strong>INPUT REGULATOR OPERATOR<\/strong><\/p>\n<p>This module receives a data that represents a voltage level and if the input is less than the constant <em>SENSOR_MIN<\/em>, the output is false by the other hand if the input is bigger or equal than the constant, the output is true, so the module can set a range of detection for each sensor.<\/p>\n<p><strong>STATE TO RGB OPERATOR<\/strong><\/p>\n<p>The entire system has an independent state for each traffic light, so this block translates these states to its respective boolean value, because each traffic light needs three boolean values for the three lights red, yellow and green.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-state-to-rgb.png\" \/><\/p>\n<p><strong>OUTPUT HANDLER OPERATOR<\/strong><\/p>\n<p>This module has the function to use four instances of <em>StateToRGB<\/em>, one for each Traffic Light, to convert the system type <em>LighState <\/em>to three booleans that indicate the whether the green, red and yellow lights of each Traffic Light must be on or off.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 200px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-output-handler-1.png\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 200px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-output-handler-2.png\" \/><\/p>\n<p><strong>COUNTER OPERATOR<\/strong><\/p>\n<p>This operator is a counter used to wait for the time required for a traffic light to stay on green light and yellow light.<\/p>\n<p>It has a Limit input where you enter the cycles to count, a reset input where you enter when you want to restart the counter and an output with the result of the count.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 300px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-counter.png\" \/><\/p>\n<p><strong>EDGE DETECTOR OPERATOR<\/strong><\/p>\n<p>This operator detects a rising edge on an input signal, resulting in a signal that lasts only one clock cycle, and is used for various system processes such as vehicle detection.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-op-edge-detector.png\" \/><\/p>\n<h3  id=\"VERIFICATION\">Verification<\/h3>\n<p>A critical part of the project development is to do the verification (testing and coverage) of the software. The following are two examples of the tests that were created to verify the system&#8217;s correct behavior.<\/p>\n<p><!-- HTML generated using hilite.me --><\/p>\n<div style=\"background: none;overflow: auto;width: auto;border: none;padding: .2em .6em\">\n<pre style=\"margin: 0;line-height: 125%\"><span style=\"color: #999999;font-weight: bold\">#<\/span><span style=\"color: #999988;font-style: italic\">\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># Test Case Reference :<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># TL_TEST_IB_06<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#Test case Objectives :<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># Verify the system is able to detect emergency only once even if the emergency vehicle Stays<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#  on the sensor.<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#Covered Requirements :<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># TL_SEB_03<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#Test Case Acceptance Criteria :<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># check the green light of a lane when sensorBeforeLane is 5.0 and it shall be green only the<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#  specified time.<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#Test case Description :<\/span>\r\nSSM<span style=\"font-weight: bold\">::<\/span>set TopIntersection<span style=\"font-weight: bold\">\/<\/span>sensorBeforeLane4 <span style=\"color: #009999\">5.0<\/span>\r\nSSM<span style=\"font-weight: bold\">::<\/span>cycle <span style=\"color: #009999\">15<\/span>\r\nSSM<span style=\"font-weight: bold\">::<\/span>check TopIntersection<span style=\"font-weight: bold\">\/<\/span>greenLightLane4 <span style=\"color: #999999\">true<\/span> sustain<span style=\"font-weight: bold\">=<\/span><span style=\"color: #009999\">1<\/span>\r\nSSM<span style=\"font-weight: bold\">::<\/span>set TopIntersection<span style=\"font-weight: bold\">\/<\/span>sensorBeforeLane4 <span style=\"color: #009999\">0.0<\/span>\r\nSSM<span style=\"font-weight: bold\">::<\/span>cycle <span style=\"color: #009999\">15<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#--------------------------------------------------------<\/span>\r\n<\/pre>\n<\/div>\n<p><!-- HTML generated using hilite.me --><\/p>\n<div style=\"background: none;overflow: auto;width: auto;border: none;padding: .2em .6em\">\n<pre style=\"margin: 0;line-height: 125%\"><span style=\"color: #999999;font-weight: bold\">#<\/span><span style=\"color: #999988;font-style: italic\">\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># Test Case Reference:<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># TL_TEST_IB_01<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#Test Case Objectives :<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># Verify that when the system is booted, the four traffic lights are in red.<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#Covered Requirements :<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># TL_SB_01<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#Test Case Acceptance Criteria :<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># Check the four lights redLightLane1, redLightLane2, redLightLane3 and redLightLane4, these<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#   signals shall be true.<\/span>\r\n<span style=\"color: #999999;font-weight: bold\"># Test Case Description :<\/span>\r\nSSM<span style=\"font-weight: bold\">::<\/span>check TopIntersection<span style=\"font-weight: bold\">\/<\/span>redLightLane1   <span style=\"color: #999999\">true<\/span>\r\nSSM<span style=\"font-weight: bold\">::<\/span>check TopIntersection<span style=\"font-weight: bold\">\/<\/span>redLightLane2   <span style=\"color: #999999\">true<\/span>\r\nSSM<span style=\"font-weight: bold\">::<\/span>check TopIntersection<span style=\"font-weight: bold\">\/<\/span>redLightLane3   <span style=\"color: #999999\">true<\/span>\r\nSSM<span style=\"font-weight: bold\">::<\/span>check TopIntersection<span style=\"font-weight: bold\">\/<\/span>redLightLane4   <span style=\"color: #999999\">true<\/span>\r\nSSM<span style=\"font-weight: bold\">::<\/span>cycle <span style=\"color: #009999\">5<\/span>\r\n<span style=\"color: #999999;font-weight: bold\">#--------------------------------------------------------<\/span>\r\n<\/pre>\n<\/div>\n<p>Once all the tests corresponding to the software requirements have been done, it is mandatory to execute them to know if the model of software fulfills its expected functions. After passing the tests, making the model coverage is the next step.<\/p>\n<p>As can be seen in the next images, the software model passed all the tests, and the tests have a coverage of 100%<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 300px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-test-results.png\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 300px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-model-coverage-results.png\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 200px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-model-coverage-report.jpeg\" \/><\/p>\n<h3  id=\"IMPLEMENTATION\">Implementation<\/h3>\n<p>Implementation can take two different forms, whether via simulation or via physical application.<\/p>\n<p>The first one can be executed with a control panel built in the tool SCADE Rapid Prototyper. The simulation shows the four Traffic Lights of the intersection and their behavior both under normal and urgent circumstances. The operator can use the switch at the right of the panel to emulate the presence of an incoming emergency vehicle by putting one of the <em>Before levers <\/em>in an ON state. Similarly, the operator can simulate the exit of an emergency vehicle by putting one of the <em>After <\/em>levers in an ON state.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-rapid-prototyper-panel.jpeg\" \/><\/p>\n<p>There are some scenarios implemented in simulation using the panel to show some functionalities, the scenarios that are shown below are tests shown later in the article.<\/p>\n<p>Scenario 1:<\/p>\n<p><strong>Test ID: TL_TEST_SEB_03<\/strong><\/p>\n<p>When an emergency is detected, the system shall set the current green light into a red light and set green the traffic light of the corresponding lane of the emergency.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-tl-test-seb-03-before.png\" \/><\/p>\n<p>After 15 cycles is set green light of the lane 4:<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-tl-test-seb-03-after.png\" \/><\/p>\n<p><strong>Test ID: TL_TEST_IB_01<\/strong><\/p>\n<p>When the system starts, all traffic lights shall be red.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-tl-test-ib-01.png\" \/><\/p>\n<p><strong>Test ID: TL_TEST_MET_01<\/strong><\/p>\n<p>When two or more emergencies are detected, the system shall attend these emergencies in order they arrive.<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-tl-test-met-01-before.png\" \/><\/p>\n<p>After 10 cycles is set green light of the lane 3:<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-tl-test-met-01-after.png\" \/><\/p>\n<p>After 10 cycles is set green light of the lane 1:<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-tl-test-met-01-even-later.png\" \/><\/p>\n<p>The second kind of demonstration is the physical implementation. This one entails the use of different components, that will be listed below:<\/p>\n<ul>\n<li>Arduino Mega 2560.<\/li>\n<li>4 mini-Traffic Light GYR modules.<\/li>\n<li>8 receiver phototransistors.<\/li>\n<li>4 infrared diodes.<\/li>\n<li>4 battery holders type AA.<\/li>\n<li>A Model of a four-way street.<\/li>\n<\/ul>\n<p>In the next images, the physical implementation can be seen:<\/p>\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-physical-demo-one.jpeg\" \/><br \/>\n<img decoding=\"async\" style=\"max-height: 500px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-physical-demo-two.jpeg\" \/><\/p>\n<h3  id=\"RESULTS\">Results<\/h3>\n<p>The intelligent traffic light system demonstrated its capability to enhance emergency vehicle response times in urban settings. By utilizing transmitters and receivers to detect emergency vehicles in specific lanes, the system dynamically adjusted traffic light timings, prioritizing green light extensions for lanes with detected emergencies.<\/p>\n<p>This adaptive approach significantly improved the efficiency of emergency vehicle passage through intersections, potentially leading to faster response times and enhanced safety outcomes. The project highlighted the feasibility and advantages of integrating intelligent traffic management systems in urban environments, aiming to establish a new standard in urban mobility and safety by effectively balancing emergency vehicle prioritization with maintaining efficient traffic flow.<\/p>\n<h3  id=\"FEEDBACK-SUMMARY-ABOUT-MBD-SCADE\">Feedback summary about MBD &amp; SCADE<\/h3>\n<p>MBD (Model-Based Design) and SCADE are powerful tools for developing embedded systems. They streamline the design process by allowing for detailed modeling and simulation before physical prototyping. This approach helps catch potential issues early and improves overall system reliability. The structured nature of MBD and the capabilities of SCADE have made project development more efficient and collaborative, especially in complex applications.<\/p>\n<p>SCADE, particularly, offers specialized tools and environments specifically designed for safety-critical applications, such as aerospace, automotive, and industrial control systems. Its graphical modeling capabilities and automatic code generation features not only streamline the design process but also ensure compliance with safety standards and regulations.<\/p>\n<h3  id=\"ABOUT-THE-AUTHORS\">About the authors<\/h3>\n<table style=\"border: none !important\">\n<tbody>\n<tr>\n<td style=\"border: none !important\">\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 200px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-author-patricio-1.png\" \/><\/p>\n<\/td>\n<td style=\"border: none !important\">Patricio Emiliano Morales Diaz Patricio Emiliano Morales Diaz, graduated as a technologist in software development from Centro de Ense\u00f1anza T\u00e9cnica Industrial (CETI), Mexico in 2022. He is currently studying engineering in robotics at the Centro Universitario de Ciencias Exactas e Ingenier\u00edas (CUCEI). His interests include software development and programming, studies in embedded systems and the application of emerging technologies in innovative projects.<\/td>\n<\/tr>\n<tr>\n<td style=\"border: none !important\">\n<p style=\"text-align: center\"><img decoding=\"async\" style=\"max-height: 200px !important\" src=\"https:\/\/innovationspace.ansys.com\/knowledge\/wp-content\/uploads\/sites\/4\/2024\/09\/scade-022-author-mariana-1.png\" \/><\/p>\n<\/td>\n<td style=\"border: none !important\">Mariana Corona Aldana received the title of technologist in software development from Centro de Ense\u00f1anza Tecnica Industrial (CETI), M\u00e9xico, in 2022. She is currently studying to get a degree in Robotics from Centro Universitario de Ciencias Exactas e Ingenier\u00edas (CUCEI). Her interests include development of both software and embedded software.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n","protected":false},"template":"","class_list":["post-183424","topic","type-topic","status-publish","hentry","topic-tag-cinvestav","topic-tag-guest-article","topic-tag-scade","topic-tag-scade-rapid-prototyper","topic-tag-scade-suite","topic-tag-scade-test","topic-tag-student"],"aioseo_notices":[],"acf":[],"custom_fields":[{"0":{"_edit_lock":["1743783672:1769"],"_edit_last":["1769"],"filter_by_optics_product":["Lumerical"],"_filter_by_optics_product":["field_64fb192ba3121"],"application_name":[""],"_application_name":["field_64a80903c8e15"],"family":[""],"_family":["field_64a809229a857"],"siebel_km_number":[""],"_siebel_km_number":["field_63ecbffce60db"],"salesforce_km_number":[""],"_salesforce_km_number":["field_63ecc018e60dc"],"km_published_date":[""],"_km_published_date":["field_64c77704499dd"],"product_version":[""],"_product_version":["field_64c776cb4fd2e"],"_bbp_forum_id":["27825"],"_bbp_topic_id":["196481"],"_bbp_author_ip":["194.98.52.82"],"_bbp_last_reply_id":["0"],"_bbp_last_active_id":["183426"],"_bbp_last_active_time":["2024-09-06 14:23:46"],"_bbp_reply_count":["0"],"_bbp_reply_count_hidden":["0"],"_bbp_voice_count":["0"],"_yoast_wpseo_content_score":["30"],"_yoast_wpseo_estimated-reading-time-minutes":["26"],"_btv_view_count":["1415"],"_bbp_likes_count":["5"],"_aioseo_title":[null],"_aioseo_description":[null],"_aioseo_keywords":["a:0:{}"],"_aioseo_og_title":[null],"_aioseo_og_description":[null],"_aioseo_og_article_section":[""],"_aioseo_og_article_tags":["a:0:{}"],"_aioseo_twitter_title":[null],"_aioseo_twitter_description":[null]},"test":"solution"}],"_links":{"self":[{"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/topics\/183424","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/topics"}],"about":[{"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":7,"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/topics\/183424\/revisions"}],"predecessor-version":[{"id":196481,"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/topics\/183424\/revisions\/196481"}],"wp:attachment":[{"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/media?parent=183424"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}