Managing cdr output

I am migrating users from an Asterisk 10.12.3/FreePBX 2.10.0rc1 to Asterisk 12.4.0/FreePBX 12.0.42 and am finding it difficult to return the same results in the cdr record for fields 2 (src) and 3 (dst).

On the old system, field to shows the agent extension for src and shows the dialed number for dst on outbound calls. On inbound calls, it’s the opposite. Agent extension would be in dst and the DID dialed would be in dst.

On the new install, the trunk callerID displays in src and “s” appears in dst.

Can anyone tell me how I should manipulate settings to reflect the csv output the same way my old system did?

EDIT – I have checked and see that src is not getting set correctly because ${AMPUSER} returns a null value. Does anyone know how to ensure that the AMPUSER variable gets set correctly when the extension is registered and a call is made?