You can run the Raspberry Pi and IO Pi Plus boards from the 24V power supply by using a voltage regulator to drop the 24V down to 5V. Ideally you will want to use a DC to DC switch-mode regulator as they are far more efficient than linear regulators, especially with large voltage drops like 24V down to 5V. I have used the PTN78020W from Texas Instruments for several Raspberry Pi projects in the past and athough they are a bit expensive they do produce a stable voltage and up to 6A capacity. You use a resistor to set the voltage for the output which you can find in the datasheet. You can also find plenty of cheaper switch-mode power supplies on places like ebay that would do the job. If you want to completely isolate the power supply for the Raspberry Pi from the motor then it is possible to get isolated switch-mode regulator but they are a bit more expensive.
You will need to use a common ground between the Raspberry Pi and IO Pi Plus boards, the isolation link on the boards only isolates the 5V rail so you can use two seperate 5V supplies and not have the IO Pi Plus supply back feed into the Raspberry Pi through the GPIO port. If the IO Pi Plus is plugged into the Raspberry Pis GPIO port then it will be connected to the Raspberry Pi ground through several of the GPIO pins so you will not need to connect seperate ground wires to each board.
You only need two 5V supplies if your Raspberry Pi supply is not capable of supplying enough current to power all of the outputs on the IO Pi Plus boards but as you will be driving an opto-isolator it should be safe to power the Raspberry Pi and IO Pi Plus from a single 5V supply and not remove the power link on the IO Pi boards. It may be worth using a regulator that can supply at least 3A to make sure you have plenty of spare current for the Pi and expansion boards.