...
µC/SMTPc does not require to be initialized. Although, if you want to use the DNS features, µC/DNSc shall be properly initialized.
Create an email
To create an email, you will need to create an instance of SMTPc_MSG.
*From | SMTPc_MBOX | |
*ToArray[SMTPc_CFG_MSG_MAX_TO] | SMTPc_MBOX | |
*ReplyTo | SMTPc_MBOX | |
*Sender | SMTPc_MBOX | |
*CCArray [SMTPc_CFG_MSG_MAX_CC] | SMTPc_MBOX | |
*BCCArray [SMTPc_CFG_MSG_MAX_BCC] | SMTPc_MBOX | |
MsgID [SMTPc_MSG_MSGID_LEN] | CPU_CHAR | |
MIMEMsgHdrStruct | SMTPc_MIME_ENTITY_HDR | |
*Subject | CPU_CHAR | |
*AttachArray[SMTPc_CFG_MSG_MAX_ATTACH] | SMTPc_ATTACH | |
*ContentBodyMsg | CPU_CHAR | |
ContentBodyMsgLen | CPU_INT32U |
This must be first initialized with the function SMTPc_SetMsg(). You will need also to create several instance of SMTPc_MBOX to populate your SMTPc_MSG. SMTPc_MBOX is a mailbox that define the adresse and the name if a sender (FROM) or a recipient( TO,CC and BCC). SMTPc_SetMbox() is a tool to populate the field of the mailbox.
Function name | Description |
---|---|
SMTPc_SetMsg() | |
SMTPc_SetMbox() |
Send an email
Function name | Description |
---|---|
SMTPc_SendMail() | Process all the steps to send an email. |
...