JRICE

Program lamp to flash error code

5 posts in this topic

As I am a noob this is probably a noob question. I have a machine with a micro 1400 and if the machine has a fault or jams it lights it's "machine fault" lamp. The fault can be triggered by one of 8 prox switches not getting made within a certain time span. There is nothing to indicate which one. I'd like to program the lamp to, rather than stay on steady, have a blink pattern to indicate which prox caused the fault condition. 3 blinks and a pause, then repeat for PROX 3 for example.

I have searched for this with no joy. Thanks - Jon

Share this post


Link to post
Share on other sites

A simple flowchart, here, will help you design the circuit.  So you have (1) output - a PLC output energizing a fault lamp; with (8) inputs - proximity sensors.  You want PRX1 to flash the output once-pause; PRX2 to flash the output twice-pause; etc.  

?1. Do your (8) proximity switches have normally-opened (NO) or normally-closed (NC) contacts.  

?2. How should the fault lamp output behave if (2) or more fault proximity switches are made.

Yeah, you will not find an example of this in literature as this is a PLC ladder logic or function block or structured text programming example.

Is this a class project?

Share this post


Link to post
Share on other sites

Not a class project. I'm a field service technician for a packaging equipment distributor. I haven't done much PLC programming but (in a past life) did program in Basic, RPGII, Fortran, Cobol, Pascal, and composed some very complicated Lotus 123 spreadsheets interpreting a serial data output from an injection mold press and formatted the data into a report. I need to stress the "past life" part. I remember knowing how to do all that stuff, could not necessarily do any of it today.

I have some in line automatic strapping machines I'm installing 4 hours away from my home and I'm trying to make remote troubleshooting easier, as in over the phone. If sales had pushed the panelview option I wouldn't be doing this... My thought was I'd use an S bit to get a flash rate I like and then use a counter to limit the number of flashes before I do a pause. flash X times, pause, repeat,  I would use a move statement to put the value in the counter depending on what triggers the fault.

All of the prox's I've looked at so far are NO.

Ideally the lamp would indicate the first cause of the fault as a condition causing one time out might also cause others unrelated. That's a good consideration though.

I'm doing the first one next week so I may be able to watch the fault routine in action to get a good idea of how it sets/resets itself. 

Most of the work I do with PLC's is either troubleshooting or forensic programming - I run across customers that have a PLC with little to no (or incorrect) documentation and have to teach it a new trick or port the program to a newer PLC.

Whatever guidance I can get is highly appreciated.

Thanks,

Jon

 

 

 

Share this post


Link to post
Share on other sites

Some students post here for the quick answer.  

With NO proximity sensors, these would be coded in parallel so that any energized will energize your alarm coil.

With NC proximity sensors, these would be coded in series.

To get the flash rate of the alarm coil to match the proximity sensor, you will run  into issue if more than one sensor is made at a time.  You can work around this by coding a routine that will cycle through the alarm codes with pauses or fast pulses in between alarm code display and a different pause or fast pulse when cycling through.

My suggestion is a state-based routine; use a state register; rung 1, state 10, if this then that and move to state 20; rung 2, state 20, if this then that and move to state 30.  With state-based routine you can easily add code to get the desired results and make the routine robust and functional.

1 person likes this

Share this post


Link to post
Share on other sites

Could you pack the prox sensor status into a word based on first out? Then compare, and flash sequence (x) if = to ?

4 prox sensors = integer value 0, 1, 2, 4, 8 BUT first out would have to clear the other bits.

 

1 person likes this

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now