There are really many variables here to consider: what kind of piece you are playing, what kind of style, what kind of instrument and so on.
Remember this: pistons only facilitate the change of organ stops. Instead of pulling many stops by hand, you simply press one piston with your thumb and everything changes instantly.
But the choices of stops that go into each piston depend on a lot of things. Sometimes you can use pistons in a public performance when you have to play some pieces with contrasting registration and pushing a piston simply reduces the time you would need to change the stops by hand between the pieces.
Sometimes pistons are very useful even in the middle of the piece when you have several contrasting sections and each would require contrasting registration which otherwise would require an assistant to make changes.
Sometimes the pistons are used to make crescendos and diminuendos in the middle of the piece. You set up the pistons in advance in a way that each subsequent piston has a little louder combination of stops. This happens a lot in many French symphonic pieces.
In this case pistons (and toe studs) are used similarly to the ventil system that traditional Cavaille-Coll organs had.
In many pieces of French organ composers, the places for change registration are very obvious - they write in the necessary reeds, other stops or couplers you have to add.
When a composer doesn't indicate the exact pitch level or exact stop combination, then you only see signs for dynamics in the score (pp, p, mf, f, ff etc.) - this is often the case with German Romantic composers. Then you have many more choices for your pistons but still try to consider the general characteristics and requirements for registration for this particular style.
Try to learn to read your score and composer's intentions and you will understand how to use pistons in changing registration.