-
Notifications
You must be signed in to change notification settings - Fork 739
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
Cannot send message to cloud if in callback of message received #597
Comments
This should work. I know for MQTT and in IoT Edge, a common scenario is we get sending messages inside a callback. However for this case we use Also I see you're doing Finally if this doesn't help, more logs might. Something like bool traceOn = true;
(void)IoTHubClient_SetOption(iothub_handle, OPTION_LOG_TRACE, &traceOn); |
Well actually it is called all the time since it is in Also I forgot mentioning that if I call the |
Hi @jcagme , Calling any Azure IoT C SDK function from the LL module from one of its callbacks is not supported in a multi-threaded scenario unless your provide the appropriate locks around the internal queues. The convenience layer (threaded, non LL module) does that for you and supports calling any function from within the callbacks, but I believe it wouldn't be applicable to your arduino project. So long story short, this behavior is by design. |
@jcagme , |
@jcagme, thank you for your contribution to our open-sourced project! Please help us improve by filling out this 2-minute customer satisfaction survey |
I think this related to: #26 which has been closed for a while so:
I'm on macOS High Sierra 10.13.6 using the AzureIotHub libraries version 1.0.44 for Arduino.
If I try to send a message to the cloud in the callback of the message received it is not sent at all.
Here is a snippet of my code:
Any suggestions?
The text was updated successfully, but these errors were encountered: