So here is the next level
Adding the embedded tab as in previous post.
This one has the following hal pin:
Code:
HAL_BIT OUT timer.alarm_machine
HAL_BIT OUT timer.alarm_spindle
HAL_U32 OUT timer.elapsed_periodes_machine
HAL_U32 OUT timer.elapsed_periodes_spindle
HAL_BIT IN timer.machine_on
HAL_U32 IN timer.periode_time_machine
HAL_U32 IN timer.periode_time_spindle
HAL_BIT IN timer.reset_alarm_machine
HAL_BIT IN timer.reset_alarm_spindle
HAL_BIT IN timer.running
HAL_BIT IN timer.spindle_on
As shown in the attached hal file you will need to set the periods for the time after you want the alarm like so:
Code:
setp timer.periode_time_machine 2
setp timer.periode_time_spindle 1
Give the time in minutes, so here a alarm is given for machine time after 2 minutes and every minute you get an alarm for the spindle
In real machines you will sure set the time intervals longer, in my machine I set the machine time to 259200 and spindle time to 480
After that time periode the alarm pin will get high and will stay high until you set the corresponding timer.reset_alarm pin to high, do not forget to set it low again after you have done the maintenance or lube! Setting the reset pin high will clear the alarm an increment the elapsed_periods pin, so if you have done 10 lubes you may control the lube level to see if the use of oil is in between your limits or what ever you want to do with that information.
All values will be stored in a var file and reloaded on next start, machine pin after turning on the machine, spindle pin after turning on the spindle.
So what next?
- part counter
- travel distance
- anything else
And again you see, there is nothing impossible with gmoccapy and python. By the way this embedded tabs can also be included and axis and some other GUI.
So now I need testers and feed back
Norbert