plunker의 simcirjs

3551 단어 SimcirJSPlunker

개요



plunker에서 simcirjs를 시도했습니다.

사진





샘플 코드


{
  "width":800,
  "height":400,
  "showToolbox":true,
  "toolbox":[
    {"type":"In"},
    {"type":"Out"},
    {"type":"Joint"},
    {"type":"DC"},
    {"type":"LED"},
    {"type":"PushOff"},
    {"type":"PushOn"},
    {"type":"Toggle"},
    {"type":"BUF"},
    {"type":"NOT"},
    {"type":"AND"},
    {"type":"NAND"},
    {"type":"OR"},
    {"type":"NOR"},
    {"type":"XOR"},
    {"type":"XNOR"},
    {"type":"OSC"},
    {"type":"7seg"},
    {"type":"16seg"},
    {"type":"4bit7seg"},
    {"type":"RotaryEncoder"},
    {"type":"BusIn"},
    {"type":"BusOut"},
    {"type":"RS-FF"},
    {"type":"JK-FF"},
    {"type":"T-FF"},
    {"type":"D-FF"},
    {"type":"8bitCounter"},
    {"type":"HalfAdder"},
    {"type":"FullAdder"},
    {"type":"4bitAdder"},
    {"type":"2to4BinaryDecoder"},
    {"type":"3to8BinaryDecoder"},
    {"type":"4to16BinaryDecoder"},
    {"type":"AltFullAdder"},
    {"type":"Transmitter"},
    {"type":"Delay"},
    {"type":"NumSrc"},
    {"type":"NumDsp"},
    {"type":"DSO"}
  ],
  "devices":[
    {"type":"DC","id":"dev0","x":96,"y":120,"label":"DC"},
    {"type":"Toggle","id":"dev1","x":160,"y":72,"label":"Toggle","state":{"on":false}},
    {"type":"Toggle","id":"dev2","x":160,"y":152,"label":"Toggle","state":{"on":false}},
    {"type":"LED","id":"dev3","x":216,"y":112,"label":"LED"},
    {"type":"LED","id":"dev4","x":216,"y":208,"label":"LED"},
    {"type":"XOR","id":"dev5","x":312,"y":112,"label":"XOR"},
    {"type":"LED","id":"dev6","x":400,"y":112,"label":"LED"}
  ],
  "connectors":[
    {"from":"dev1.in0","to":"dev0.out0"},
    {"from":"dev2.in0","to":"dev0.out0"},
    {"from":"dev3.in0","to":"dev1.out0"},
    {"from":"dev4.in0","to":"dev2.out0"},
    {"from":"dev5.in0","to":"dev1.out0"},
    {"from":"dev5.in1","to":"dev2.out0"},
    {"from":"dev6.in0","to":"dev5.out0"}
  ]
}

아티팩트



이상.

좋은 웹페이지 즐겨찾기