Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
13.5. Presentation    
27.5. Station-Station Controller + C-Interface
17.6. Integrationstesting
24.6. Defined testcases with stopflag
01.7. Schedules for trains are working

cw 34 Final presentation
cw 35 Excursion to Miniatur Wunderland


Work Current work distribution: 


TaskAssigned Persons
C-IntefaceAlexander
Mutual ExclusionNis
Station-to-StationPersonal assignments
Test ScenariosExpert-groups
DeadlocksCarsten
IntegrationSmall groups, dynamic time schedule


Implementation in short:

The main idea is, that we have a universal model of the track segments. From these single track segments, track sections, that connect train stations are modeled and from those track sections, all final schedules for the trains should be build. On each track segment, there should be at most one train: In order to drive over a track, a train must request this track, and afterwards it must free it again (details below). If two trains request the same track section, the priority, which is derived from the train number, decides, which train gets the track section. A train must request all tracks until the next possibility to stop an wait in order to avoid collisions. If the train does not get all track segments, it must free them again in order to avoid deadlocks or delays of other trains. Deadlocks might occur at the exists of all train stations, and additionally, if one train with a low priority exists the Kicking-Horse-path while another train with a higher priority sends an entry-request. It remains to be seen, if additional deadlocks occur. Deadlocks can be resolved by using a superior Mutex-Controller. 

...

Behaviour modeled in an SCChart (without deadlock prevention):

Station-Station Modules

Input: Zugnummer, Startgleis, Zielgleis, Cleanup, (Mutex Variablen?)
Output: "Echtes" Zielgleis (Ausweichgleis?)

...

The C-Interface wraps some general functions, in order to prevent long and ugly host-code statements within the SCCharts. It especially hides the railway pointer. In addition, the C-Interface provides a persistent environment during a macro step. To bring in some randomness, the time, which a train has to wait in a station, is controlled by the C-Interface. Therefore, trains have to notify the interface about their arrival and their departure

 

Test cases: 

Our Implementation should pass the following simple tests: 

...