I have a generic question about changing pin state and triggering a function based on pin state change.
Iíve seen it is possible to trigger an interrupt by changing the a pin state from HIGH to LOW for exp. using a button/switch for example and this interrupt will run an ISR (Iím not too familiar with interrupt programming).

Assuming I have 2 TS31 letís call them TS1 and TS2.
TS1 and TS2 are running 2 different sketches. Iíd like to use TS2 to trigger execution of a specific function (like an ISR?) on TS1 by changing the state of a defined pin on TS1 (from High to Low for exp).
In other words, TS2 would act as a switch.
Will this work if I simply connect a pin from TS1 as digital input to TS2 pin in digital Output mode? How could I do this?

Thank you,