Saturnus Posted February 19, 2019 Share Posted February 19, 2019 10 minutes ago, Zarquan said: For example, in Saturnus's NAND, he has the wires from the two signal switches link up. If you were to do this in the real world, and the two switches were opposite, it would short circuit. Uhm... no. It's a basic "totem pole" NAND gate. You can build this on a breadboard to test it if you like. Link to comment Share on other sites More sharing options...
KittenIsAGeek Posted February 19, 2019 Share Posted February 19, 2019 14 minutes ago, Zarquan said: Not quite. I was overly-simplifying, yes. Link to comment Share on other sites More sharing options...
Arnadath Posted February 19, 2019 Author Share Posted February 19, 2019 46 minutes ago, Saturnus said: With the knowledge that NAND gates are "perfect" universal gates for our purpose as they're inherently buffered, we can start building circuits using just NAND gates as is most often the case in real life. For example here I've built a XOR gate from 4 NAND gates, ie. 8 NOTs down from 11 as in your example using mixed gates. Both our designs have a problem, and it's the same problem. If you change the input from "00" to "11" there will be a 1 tick of '1' in the output. You can fix the behavioural by making the nor condition happen 1 tick later than the AND condition, with two OR gates in each input. Link to comment Share on other sites More sharing options...
Zarquan Posted February 19, 2019 Share Posted February 19, 2019 12 minutes ago, Saturnus said: Uhm... no. It's a basic "totem pole" NAND gate. You can build this on a breadboard to test it if you like. I typoed, I meant your NOR. But you can do this with NOR too, so I guess I stand partially corrected. However, nobody makes computers completely out of TTL gates anymore, so my point does have some merit. Link to comment Share on other sites More sharing options...
Saturnus Posted February 19, 2019 Share Posted February 19, 2019 25 minutes ago, Arnadath said: Both our designs have a problem, and it's the same problem. If you change the input from "00" to "11" there will be a 1 tick of '1' in the output. You can fix the behavioural by making the nor condition happen 1 tick later than the AND condition, with two OR gates in each input. Not sure but the buffer and filter gates set at 0.1s is one frame delays, right? If so that's an easy fix. That wasn't the point of my post though. It was merely demonstrating that a NAND made of two inverters is good logic building block. Even in ONI. 22 minutes ago, Zarquan said: I typoed, I meant your NOR. But you can do this with NOR too, so I guess I stand partially corrected. However, nobody makes computers completely out of TTL gates anymore, so my point does have some merit. That's why I specifically mentioned the NOR (at it's most basic level) was unbuffered on the inputs and therefore has limited practical use. But you certainly can still do it with just resistors on a breadboard. Link to comment Share on other sites More sharing options...
Arnadath Posted February 19, 2019 Author Share Posted February 19, 2019 53 minutes ago, Saturnus said: Not sure but the buffer and filter gates set at 0.1s is one frame delays, right? If so that's an easy fix. @Saturnus Short answer is no. They are unreliable substitute. A buffer gate for example, will change the output from off to on within one frame after receiving a 'true' in the input, but the transition from on to off, will last one frame, plus a game time check which means randomly 1 or 2 more ticks. Do this experiment in debug mode: Both filter and buffer gate are at 0.1 sec Just flick the switch while unpaused. The mechanism is set so that it skips the initial automation step, and counts how many automation steps takes for the "real time" transition to happen. In slow speed, you'll see the buffer gate will delay transiting randomly for 1 up to 2 steps. In the highest speed, it might take even more than 5 steps. Filter gate also expressses this eratic behaviour but it's only apparent in slow speed. The or gate will always transit at automation step, thus it will never ever change any of the outputs If you are trying to do synchronous automation and you utilize even one of them in your design, your system will always get out of whack pretty quickly. Link to comment Share on other sites More sharing options...
Saturnus Posted February 19, 2019 Share Posted February 19, 2019 11 minutes ago, Arnadath said: @Saturnus Short answer is no. That would have sufficed. An OR or AND gate then as delay? I know then we're technically not exclusively using NOTs but you gotta roll with what you've got. Link to comment Share on other sites More sharing options...
Arnadath Posted February 19, 2019 Author Share Posted February 19, 2019 @Saturnus. Yep. Here is a version of your xor that won't produce this pulse We just confirm for nor condition before we confirm for nxnor condition. Link to comment Share on other sites More sharing options...
Saturnus Posted February 19, 2019 Share Posted February 19, 2019 19 minutes ago, Arnadath said: @Saturnus. Yep. Here is a version of your xor that won't produce this pulse We just confirm for nor condition before we confirm for nxnor condition. I would just have used ANDs as delays without changing anything. Like this: Link to comment Share on other sites More sharing options...
Arnadath Posted February 19, 2019 Author Share Posted February 19, 2019 5 minutes ago, Saturnus said: I would just have used ANDs as delays without changing anything. Like this: Judging by the picture, this will also work because your time critical path is 2 ticks. Link to comment Share on other sites More sharing options...
Gurgel Posted February 19, 2019 Share Posted February 19, 2019 4 hours ago, KittenIsAGeek said: I think its amazing that because of the formal logic arguments developed by the ancient greeks (and other cultures), we can use a simple NOT gate to build pretty much all our technology. ONI, video streaming, cell phones, teh intertubes, whatever. It all boils down to NOT gates. You actually need NOT and AND or OR, or, alternatively, just NAND or NOR. In the real world, you can do wired-AND and wired-OR as well, with the right type of output (open collector or open drain). It is rarely used though as it has really bad switching characteristics. Link to comment Share on other sites More sharing options...
Yunru Posted February 20, 2019 Share Posted February 20, 2019 1 hour ago, Gurgel said: You actually need NOT and AND or OR, or, alternatively, just NAND or NOR. As evident above, you only need NOT and OR. AND is just a product of those. Link to comment Share on other sites More sharing options...
badgamer123 Posted February 21, 2019 Share Posted February 21, 2019 I would like to be a bit of greedy to ask, any idea to create a logic loop that work like door pump but shut off each other first? my problem is I got a very very far end place that only supplying 1kW power (sometime 2kW when other place have power left) I recent want to expansion. I could do the normal shutoff SB switch thing,but I need 3 circuit all running 2KW. Thus I need to connect battery A for 20 second then close then open battery B for 20 second then Close B and open C ,then loop back to A really like to avoid memory gate as it a bit unstable.I put in a door pump logic gate there but it have that 0.1 second of connected more then 1 circuit. Really like to using buffer,not,filter gate as they are more stable without fail Link to comment Share on other sites More sharing options...
Saturnus Posted February 21, 2019 Share Posted February 21, 2019 33 minutes ago, badgamer123 said: Really like to using buffer,not,filter gate as they are more stable without fail This should work. Filters set to 20s each. Link to comment Share on other sites More sharing options...
badgamer123 Posted February 21, 2019 Share Posted February 21, 2019 47 minutes ago, Saturnus said: This should work. Filters set to 20s each. it worked great thx Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.
Please be aware that the content of this thread may be outdated and no longer applicable.