And is there any way to collect data from two input pins simultaneousl in processing? And to specify which pins is all about.
Yes. Define a protocol for sending the data from your Arduino sketch to a Processing sketch. For example, you could use '<Innn,Onnn>'. You would need to modify the Processing sketch to read the whole string, and split it up.