Workplace automation

My project overview is to have a machine turn off the air compressor.

The compressor has the ability turn on and off with an input signal of 24v. When the compressor is supplied with 24v, the compressor is on. When there is no more input voltage, the compressor shuts off.

The machine can output a 24v signal before the machine turns off.

I also need to have the ability for an external input such as a switch.

This is what I am thinking

Input 1 - External Switch (Person can manually turn on or off compressor)
Input 2 - Machine (Machine is on or off)

Output 1 - Compressor A
Output 2 - Compressor B

If Input 1 or Input 2 is on, One of the compressors is on.
Both inputs must be off before the compressor shuts off.

I have 2 outputs because we run Compressor A during the busy days (Mon-Thurs) and the back-up (Fri-Sat)

I feel like I can write the logic without too many issues. I could use some assistance with the hardware. I am not quite sure how to step the voltage up and down for the arduino. Also, how to make sure it is stable.

Resistor voltage divicers to get the 24V down to 5V (or 3.3V) for an Arduino input. Or opto isolators.

Logic level MOSFETS to raise output voltage from the 5V (or 3.3V) of an Arduino output to 24V.

Signals are indeed easy enough to step up/down. Voltage dividers and small signal transistors will do just fine for this (mind that your output signal gets reversed this way: a high fro, the Arduino is a low on the output and the other way around) .

I can't help but wonder what the role of the Arduino is in this, really.