Split messages into multiple packets if exceeds maximum length