added log/trail display for debugging purposes