I'm very pleased with this design. it will eventually be part of a packet-switched railway where carts can be dispatched autonomously to a distant destination, each carrying with it a ticket that tells the railway system where it should be directed. This is a test of a single switch; it detects if a piece of paper is in the minecart chest, and if so, switches it to the side track and returns the ticket to the cart. When I throw the paper onto the hopper, it's dispensed into the minecart, so as to demonstrate the switching.