Hal connection
- horcsab
- Offline
- New Member
Less
More
- Posts: 13
- Thank you received: 1
16 Dec 2024 13:34 #316753
by horcsab
Hal connection was created by horcsab
Hi All,
Please help me!
I have promblem and I don't understand hal net command.
I always get an error in the lubrication section.
# LUBRICATION
# Oil level check
net oil_level_ok FUW400-5A-75E.gpio.26.in-not => and2.0.in1
net oil_low_warn FUW400-5A-75E.gpio.26.in-not => not.0.in
net oil_low FUW400-5A-75E.gpio.26.in-not => msg.trig
I get this error in second line: Pin 'FUW400-5A-75E.gpio.26-not' was already linked signal 'oil_level_ok'.
If I try this:
net oil_level_ok FUW400-5A-75E.gpio.26-not
net oil_level_ok => and2.0.in1
net oil_low_warn oil_level_ok => not.0.in
net oil_low oil_level_ok => msg.trig
I get this error message in second line: Pin 'oil_level_ok' does not exist
How do I fix it to make it work?
Thanks!
Please help me!
I have promblem and I don't understand hal net command.
I always get an error in the lubrication section.
# LUBRICATION
# Oil level check
net oil_level_ok FUW400-5A-75E.gpio.26.in-not => and2.0.in1
net oil_low_warn FUW400-5A-75E.gpio.26.in-not => not.0.in
net oil_low FUW400-5A-75E.gpio.26.in-not => msg.trig
I get this error in second line: Pin 'FUW400-5A-75E.gpio.26-not' was already linked signal 'oil_level_ok'.
If I try this:
net oil_level_ok FUW400-5A-75E.gpio.26-not
net oil_level_ok => and2.0.in1
net oil_low_warn oil_level_ok => not.0.in
net oil_low oil_level_ok => msg.trig
I get this error message in second line: Pin 'oil_level_ok' does not exist
How do I fix it to make it work?
Thanks!
Please Log in or Create an account to join the conversation.
- andypugh
- Offline
- Moderator
Less
More
- Posts: 23558
- Thank you received: 4858
16 Dec 2024 16:57 #316774
by andypugh
Replied by andypugh on topic Hal connection
Your first block of code could be written on a single line,
But I think that there might be a problem with your logic.
What does FUW400-5A-75E.gpio.26 actually indicate? It can't mean Low, OK _and_ warn.
Should these use GPIO 26, 27 and 28 maybe?
If not, and you are deriving different meanings from the GPIO with different logic, then you can only have one signal that represents the value of FUW400-5A-75E.gpio.26-not. It's a bit inconsistent insome ways, as you are allowed to to treat in-not and in as separate inputs, despite the fact that they are the same data.
You can not bother with not.0
(possibly, I don't know how your system is set up)
net oil_level_ok FUW400-5A-75E.gpio.26.in-not => and2.0.in1 not.0.in msg.trig
But I think that there might be a problem with your logic.
What does FUW400-5A-75E.gpio.26 actually indicate? It can't mean Low, OK _and_ warn.
Should these use GPIO 26, 27 and 28 maybe?
If not, and you are deriving different meanings from the GPIO with different logic, then you can only have one signal that represents the value of FUW400-5A-75E.gpio.26-not. It's a bit inconsistent insome ways, as you are allowed to to treat in-not and in as separate inputs, despite the fact that they are the same data.
You can not bother with not.0
net oil_level_ok FUW400-5A-75E.gpio.26.in-not => and2.0.in1
net oil_low_warn FUW400-5A-75E.gpio.26.in => msg.trig
(possibly, I don't know how your system is set up)
Please Log in or Create an account to join the conversation.
- horcsab
- Offline
- New Member
Less
More
- Posts: 13
- Thank you received: 1
16 Dec 2024 17:13 #316778
by horcsab
Replied by horcsab on topic Hal connection
Dear Andy,
Thank you for your reply.
I would like to install central lubrication on the machine.
FUW400-5A-75E.gpio.25.in-not: this bit is connection oil pressure switch.
FUW400-5A-75E.gpio.26.in-not: this bit is connection oil level switch.
I would like to solve this:
If there is not enough oil level, then there should be no lubrication and write it on the screen.
If there is enough oil level, then lubrication can be set periodically, for a given time.
If lubrication has started, then watch whether the pressure switch switches during a given time. If it does not switch, then write it on the screen.
Thank you for your reply.
I would like to install central lubrication on the machine.
FUW400-5A-75E.gpio.25.in-not: this bit is connection oil pressure switch.
FUW400-5A-75E.gpio.26.in-not: this bit is connection oil level switch.
I would like to solve this:
If there is not enough oil level, then there should be no lubrication and write it on the screen.
If there is enough oil level, then lubrication can be set periodically, for a given time.
If lubrication has started, then watch whether the pressure switch switches during a given time. If it does not switch, then write it on the screen.
Please Log in or Create an account to join the conversation.
Time to create page: 0.049 seconds