Posted 14 Oct 2021 I am working on something different. I have a Signal Speaker that uses binary inputs to play a certain song based on source configuration. I have to send 24v to the inputs of the speaker. I have 5 of them with 30 different configurations. I am currently trying to do this in ladder logic, RSLogix 5000. Steps done. 1. Assigned the 6 outputs tag names. This is so that I can shift the program to other machines if I have to and I just need to change the slot location, or if I have an output go bad I can move it with ease. This works. 2. I created the 30 lines of 5 columns to match the binary method. This works. a. I can manually toggle the output to cycle thru the binary table. 3. Currently working on the logic that when a particular alarm is activated... I turn on the outputs needed to match the binary table. The problem is destructive bit reference on the coils. I was researching some but don't know what direction to go. How can I call the same output on different rungs? I have attached the .L5X to show what I have programmed. 4. I know the first rungs are wrong. That is what I am trying to fix. 5. Would there be a better way to address this, if so how? Any help would be greatly appreciated. Speaker_Alarm.L5X Speaker_Alarm.L5X Share this post Link to post Share on other sites
Posted 14 Oct 2021 Unfortunately I can't look at your logic from this computer. Why can't you use OR logic to turn on the output --! ! --------------( ) ! --! !----- ! --! !----- Share this post Link to post Share on other sites
Posted 14 Oct 2021 You can also use bits of an integer to trigger the output and then Move an Int into the register based on the DI. 1 person likes this Share this post Link to post Share on other sites
Posted 15 Oct 2021 Michael that is exactly what I am wanting to do. Unfortunately, I don't know how to do that, first time. Could you show an example of assigning the output channels? I have added a pdf of the program to show my setup. Speaker msgs.pdf Share this post Link to post Share on other sites
Posted 15 Oct 2021 I'm at work so I have access to the AB software. I can't open the L5X files. It says The specified L5X file does not contain a controller export. Likely because I don't fully understand what you are trying to do, I don't see a problem with your logic. You are trying to " call the same output on different rungs" Flip that around to call the same output with different logic Kudo's for getting this far without PLC experience. I've attached a completely unrelated type of program with various kinds of branches, one shots (ONS) (positive edge trigger that passes the on state once and won't pass it again until the input turns off then on again), etc Take a look at any of the MOV routines (motor operated valve). Some of the triggers come from Pxxx routines (pumps). There are numerous branched rungs I like to map IO to tags to user defined data types (under Data Types folder) so I can easily reassign the IO... None of this is THE way to do it. It's how I do it. Asherton_05_26_16.ACD 1 person likes this Share this post Link to post Share on other sites
Posted 15 Oct 2021 Looking at your pdf, reverse the way you're controlling your bits: Each output coil should only be referenced once. Gather all conditions that will turn that coil on together, in parallel, on a single rung. Another thing you could do is assign a number to each message. So, for example, message 3 would require that bits 0 and 1 are both on. You can have the alarm conditions write a number to a tag and then map the individual bits of that tag to individual outputs: If the speaker turns off when its input 0 is turned on, then you can only configure 31 messages instead of 64 (you can get 32 messages if having all channels turned off can trigger a message). You could use AlarmMSG=0 to turn on Output_0 and then offset the remaining bits: 2 people like this Share this post Link to post Share on other sites
Posted 15 Oct 2021 Thank you for help! Have a great weekend. Share this post Link to post Share on other sites
Posted 15 Oct 2021 Let's see if I can whip out a possibility: Song Selected is a DINT or INT XIC ConditionsSong1Met MOV 1 SongSelected XIC ConditionsSong2Met MOV 2 SongSelected XIC ConditionsSong3Met MOV 3 SongSelected ..... XIC ConditionsSong30Met MOV 30 SongSelected XIC SongSelected.0 OTE OutputWiredToSpeakerBit1 XIC SongSelected.1 OTE OutputWiredToSpeakerBit2 XIC SongSelected.2 OTE OutputWiredToSpeakerBit3 XIC SongSelected.3 OTE OutputWiredToSpeakerBit4 XIC SongSelected.4 OTE OutputWiredToSpeakerBit5 Now if an output dies you just change it in one rung. Also no fancy instructions just XIC for old joe relay. Share this post Link to post Share on other sites