News:

  • June 09, 2026, 08:14:41 AM

Login with username, password and session length

Author Topic: DL06 IO Slots  (Read 14573 times)

hirzel

  • Newbie
  • *
  • Posts: 8
DL06 IO Slots
« on: June 05, 2008, 02:24:40 PM »
I authored a program that we use in several pieces of equipment. The program is generic in nature, and can run on many different versions of our machines.

As I add features to the same basic program, I find I needed to add three IO cards in the expansion slots to support the new features.  I want the program to be backwards and forward compatable, so I leave existing IO assignments as they are.

Heres my problem:

I'm using the same program in many machines, Some machines only use the on board IO, some use one of the IO expansion, and some use both the IO.

I set up the IO Configuration manually so that the same Xs and Ys are assigned to a particular slot.  In this case:

Slot 0 is Automatic (I put an analog in this one, sometimes)
Slot 1 is X100 Y100
Slot 2 is X120 Y120
Slot 3 is X140 Y140


Example:

I use X140 (its in slot 3) to look at a tach pulse to see if a long shaft is OK (the belt hasn't broke, etc). In my program, If I don't see this pulse, I raise an alarm to check the shaft belt.

On some machines, I don't use this feature (solid shaft, no belt) In this case, I simply connect the X140 input to the regular tach so they both get pulsed by the same sensor.

What I would like to do, is check and see if this card is installed in Slot 3,  if it isn't, then ignore (open contact) the requirement for the X140 tach pulse input.

QUESTION -  Is there a way to tell, programatically, if an IO card is installed in a slot? This would make my life very easy.

John








« Last Edit: June 05, 2008, 02:28:17 PM by hirzel »

milldrone

  • Full Member
  • ***
  • Posts: 48
  • I'm changing my attitude to thumbs up
Re: DL06 IO Slots
« Reply #1 on: June 06, 2008, 12:39:00 PM »
hirzel,

I read your post, and I thought this would be easy. I remembered seeing the special relays SP140 to SP537 in the appendix D. Good thing I tried it first, I received no change of state for any of those when I installed an option card.

As a kludge, can you make one of the inputs always on by installing a permanent jumper when you install a module?
Vaughn

ATU

  • Internal Dev
  • Hero Member
  • ****
  • Posts: 2126
  • YKPAIHA
    • ATU, Inc.
Re: DL06 IO Slots
« Reply #2 on: June 06, 2008, 01:12:29 PM »
For input modules, if you check the state of an input and then try to change it in the program using a SET or RST bit.  If the module is not present , I think the bit will change state and remain in that state for more than 1 scan. However, if the hardware is present the I/O update will always reflect the state of the input and will change it back to whatever that state is in the begining of the IO updae.  So you could put a series of stages in your startup routine to test the input and then make your decisions from there. I tested this on a 405 system and it seemed to work, not an 06, but it should work. Output modules would be a little more involved,maybe run an output to an input.

hirzel

  • Newbie
  • *
  • Posts: 8
Re: DL06 IO Slots
« Reply #3 on: June 09, 2008, 02:42:06 PM »
Thanks for the replys;

All the inputs are assigned, so that rules out that option.

However, I like the idea ATU presented.  I'll put an "Initialize" stage in to test for input cards, then enable the normal stages after I figured out what cards are present.

Thanks for the ideas.

Hirzel

hirzel

  • Newbie
  • *
  • Posts: 8
Re: DL06 IO Slots
« Reply #4 on: June 10, 2008, 03:57:26 PM »
OK, This works great for the input cards. (I don't have output cards so its not a big deal)

I SET all the inputs, X100 - X105 (slot2) , and X120 - X127 (slot3) on the first scan.

On the second scan I test them to see if they're still SET.

If they're still SET, I set a Flag (C100 for Slot 2 and C101 for Slot3, then RESET all the inputs.

On the third scan I test to see if they are still RESET;

If C100 is SET and the X100 - X105 are still RESET, then I know my Slot2 is empty.

If C101 is SET and X120 - X127 is RESET, then I know Slot 3 is empty.

I then set C100 and C101 again, according to the Slot 2 and 3 empty or not.

I then SET Stage %, which containes the main program



Hirzel


ATU

  • Internal Dev
  • Hero Member
  • ****
  • Posts: 2126
  • YKPAIHA
    • ATU, Inc.
Re: DL06 IO Slots
« Reply #5 on: June 10, 2008, 10:20:06 PM »
The idea occured to me because on the older 405 TI systems, we used to run out of C coils with one of the machine builders, so they would use use expansion rack X's and Y's ( it was really confusing) but they work just like C coils if the hardware was not present. Glad that worked out.