Updated the trace log generation

Signed-off-by: Herbert <herberthb12@gmail.com>