function error = prologix_error(addr)
%PROLOGIX_ERROR Summary of this function goes here
%   Detailed explanation goes here
    t = prologix_connect();
    fprintf(t, ['++addr ', num2str(addr)]);
    fprintf(t, 'system:error?');
    fprintf(t, '++read');
    error = fscanf(t);
    prologix_disconnect(t);
end

