added encoders for ports and pids
typo fix
removed variables from list_records_to_json macro