There are many ways to do this. You might try an "Only when" condition and put in your 10pm to 8 am time restrictions. You have to check the "Show restrictions" option in your piston options to see the "Only when".
I would suggest reading through this Only When discussion and using Restrictions.
You could instead use a Time is between condition.