The Primary Surveillance Radar (PSR) sends out an electromagnetic signal that reflects off objects in the PSR space that are large enough to be picked up and returns the reflection to the PSR as an image on the ATC screen.
SSR sends an interrogation signal to the aircraft that is received and answered by the transponder. In order for SSR to return a signal to ATC the aircraft has to be equipped with a transponder.
The transponder is in the cockpit and the pilot enters a 4-didgit code that talks to ATC through the SSR. The numbers 0 through 8 are used in a combination of four. This is why it is sometimes referred to as 4096 transponder. When the SSR interrogates the transponder, the transponder sends information to ATC such as altitude and ID . If the pilot is not in communication with ATC and has a transponder, normally the pilot will have the transponder on and set to 1200. If the pilot is under ATC control, ATC gives the pilot a specific code to SQUAWK. By entering this code, ATC now knows wich aircraft is being picked up by SSR. If a pilot request help from ATC, ATC will issue a code and/or tell the pilot to IDENT. This will allow ATC to verify the location of the aircraft they are talking to.