I'm using DA 16200mod evk to publish to a topic in Aws. Downloaded the DA16200 firmware image '.ttl' script from DA16200_DA16600_AWS_v3.2.8.0_ATCMD_img. Have sent the three certificates files over uart.I have done the configurations using AT commands sending from nRF52840 DK uart, as follows
Hi There,Thank you for posting your question online.
vani said:As per the manual after this a factory reset is to be done which leads to soft ap mode and waiting for provisioning. But here it is entering soft AP mode but no wfscan happens or provisioning cannot be done.
In order to go into Provisioning mode, you will have to use the Android or IOS mobile application. Please refer on UM-WI-038 , on A.1.2 Provisioning Mode, on page: 31Regarding the error you are facing when transmitting AT commands to the DA16200:I will have to take a look and get back to you as soon as possible. In the meantime, could you please access the NVRAM via the Debug Console Interface (UART0) and check if the AWS broker configuration has been properly saved?Best Regards,OV_Renesas
hi, I cheked the nvram and got this response.
and the certificate status is as below.Is the DH parameter necessary for this to work?If necessary,how can I get it?
and getting error message as
Any updates regarding this?
Hi There,Thank you for the reply.Apologies for the delay but I am travelling on a biz trip until Friday 10th. Please note that there will be a delay on the responses but I will look into it.Best Regards,OV_Renesas
Hi There,Apologies for the delay.
vani said:and getting error message as
The MQTTBadParameter error code corresponds to if the packet would exceed the size allowed by the MQTT spec or if a subscription is empty. It seems that you did not issue the MQTT request with the correct parameters.Please refer on User Manual DA16200 DA16600 Getting Started with AWS® IoT Using AT Command UM-WI-038It would be helpful for us if you could share the whole UART0 and UART1 log files so we can understand the AT commands sequence you used and how you configured your DA16200.With the Wi-Fi Provisioning Mobile application were you able to do provisioning and access the AWS server?Best Regards,OV_Renesas
A gentle remainder. Please let me know if any updates.
Hi Vani,Apologies for the delay. Could you please share the whole UART0 (Debug Console Interface) logs with Timestamps?In order to add timestamp and keep the log file:On Tera Term--> FIle--> Log.. --> Make sure you select the Timestamp option.Please also make sure you define the DEBUG_ATCMD macro, so we can get all the debug info from the AT commands on the UART0.Best Regards,OV_Renesas
Hi,
I will be following this from now on behalf of Vani. Regret any inconvenience caused.
As you mentioned, we enabled the timestamp option and have attached the file herein. But please note that firmware ‘DA16200_DA16600_AWS_v3.2.8.0_ATCMD_img’ from https://www.renesas.com/us/en/document/sws/aws-iot-atcmd-image-freertos-sdk?r=1600096 was used by us.
If we need to include the DEBUG_ATCMD macro, could you please help us with the corresponding sample software file which will support the AT commands and wherein we can possibly define the mentioned DEBUG_ATCMD macro?
Please let me know your feedback.
Thanks and Regards,
Raji0552.teraterm.log
Hi Raji,Thank you for the reply.You are using the pre-compiled images.For the generic FreeRTOS SDK v3.2.8.0 AWS:1) Download the FreeRTOS SDK v3.2..8.12) Download the AWS IoT Reference for FreeRTOS SDKInside the AWS IoT Reference for FreeRTOS there is a ReadMe file on how to integrate the AWS functionalities on the generic SDK.In order to enable the AT commands please refer on UM-WI-003, on section 4.1.1 How to Run AT-CMD on UART, on page: 26You can define the DEBUG_ATCMD macro there or in the atcmd.c/h files.Follow the steps of the UM-WI-056, on section 5.4 Importing DA16200 FreeRTOS SDK Project into e 2studio, on page: 36 so you can understand how to Import and Build your project on e2studio.We would also recommend you follow our available example first to understand how to configure the AWS Server and the DA16200 based on the following documents. 1) UM-WI-017 DA16200 AWS IoT Server Setup (renesas.com)2) UM-WI-016 DA16200 Door Lock Application Using AWS IoT (renesas.com)3)UM-WI-038 DA16200 DA16600 Getting Started with AT Command for AWS IoT (renesas.com)For our Demo, you will our Wi-Fi Provisioning App to test it:Renesas WiFiProvisioning - Apps on Google PlayFrom the log file you shared it is not clear to me how you issue the AT commands and the responses, this is the reason we need the DEBUG_ATCMD macro defined.On the log file I can see:
======================================================= argc num = 2 argv[0]: AT+AWS argv[1]: SET APP_THINGNAME vani_aws_iot ======================================================= APP SET vani_aws_iot ======================================================= argc num = 2 argv[0]: AT+AWS argv[1]: SET APP_PUBTOPIC vani_aws_iot/DeviceControl ======================================================= APP SET vani_aws_iot/DeviceControl ======================================================= argc num = 2 argv[0]: AT+AWS argv[1]: SET AWS_BROKER a3kbzziaf9hg4n-ats.iot.us-east-1.amazonaws.com ======================================================= APP SET a3kbzziaf9hg4n-ats.iot.us-east-1.amazonaws.com ======================================================= argc num = 2 argv[0]: AT+AWS argv[1]: CFG 1 mcu_door 1 0 ======================================================= ======================================================= Att[1] number : 1 Att[1] name : mcu_door Att[1] data type: 1 Att[1] MQTT type: 0 =======================================================
======================================================= argc num = 2 argv[0]: AT+AWS argv[1]: CMD MCU_DATA 1 mcu_door opened ======================================================= board feature : topicCount : 1 Count : 0, cmdNum = 1 mqtttype = 0 data type(publish)=1 call publish: 1 mcu_door opened [ERROR] [MQTT] [validatePublishParams:1756] Packet Id is 0 for PUBLISH with QoS=1. [ERROR] [MQTT] [MQTT_Publish:2193] MQTT PUBLISH failed with status MQTTBadParameter. [ERROR] [PkcsTlsTransport] [xPublishToTopic:1396] Failed to send PUBLISH packet to broker with error = MQTTBadParameter. publish (contents update) NG - topic : vani_aws_iot/DeviceControl payload: 1 mcu_door opened [/DA16200] # ======================================================= argc num = 2 argv[0]: AT+AWS argv[1]: CMD MCU_DATA 1 mcu_door opened ======================================================= board feature : topicCount : 1 Count : 0, cmdNum = 1 mqtttype = 0 data type(publish)=1 call publish: 1 mcu_door opened [ERROR] [MQTT] [MQTT_SerializePublishHeader:1995] Argument cannot be NULL: pFixedBuffer->pBuffer is NULL. [ERROR] [MQTT] [MQTT_Publish:2193] MQTT PUBLISH failed with status MQTTBadParameter. [ERROR] [PkcsTlsTransport] [xPublishToTopic:1396] Failed to send PUBLISH packet to broker with error = MQTTBadParameter. publish (contents update) NG - topic : vani_aws_iot/DeviceControl payload: 1 mcu_door opened
Thank you for you detailed reply. I followed your instructions, copied the AWS IoT package in the '~SDK\apps\' directory of the DA16200_DA16600 Generic SDK V3.2.8.1, defined the DEBUG_ATCMD macro and built it using e2 studio. But after flashing the new images in the DA16200MOD-DeVKT through teraterm using the macro and .ttl script generated as shown below,