Push Buttons with LEDs

Moderators: TomKerekes, dynomotion

Post Reply
tmday7
Posts: 51
Joined: Fri May 11, 2018 10:17 pm

Push Buttons with LEDs

Post by tmday7 » Thu Feb 13, 2020 12:10 pm

Hello,
Starting on my mill control panel now and need some info on using momentary push buttons with built in LED. All buttons and LEDs are physical buttons, not KMCNC screen buttons.
I have 2 buttons for the Feed Forward and Feed Reverse when Feed Hold is active. I am trying to figure out how to turn on the Feed Forward,Reverse LEDs when the Feed Hold button is pressed and switch off LEDs when Cycle Start button is pressed to resume motion. Buttons and LEDs are 24vdc and LED 24v+ will come from the Feed Hold switch that is connected to a Konnect input.
Can a latching transistor circuit of some sort be used? Or is there a simple way iam missing?

Thanks for any info,
Troy

User avatar
TomKerekes
Posts: 2679
Joined: Mon Dec 04, 2017 1:49 am

Re: Push Buttons with LEDs

Post by TomKerekes » Thu Feb 13, 2020 5:57 pm

Hi Troy,

You should just be able to test CS0_StoppingState to check if Feedhold is active and control the LEDs in your forever loop. Something like:

Code: Select all

	if (CS0_StoppingState == 0)
		ClearBit(FEEDHOLD_LED);
	else
		SetBit(FEEDHOLD_LED);
HTH
Regards,

Tom Kerekes
Dynomotion, Inc.

Post Reply