modified JSON serial output

modified JSON serial output to output all data at once