Skip to content

How to perform OTA for Quectel module QuecOpen EG912U?

0

Hello, thank you for your response. I would like to update my questions:

1.I am currently stuck at the 'Create a code signing profile / Device hardware platform' step in the AWS console under FreeRTOS OTA, as there are no options to select. 在此处输入图片描述

2.I am not quite sure what kind of file should be provided for the S3 URL. Should it be the update package for the OTA? When I tried to select my update package out.pac, it didn’t appear as an option. 在此处输入图片描述

3.Is the 'Path name of file on device' the path where the OTA file will be automatically stored on my device after the update? 在此处输入图片描述

4.I would like to understand what kind of file is sent to my device when this FreeRTOS OTA job is executed. What is the process of how this FreeRTOS OTA job delivers the OTA update to the device?

Below are related screenshots and Quectel’s documentation.

asked 9 months ago140 views
2 Answers
1
Accepted Answer

Hi. It may be useful to share a link to where Quectel have documented this. So I can understand what they offer.

The code uses Quectel's official example code with the HTTP method.

So Quectel is expecting the FreeRTOS OTA update method, with HTTP transfer (instead of MQTT)?

The code requires a remote server link address for the upgrade package. Is the URL generated after placing the upgrade package into the S3 bucket the remote server link address?

If you are selecting the FreeRTOS OTA method in the AWS IoT console, it will call the CreateOTAUpdate API. This API will create a job document that contains a presigned URL placeholder for the firmware binary. When your device processes the job, a presigned URL is generated. This is the URL that the device should use to download the package. More here: https://repost.aws/articles/ARDHNhV0bnRGau0kmdhTSZZA/comparing-aws-iot-jobs-and-aws-iot-over-the-air-ota-updates

Presigned URLs grant time-limited permissions to download objects. Even if you don't use FreeRTOS OTA, you should use a presigned URL rather than a public object in the S3 bucket.

Since the Quectel module’s upgrade package has a .pac suffix, it cannot be placed into the FreeRTOS OTA’s S3 URL.

I'm not sure what you mean here. There's no restriction on the file extension. I just tested with .pac.

Regarding the code signing configuration file, I have generated the relevant certificate using OpenSSL, but I am unable to select the device hardware platform.

Sorry, do you mean you've imported your signing certificate to ACM, and now you're trying to to create a signing profile? If so, the platform setting should likely be AmazonFreeRTOS-Default.

https://docs.aws.amazon.com/signer/latest/developerguide/signing-profiles.html

aws signer put-signing-profile --profile-name my-profile --signing-material certificateArn=arn:aws:acm:<region>:<accountId>:certificate/<id> --platform AmazonFreeRTOS-Default --signing-parameters certname="foobar",certificatePathOnDevice="foobar"

UPDATE Feb 20 because the question was updated

1.I am currently stuck at the 'Create a code signing profile / Device hardware platform' step in the AWS console under FreeRTOS OTA, as there are no options to select.

I'm not sure what the issue is there in the console, but I recommend you create the signing profile using the CLI, as I have shown above. And then just select the signing profile from the console when you create a job.

2.I am not quite sure what kind of file should be provided for the S3 URL. Should it be the update package for the OTA? When I tried to select my update package out.pac, it didn’t appear as an option.

You should select out.pac. I can see in the screenshot that it's not selectable. That's not because of the file extension. I think you perhaps have a permission problem. In the IAM permissions for your user or role, or perhaps the bucket policy.

3.Is the 'Path name of file on device' the path where the OTA file will be automatically stored on my device after the update?

The path is just a text string that will be sent in the job document. In your device firmware, you can use that as you see fit. Or ignore it. It all depends on how your firmware is implemented.

See Figure 1 in this article to better understand the job document: https://repost.aws/articles/ARDHNhV0bnRGau0kmdhTSZZA/comparing-aws-iot-jobs-and-aws-iot-over-the-air-ota-updates

4.I would like to understand what kind of file is sent to my device when this FreeRTOS OTA job is executed. What is the process of how this FreeRTOS OTA job delivers the OTA update to the device?

The job document (JSON file) is sent to your device over MQTT, on the job topics. Then your device firmware gets the presigned URL out of the job document, and downloads the .pac object from the S3 bucket using HTTP. Then your firmware writes that into memory (device implementation detail), and reboots into the next image. More information here: https://www.freertos.org/Documentation/03-Libraries/07-Modular-over-the-air-updates/01-Over-the-air-updates. And here: https://docs.aws.amazon.com/iot/latest/developerguide/jobs-workflow-device-online.html

AWS
EXPERT
answered 9 months ago
EXPERT
reviewed 8 months ago
  • Hello, is there a way where I can simply upload the upgrade package to an AWS S3 bucket, generate a pre-signed URL, and have my device connect to download it? In this case, AWS would only be used to store the firmware.

  • Hello, above are the updated issues I encountered while operating FreeRTOS OTA. How can I send you the Quectel documentation?

  • is there a way where I can simply upload the upgrade package to an AWS S3 bucket, generate a pre-signed URL, and have my device connect to download it?

    Yes, you can certainly do that. You just need a way to trigger the generation of the presigned URL, and send that presigned URL to your device. You can build something custom to do that, but AWS IoT jobs (including FreeRTOS OTA with HTTP file transfer) already does that for you. As well as manages the state.

  • How can I send you the Quectel documentation?

    Please just add a link as a comment, or tell me the particular document name. I have a Quectel account already.

  • I've updated the answer to address your edited question. If you have small additional questions, please add here in comments. If you have bigger follow-up questions, please post a new question, rather than edit the existing question.

0

I apologize, but I don't have specific information about performing OTA updates for the Quectel module QuecOpen EG912U using FreeRTOS OTA through the AWS console GUI. The sources provided don't contain details about this specific module or its requirements.

However, I can provide some general guidance based on the FreeRTOS OTA update process:

  1. Typically, when you upload a firmware image to an S3 bucket as part of the OTA update process, you don't directly use the S3 URL. Instead, you select the firmware image from the S3 bucket within the AWS IoT console when creating the OTA update job. The AWS IoT service then handles the delivery of the firmware to your devices.

  2. Regarding the .pac file format, FreeRTOS OTA doesn't have specific requirements for file extensions. However, if the console doesn't accept this file type, you may need to consult Quectel's documentation or support for guidance on how to prepare the firmware package for OTA updates through AWS IoT.

  3. For the code signing configuration, FreeRTOS OTA typically requires you to select a hardware platform. If you're unable to find a matching platform for your Quectel module, you may need to check if your device is qualified for FreeRTOS OTA or if you need to implement a custom OTA agent.

Given these challenges, it might be beneficial to consult with Quectel's support or documentation to see if they provide specific instructions for performing OTA updates on the EG912U module using AWS IoT services. They may have particular requirements or procedures that differ from the standard FreeRTOS OTA process.
Sources
OTA tutorial - FreeRTOS
OTA tutorial - FreeRTOS

answered 9 months ago
  • What should I do to implement a custom OTA agent

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.