All Activity

This stream auto-updates   

  1. Past Hour
  2. Today
  3. Anyone can help me ???
  4. Yesterday
  5. Student advice

    Hey, thank you so much for all your advice and insights, Joe!
  6. Student advice

    I think I understand what you're trying to achieve. Based on what I see, if you see a part that is NOT an assembly, set the bit in the reject array. If it is, don't set the bit. Whether it's an assembly or not is determined solely by the status of IP3. So, if you see an item at IP4 without IP3 being on, set the reject bit. If I'm missing something or misunderstanding, I'm sorry. I have to leave now and will take another look in the morning.
  7. Student advice

    To recap, I need to write code to identify and differentiate between Assembled Items, Pegs, and Rings. And store, the results as bits in a Bit Shift Register. This will be used to Reject (1) or Accept (0) them.
  8. Student advice

    The distance between IP4 and the rejection station can accommodate TWO  of any combination of items. However, so far, the identification method and mechanism designed can cope with a stream of any combination of items.
  9. Student advice

    To recap, I need to write code to identify Assembled Items, Pegs, and Rings. I ONLY want to keep Assembled Items. Pegs and Rings must be rejected via the piston OP3. These are stored in a Bit Shift Register as 1 or 0. A 1 bit triggers the rejection piston. A 0 bit does NOT trigger the rejection pistion. Assembled Item = 0 Peg = 1 Ring = 1
  10. Student advice

    Do you really care about the rings per se? As I understand it, you only care if it's an assembly or not. If it's an assembly (latch/seal for IP3 = 1), don't reject it. Otherwise, track it and reject it. For that purpose, IP8 is redundant. It doesn't give you any information you need, at least to solve this particular problem. However... In my experience, "they" will always want to know more than good/bad; they will want to track why it's bad. To do that, you could set up a tracking array for each defect (2 in this case). Use one array to track pegs (easy, IP4 = 1 while the latch/seal for IP8 = 1) and the other to track rings (harder but not too bad, IP4 = 1 while the latches/seals for IP3 and IP8 are both 0). Then you'd reject if either array has a "1" at the reject position and you could also accumulate a count of each type of reject. Both arrays would shift at the same time. If you get many more defect reasons, you probably won't want to stay with bit shifts but use word shifts, where you have an array of integers. Each integer represents a "position" while each bit within each integer represents a defect cause. Also: will there ever be more than one part between IP4 and the reject station? If so, will the number of parts ever change? If so, you will likely need some sort of FIFO arrangement instead of a bit shift array. That will be a problem for another day...  
  11. Student advice

    In LADSIM: RES is also used to reset Timers, Counters and Register bits. The Latch and Unlatch instruction are used on Outputs and a single bit too! There is no Latch or Unlatch instruction for INPUTS and no 'Seal In' at all!   Do I have to rewrite the code relating to IP3/IP8 and IP4 completely? At the moment: Rung 11 without IP4 - I can detect Assembled Items and Pegs but not rings - and the register works correctly. Rung 11 with IP4 - I can detect Assembled Items and Pegs and Rings - BUT the register increments errors - I suspect because the use of IP4 twice causes a double count to occur. Again, thank you.
  12. Student advice

    Ok... With there being a lag between IP3/IP8 and IP4, that does complicate it somewhat but not unduly...as long as there's a gap between the parts. If there's sufficient gap between the parts, you can use a latch or seal-in to record IP3/IP8 when they come on. Generally, using a seal-in is preferred, but a latch will work. Then, when IP4 comes on, you check the status of the bits that IP3/IP8 set/sealed and make a decision at that point whether or not to set the bit in the shift array. So... In the instant that IP4 comes on...if IP3's latch/seal is OFF, the item is not an assembly, so you reject it. If IP3's latch/seal is ON, the part is an assembly so you don't reject it. In either case, you set the input bit status and shift the register, either when IP4 comes on or when it goes off. After you shift, you then clear the latches/seals from IP3/IP8 and you're ready for the next part. For just this purpose, where you're trying to reject everything except assemblies, you don't need IP8 at all. You just care that something's there (IP4) and it is/isn't an assembly (IP3). It may be useful at a later date to track pegs and rings separately, but that's beyond the scope of what you're asking here. My other question was merely curiosity about why there are two different instructions that appear to do the same thing: write 0 to a bit. In the AB world that I'm used to, the RES instruction is used to reset timers, counters, etc. while the U instruction unlatches a single bit.
  13. Student advice

    Rung 12 - This corrects the assembled items being labelled 1 (rejection). Because IP3 and IP8 operate simultaneously assembled items are ALWAYS labelled 1; so, the 1 has to be changed to 0 to avoid rejection. That is the function of this rung. Rung 14 - This rung just tidies up the register - from location 13 onwards, bits are not required. Rung 15 and 16 - the rejection rungs. An item labelled 1 in location 14 in the register triggers the rejection piston O3. It seems to work.   IP5 = Detects ALL items in the rejection area. OP3 = Rejection pistion. ----R1|  |14-- = When a 1 is in location 14 in the register it energises this NOC.   Also, thank you for taking the time to read this. It has been very stressful!  
  14. Student advice

    Sorry, I can't look at a youtube video right now. I'm really not just ignoring it... Do IP3, IP4, and IP8 operate simultaneously? In other words, if an assembly passes by, do all 3 inputs turn on and off at the same time? If the 3 inputs are synchronized, try changing rung 11 so that it only turns on R1.15 when IP4 is on AND IP3 is off. Eliminate rung 12. Then shift the data. You may need to use the other state of IP4 to shift it properly. I see an RES instruction and a "U" instruction. Both seem to be used on individual memory bits. What is the difference between them?  
  15. Student advice

    There has to be a solution that: (a) Identifies the three types of items. (b) Stores the data correctly in the bit shift register. Agh!
  16. Student advice

    When I use the Rung 11 that identifies only assembled items and pegs - the register keeps an accurate record. When I use the Rung 11 that identifies EVERYTHING by using IP4 - the register does NOT keep an accurate record. In the latter case, I think there is double counting caused by using IP4 on two rungs (11 and 13).
  17. Student advice

    It is supposed to represent the IP4 scanning beam. This is how the system operates: https://www.youtube.com/watch?v=6YFHfiQCqBs
  18. Student advice

    What is the device between IP3 and IP4? Is it a gate? Or a light barrier? How many parts could be in the system at a time?  
  19. Student advice

    In the above 4 pics, you can see the changes in the register. pic 1. Register is 0000 0000 0000 0000. Nothing has been scanned and identified. pic 2. Register is 1000 0000 0000 0000. Peg has been scanned and identified by IP8. Bit 1 is input into location 15 (MSB). pic 3. Register is 0100 0000 0000 0000. Peg has been scanned by IP4. This SHIFTS all bits to the right (via Rung 13). pic 4. Register is 0100 0000 0000 0000. Item rejected by piston OP3. No affect on register. This is how it is supposed to work.
  20. Student advice

    1 = reject 0 = not reject I've written the code to put the first scanned item in location 15 (MSB). Then, when the item reaches IP4, rung 13 triggers a bit shift. In this software, each bit shift trigger moves EVERYTHING in the register one position to the right.   Pics below.   This is for the code that only identifies assembled items and pegs. It does NOT identify rings. However, what it does identify is correctly recorded and ordered in the register.  
  21. Student advice

    I'm not sure how the shift register works in this software, so I didn't dig much into troubleshooting it. Are you tracking each of the 3 things (peg, ring, assembly) with its own register? If so: If IP3 = 1, track an assembly if IP8 = 1, track a peg If IP4 = 1 AND IP3 and IP8 are BOTH 0, track a ring. If you just need to track items to be rejected (lone pegs and lone rings, but not assemblies, right?) then it's even simpler. You would use IP4 AND NOT IP3 to set the reject bit in the register. This would set the bit to track anything that's not an assembly. You can still trigger the shift with IP4 since it turns on for all of the items. Just be careful that you set the bit and shift the bits in the right order.
  22. Student advice

    The problem is: Although, I can now identify and differentiate each type of item because I use IP4: It introduces errors into the register (outlined in previous post).
  23. Student advice

    Rung 11 does differentiate between all three item types. However, it introduces errors into the Bit Shift Register. Here, I discussed the operation of Rung 11 with and without IP4:  
  24. Student advice

    Rung 11 is intended to identify individually: assembled items, pegs, and rings. They all generate a 1. 1 triggers the rejection piston (OP3). Because assembled items aren't supposed to be rejected (!) there is a line of code which changes their 1 to a 0 thereby avoiding rejection.  
  25. Student advice

    You're right, it's a lot easier to see in the screenshot. If rung 11 is intended to detect a ring, your conditions should be in series, not in parallel. That rung will be true if IP3 is OFF, OR IP8 is ON OR IP4 is OFF. I suspect that IP3 and IP4 will be off most of the time and only turn on when something shows up. Instead, to detect a ring, you need IP3 to be OFF, AND IP4 to be ON, AND IP8 to be off. IP8 is on only when a peg is present, so you can use it alone. Same with IP3 and assemblies. The only one you need all 3 sensors for is the ring.
  26. Student advice

    IP4 is used twice for different purposes: Rung 11 - to identify a Ring and input '1' into the register. Rung 13 - to bit shift the items in the register, for example: 1000 0000 0000 0000 to 0100 0000 0000 0000.
  27. Student advice

    A pic of the code is clearer.  
  28. Load more activity