You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 22, 2022. It is now read-only.
I am trying to use device twin functions (and direct methods) from the SDK, namely, IoTHubDeviceTwin_CreateXXX macros.
But when I compile my code, it said,
libraries\AzureIoTHub\sdk\iothub_client.c.o: In function `iothub_ll_device_twin_callback':
C:\Users\JohnDoe\Documents\Arduino\libraries\AzureIoTHub\src\sdk/iothub_client.c:1336: undefined reference to `Lock'
C:\Users\JohnDoe\Documents\Arduino\libraries\AzureIoTHub\src\sdk/iothub_client.c:1336: undefined reference to `Unlock'
C:\Users\JohnDoe\Documents\Arduino\libraries\AzureIoTHub\src\sdk/iothub_client.c:1336: undefined reference to `Lock_Deinit'
libraries\AzureIoTHub\sdk\iothub_client.c.o:(.text.garbageCollectorImpl$isra$0+0x48): undefined reference to `Lock'
Searching thru all files under C:\Users\JohnDoe\Documents\Arduino\libraries\AzureIoTUtility, I only see Lock/Unlock/Lock_Deinit declared in src\azure_c_shared_utility\lock.h, but found nothing in *.c files.
The text was updated successfully, but these errors were encountered:
I'm also getting this error. I believe the function definitions should be getting generated by the MOCKABLE_FUNCTION macro, as defined in lock.h (line 50) and umock_c_prod.h (line 30). If you explicitly define the function yourself, you also get a duplicate function definition error...so it would appear the function is there...
From what I've read, the "undefined reference to 'xxx'" error is a linking error rather than a compilation error.... and that's about as far as I have got with this problem.
@tameraw When you say "twin functionality is not supported", do you mean twin functionality overall or just the functionality defined in serializer_devicetwin.h?
I've been trying to send a serialized model similar to below using IoTHubClient_LL_SendReportedState and although the message appears to be accepted by the hub client, the callback gets invoked with a status code of 400. Do you know why this happens?
The Lock family are not relevant to Arduino because it is single-thread only. Make sure you don't use any of the non-LL files (like iothub_client.c ; use iothub_client_ll.c instead) and it'll be okay.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Versions:
I am trying to use device twin functions (and direct methods) from the SDK, namely,
IoTHubDeviceTwin_CreateXXX
macros.But when I compile my code, it said,
Searching thru all files under
C:\Users\JohnDoe\Documents\Arduino\libraries\AzureIoTUtility
, I only seeLock
/Unlock
/Lock_Deinit
declared insrc\azure_c_shared_utility\lock.h
, but found nothing in*.c
files.The text was updated successfully, but these errors were encountered: