How to connect motor driver with optoisolated inputs

HOW TO CONNECT MOTOR DRIVER WITH OPTOISOLATED INPUTS?

There are two possible connections:

1. Common cathode
opto_common-cathode

2. Common anode
opto_common-anode