{
  "version": 2,
  "name": "Traffic Light Drum Sequencer",
  "exported": "2026-10-14T00:00:00.000Z",
  "notes": "v1.126 example for the Traffic Light Intersection scene (Y1-Y6 as that scene uses them). X3 = Run enable switch (maintained, ON = run). X4 = Reset PB (N.O.). One DRUM drives all six lights: D1 = step register (1-6), Y1 NS green, Y2 NS yellow, Y3 NS red, Y4 EW green, Y5 EW yellow, Y6 EW red. Steps: 1 NS green 5 s, 2 NS yellow 2 s, 3 all red 1 s, 4 EW green 5 s, 5 EW yellow 2 s, 6 all red 1 s (16 s cycle). With X3 OFF the drum pauses and the lights hold. X4 returns the drum to step 1 and clears the cycle count. C1 = done bit, ON for one scan each time step 6 ends; D2 = completed cycles (INT).",
  "program": [
    {"id": 1, "rn": 0,
     "comment": "TRAFFIC SEQUENCE — while X3 is ON the drum steps through six timed patterns on Y1-Y6; X4 resets it to step 1; C1 pulses once per cycle",
     "elements": [
       {"id":101,"kind":"contact","type":"XIC","addr":"X3"},
       {"id":102,"kind":"block","type":"DRUM","addr":"D1","out":"Y1","outs":6,"rst":"X4","dn":"C1","pre":0,
        "steps":[
          {"p":33,"t":5000,"ev":""},
          {"p":34,"t":2000,"ev":""},
          {"p":36,"t":1000,"ev":""},
          {"p":12,"t":5000,"ev":""},
          {"p":20,"t":2000,"ev":""},
          {"p":36,"t":1000,"ev":""}
        ]}
     ]},
    {"id": 2, "rn": 1,
     "comment": "CYCLE COUNT — once per completed cycle (P on the done bit C1) add 1 to D2",
     "elements": [
       {"id":103,"kind":"contact","type":"P","addr":"C1"},
       {"id":104,"kind":"block","type":"INC","addr":"D2","dt":"INT","pre":0}
     ]},
    {"id": 3, "rn": 2,
     "comment": "RESET COUNT — X4 clears the cycle count",
     "elements": [
       {"id":105,"kind":"contact","type":"XIC","addr":"X4"},
       {"id":106,"kind":"block","type":"MOV","addr":"D2","src":"0","dt":"INT","pre":0}
     ]}
  ],
  "comments": {
    "X3": "Run Enable Switch",
    "X4": "Reset PB",
    "Y1": "NS Green",
    "Y2": "NS Yellow",
    "Y3": "NS Red",
    "Y4": "EW Green",
    "Y5": "EW Yellow",
    "Y6": "EW Red",
    "C1": "Drum Cycle Done",
    "D1": "Drum Step",
    "D2": "Cycle Count"
  },
  "dregs": {},
  "dfmt": {}
}
