examples: Updated SMTP MAIL example to use a read function for data

Updated to read data from a callback rather than from stdio as this is
more realistic to most use cases.
examples: Synchronised comments between SMTP MAIL examples