- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have an application that needs to work on both ble and wifi.
I am using the ble_proximity_reporter as my main project and wanted to add the wifi "snips" to it.
I was able to add the wifi periodic scan without any problems. I did this by basically copy and pasting the code from scan.c into ble_proximity_reporter.c
However when I try to do the same thing for https_client, I get the following link error :
Bluetooth_Low_Energy_Proximity_Reporter_Application.a(ble_proximity_reporter.o): In function `application_start':
/Applications/WICED/WICED-SDK-3.3.1/apps/snip/bluetooth/ble_proximity_reporter/ble_proximity_reporter.c:191: undefined reference to `wiced_https_get'
make[1]: *** [build/snip_bluetooth_ble_proximity_reporter-BCM943341WCD1/binary/snip_bluetooth_ble_proximity_reporter-BCM943341WCD1.elf] Error 1
I looked through the https_client.mk file and found
$(NAME)_COMPONENTS := protocols/HTTP
So I added that to ble_proximity_reporter.mk
$(NAME)_COMPONENTS := libraries/drivers/bluetooth \
protocols/HTTP
.. but looks like that's just used to find the location of the http.h header file.
I guess I must be missing some library definition, but I can't figure out where.
I see it here WICED-SDK-3.3.1/build/snip_bluetooth_ble_proximity_reporter-BCM943341WCD1
grep wiced_https_get ./libraries/Bluetooth_Low_Energy_Proximity_Reporter_Application.a
Binary file ./libraries/Bluetooth_Low_Energy_Proximity_Reporter_Application.a matches
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Never mind .. I just needed to do a clean before building and that took care of this error.
Sajid
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Sajid,
You should include http.h in the ble_proximity_reporter.c file and it should be able to bring in the definitions.
#include "http.h"
Thanks,
Jaeyoung
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I actually do have http.h included.
Note that the error I am getting seems to be a linker error, not a compiler error.
Bluetooth_Low_Energy_Proximity_Reporter_Application.a is saying it can't find wiced_https_get.
But when I actually go to build/snip_bluetooth_ble_proximity_reporter-BCM943341WCD1/libraries
and grep for wiced_https_get, I see that its in Bluetooth_Low_Energy_Proximity_Reporter_Application.a
grep wiced_https_get ./libraries/Bluetooth_Low_Energy_Proximity_Reporter_Application.a
Binary file ./libraries/Bluetooth_Low_Energy_Proximity_Reporter_Application.a matches
Sajid
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Never mind .. I just needed to do a clean before building and that took care of this error.
Sajid