Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

esp_rmaker_param_update_and_report & esp_rmaker_set_params_callback conflict (MEGH-6004) #332

Open
3 tasks done
Roydudu opened this issue Sep 25, 2024 · 1 comment
Open
3 tasks done

Comments

@Roydudu
Copy link

Roydudu commented Sep 25, 2024

Answers checklist.

  • I have read the Rainmaker documentation and the issue is not addressed there.
  • I have updated my IDF branch (release/vX.Y) to the latest version and checked that the issue is present there. This is not applicable if you are using Rainmaker with Arduino.
  • I have searched the Rainmaker forum and issue tracker for a similar issue and not found a similar issue.

General issue report

Both functions use "esp_rmaker_report_param_internal." Could there be a conflict with the buffer where the parameters are written to report? For example, an MQTT message arrives, triggering "esp_rmaker_set_params_callback." While writing to the "s_node_params_buf" buffer, the main app is unlocked by some event and calls "esp_rmaker_param_update_and_report." Should there be some kind of semaphore?

@github-actions github-actions bot changed the title esp_rmaker_param_update_and_report & esp_rmaker_set_params_callback conflict esp_rmaker_param_update_and_report & esp_rmaker_set_params_callback conflict (MEGH-6004) Sep 25, 2024
@shahpiyushv
Copy link
Collaborator

Thanks for reporting the issue. Earlier, all reporting was happening only in the context of the work queue task and so this was not an issue. But the subsequent restructuring of work queue (which too happened quite some time ago) has made this indeed a possibility. We will add a fix soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants