Circuits Thread

    NeonSturm

    StormMaker
    Joined
    Dec 31, 2013
    Messages
    5,110
    Reaction score
    617
    • Wired for Logic
    • Thinking Positive
    • Legacy Citizen 5
    Code:
    actMod1 | actMod2 | actMod3
    notAM1 | notAM2 | notAM3
    
    actMod# -> notAM#
    
    notAM1 -> actMod2
    notAM2 -> actMod1, actMod3
    notAM3 -> actMod2
    -- neighbours
    
    => Everything can toggle everything

    ------


    Damage Control Grid:
    1. Clock:
      1. delay -> not
      2. not -> delay
    2. Signal:
      1. delay -> equal[for gridN]
      2. not -> actStart[gridN] -> actNext[gridN] -> ... -> actEnd[gridN] -> equal[for gridN]
      3. for each gridN
        1. equal -> act : "One sec memory for on" + or
        2. act : "One sec memory for on" -> or
        3. or -> red light "This section is damaged!"
    3. Equal module:
      1. WIP
    4. Memory module:
      1. WIP
    5. Displaying damage:
      1. "holographic room" with a cockpit pointing on a holographic table/wall
      2. A miniature-ship (1 block per 32^3 or 64^3 blocks?) to display damage
        • can be split into bot-top and top-bot view - or similar
      3. This miniature ship has red lights
        • On = section damaged
    ------

    Reliable Clock (WIP):

    Maybe you know the default Clock: Delay1 -> Not1 -> Delay1

    The problem that occurred in my Damage Control trial was, that both are active for a very short time.
    This bugs my "blink->constant transformer" (act1 -> or1 <-> act2)

    Ironically, with (act1 -> not1 -> act2 -> not2 -> act1) it works as expected.

    ------

    Challenge: RSA with ingame logic

    small = 32 bits
    big = 64 bits
    special = for big*big (%n)

    Step1: encoder/decoder:
    big: source
    big: code​
    special: intermediate result -> intermediate result
    2 values in parallel
    a switch should redirect access (read+write) to value 1 to value 2 in vice versa​

    big n
    needs to use modular on intermediate result.​

    small: e=(about 2^16+1) (used as inverse counter) or d (as counter if you want to hack it, else inverse)
    needs increment and decrement.​

    (e>0; e--) or (d>0; d--) or (d++ and continue hack) => yes -> continue


    The challenge is to create a circuit which can multiply huge numbers and optimize it for a lower result size by including modulo into the multiplication circuit.


    The progress of this project depends on if I found a practicable solution for this challenge.

    ------

    Feel free to continue this thread
     
    Last edited:
    • Like
    Reactions: aceface

    NeonSturm

    StormMaker
    Joined
    Dec 31, 2013
    Messages
    5,110
    Reaction score
    617
    • Wired for Logic
    • Thinking Positive
    • Legacy Citizen 5
    I were designing on some logic system for toilets ;), but you can also use it for bunkers.
    How it works:
    1. Initial: Inside activation block = off/yellow/open; Outside activation block = on/blue/closed
    2. If you want to enter, you deactivate the outer activation block via area triggers and a controller adjacent to just this activation block.
    3. On the inside, you lock the door with the inner activation block (you can still manually toggle the door, but you are not supposed to)
    4. If you turn the lock off, it should always open, independent on if the door was open or closed by the outer.
    5. If you close it by passing the area triggers at the outside of this door, it should close
    Solution:
    • 2 activation modules:
      • act: closed (outside switch) ->
        1. or : locked | closed
        2. and : unlocked & closed
        3. optional not : opened
      • act : locked (inside switch) ->
        1. or : locked | closed
        2. not : unlocked
        3. optional Red Lamp + Display "Is locked/occupied"
    • 2-3 not modules:
      • optional not : opened ->
        1. Green Lamp + Display "Open or needs unlock" (optional)
      • not : unlocked ->
        1. and : unlocked & closed
      • not : break closed ->
        1. act : closed
    • 1 and module:
      • and : unlocked & closed ->
        1. not : break closed
    • 1 or module:
      • or : locked | closed ->
        1. door : closed parts
    • X doors:
      • door : closed parts
     
    Last edited:

    NeonSturm

    StormMaker
    Joined
    Dec 31, 2013
    Messages
    5,110
    Reaction score
    617
    • Wired for Logic
    • Thinking Positive
    • Legacy Citizen 5
    The final Airlock circuit:
    • Airlock setup:
      1. optionally: close trigger connected to actA1 - 1 block between door and the trigger
      2. - open trigger connected to actO1 - 0 blocks between door and the trigger
      3. - outer door
      4. - open trigger connected to actO1
      5. optionally: close trigger connected to actA1
      6. optionally: some distance between doors
      7. optionally: another close trigger connected to actA1
      8. - open trigger connected to actI1
      9. - inner door
      10. - open trigger connected to actI1
      11. optionally: close trigger connected to actA1
    • Logic setup:
        • Forget about the clock part - it belongs to another circuit
        • Each or (x>1 from middle two blocks) means: other state active, this is inactive.
        • Each not (1-x from middle two blocks) means: this state is active
        • one row/line, one state: inner, outer, no door open.
      1. stateAll or(=active) -> (or->outerDoor), (or->innerDoor)
      2. stateOuter not(=inactive) -> outer door (=closed while not active)
      3. with delay: stateInner not(=inactive y|n) -> or, x*delay
        1. x*delay -> or -> inner door (=closed while signal=active =state not active)
    You need:
    • Triggers. doors and walls ;)
    • 3 controllers (only for area triggers)
    • the delay blocks if you want them (0, 2, 4, 6, 8...)
    • ---
    • 4-6 activation
    • 6-8 or
    • 4-5 not
    With the core logic being solved with 14 to 19 blocks, it is the cheapest and a very versatile solution for automatically opening and closing doors
    It does not even require you to press a button, once you have it setup.
     
    Last edited:

    NeonSturm

    StormMaker
    Joined
    Dec 31, 2013
    Messages
    5,110
    Reaction score
    617
    • Wired for Logic
    • Thinking Positive
    • Legacy Citizen 5
    2-Level gravity tube for logic-newbies ;)
    lets you use both sides of a plate like if both sides were different levels and the tube an elevator. This is the first step for building a more complex elevator.

    Untitled.jpg
    stay in the same group:
    trigger 123 -> actA 123 -> orAB 123 -> actB 123 -> orAB 123​
    cross-over:
    actB 1 -> orC 23
    actB 2 -> orC 13
    actB 3 -> orC 12​
    stay in the same group again:
    orC 123 -> actA 123 & actB 123​

    act = activation block.
    A->B = Select A, Connect it to B.
    A = first, B = second block of the same type.
    AB = is between A and B
    C = after B.

    Now, you got only one of actB on at a time => the one which is on indicates the last trigger passed.
    actB will remain on until another trigger is activated.

    Use the actA of your first trigger's group to change the gravity downwards
    Use your third actA to change the gravity upwards

    Use the orC of your second trigger's group to open the door once you left or when you enter the gravity-tube and to close the door after you hit trigger A or B, so that you can not fall to the other side again.
     
    Last edited:
    Joined
    Jun 13, 2014
    Messages
    36
    Reaction score
    13
    OK, this is great, just the sort of thing I have been trying to get to work, but have been unable to get my "logic newbie" head around:confused::confused:.
    Will have a lash at it, but don't be surprised if I come back with questions....:).

    Edit- Like did you use all area triggers or some step ons?
     

    NeonSturm

    StormMaker
    Joined
    Dec 31, 2013
    Messages
    5,110
    Reaction score
    617
    • Wired for Logic
    • Thinking Positive
    • Legacy Citizen 5
    Circuit for "a secure bomb"
    arming with 2 delay

    and a security button
    for the case you accidentally
    hit just one

    Ship core and logic blocks with lights instead of bombs + display blocks explaining it:
    Display1:
    button1, button2 -> and1 -> 4* delay
    and1, delay(all 4)-> and2 -> or1 -> button3 -> or1
    button3 -> red_light "armed"​
    Display2:
    -- arm: make both blue and wait 2 seconds
    -- abort: make one button red before it is armed​
    Display3:
    button3 -> not -> button4 "reset trigger"
    button3, (area trigger -> controller+button4) -> and3 -> white_light "boom"​
     
    Last edited:

    NeonSturm

    StormMaker
    Joined
    Dec 31, 2013
    Messages
    5,110
    Reaction score
    617
    • Wired for Logic
    • Thinking Positive
    • Legacy Citizen 5
    Now I made a Password-protection circuit for ships.

    It has 3 states:
    Change Password (blue)
    Disabled (white)
    Enabled (red)
    And it is easy to get more states.​
    For each state:
    button "change", /shared/ and "password matching" -> and "status change legal" ->
    or -> button "state active" -> /cross-over/ or "others activated" -> not -> (button "change", button "state active")​
    It has for each password-bit:
    button "enter bit" -> and "status blue" -> or -> button1 -> not -> button0
    button "enter bit" -> not -> and "status blue" -> or -> button0 -> not -> button1

    button "enter bit", button1 -> and -> "both 1"
    (button "enter bit" -> not), button0 -> and -> "both 0"

    (both 1), (both 0) -> or -> /shared/ and "password matching"​



    The uploaded file contains:
    a 2-step animation door to the bridge (with just 16 logic blocks around the door + 20 area triggers for proximity-detection)
    a password protection with 5 bits​

    The file is does NOT:
    have decorative elements (though everything is enclosed in yellow hull)
    A link of buttons to the outside of your door
    protecting the door with a password (you can still manually open or close it)​

    I want to update as soon as I finished it (reordered logic to be easier to see + not obstructing core vision + entrance protection via gravity changes)
     

    Attachments