- The SMTP server can represented as an IPv4/IPv6 address or a domain name. If a domain name is used, enable and initialize µC/DNSc properly.
- Mailbox represent the address and name of a sender (FROM) or recipient (TO,CC and BCC). Multiple recipients can be set for an email.
- µC/SMTPc allow the user to authenticate to a SMTPc server with credential if needed.
SMTPc_SetMsg() function must be called to initialized the SMTPc_MSG object. In order to set a mailbox in the email, SMTPc_MBOX instance must be passed to the SMTPc_MSG object. - The connection to the SMTP server can be either secure or not. In this example, the connection is non-secure and uses the legacy port 25. If a secure connection is required, p_secure_cfg must be configured. For more information, refer to thethe µC/TCP-IP SSL Module.
- SMTP_SendMail() function will process each step to send the email. It will connect to SMTP the server, prepare and send the email and disconnect from the SMTP server.
|