Wi-Fi Combo Forum Discussions
The problem I encountered in this thread, rfcomm cant reopen, seemed to have been fixed in 3.7. I'm not able to reproduce that exact problem, but a very similar one can be reproduced by lowering the clock speed to very low frequencies, like 12MHz.
When I do that, and open an rfcomm connection, I very often get problems locking mutexes from the BTU, READ_THREAD and HCISU threads. If I log all mutexes locked/unlocked from those threads, I can see that one of the threads pretty often forgets to unlock a mutex. It's not just a matter of several threads competing about the same mutex, one thread really forgets to unlock it, because I can see in the log that a thread locks it, then doesn't execute for a while, and during that time another thread fails to lock it, and after that the first thread locks it again (which it of course shouldn't need to do since it already had the mutex locked.)
Also, it's not just one thread forgetting to unlock it, it can be either one of those 3.
This is why I really try to avoid closed source software. It's impossible to fix problems you encounter, the only thing I can do is half-working workarounds, in this case, instead of using a xSemaphoreTake waiting FOREVER (in wiced_rtos.c wiced_rtos_lock_mutex), I use a 1 second timeout and simply pretend to have locked it if it times out. By doing that, the thread thinks it has locked it and can unlock it as usual when it's done. Of course it's a bit dangerous, but it's the best I can do without the source.
Please fix it on your end proper. If you *really* want to, I might be able to debug which function is locking the mutex and then forgets to unlock it.
Show LessI have a BCM943364WCD1 Eval board which I'm trying to flash the mfg test FW on. My expectation is to see the label "(WLTEST)" when querying for the driver version through the wl application.
I have downloaded the WICED 3.7.0 SDK, and the "make" command I used to try to get the FW on there is "make test.mfg_test-BCM943364WCD1-ThreadX-NetX_Duo-SDIO". After this I navigate via the cmd line to where the wl applications are located and I start sending commands with the application wl43364A1.
Right now, when I send the command to get the driver version, I get the following response:
...> wl43364A1.exe --serial 6 ver
7.45 RC41.0
wl0: Jun 16 2015 11:58:55 version 7.45.41 (r554772) FWID 01-f160f50b
I expect to see in the response the label "(WLTEST)" to indicate that this is the proper manufacturing version. How do I achieve this? Is there a different make command I must use, or a different wl application?
Show LessHello All,
We are working the MQTT and use the wiced SDK 3.5.2.
Use QOS 0;
In our scenario we Publish the packet from the android application. In this case when we publish the packet at fix interval (1 sec 2 packet) MQTT subscribe work fine and it subscribe all packet successfully.
While we publish packet fast (1sec 3 packet) so MQTT subscribe blocked. and not do further functionality.
So what an issue didn't find...so have you any idea so please help us.
I have another doubt:
1> how much packet publish and subscribe in 1 sec ? (use QOS 0)
2> If we send multiple packet at same time..is it possible ?
3> how we can increase speed of the subscribe and publish ?
Need help to solve an issue...
Thanks & regards
Chintan Patel
Show Lessstatic wiced_result_t wiced_dct_load( const image_location_t* dct_location )
{
elf_header_t header;
elf_program_header_t prog_header;
uint32_t size;
uint32_t offset;
uint32_t dest_loc = PLATFORM_DCT_COPY1_START_ADDRESS;
uint8_t buff[64];
/* Erase the application area */
wiced_dct_erase_non_current_dct( dest_loc );
/* Read the image header */
if (wiced_apps_read( dct_location, (uint8_t*) &header, 0, sizeof( header ) ) != 0)
{
return WICED_ERROR;
}
if ( header.program_header_entry_count != 1 )
{
return WICED_ERROR;
}
if (wiced_apps_read( dct_location, (uint8_t*) &prog_header, header.program_header_offset, sizeof( prog_header ) ) != 0)
{
return WICED_ERROR;
}
size = prog_header.data_size_in_file;
offset = prog_header.data_offset;
while ( size > 0 )
{
uint32_t write_size = MIN(sizeof(buff), size);
//if (wiced_apps_read( dct_location, buff, offset, write_size) != 0) {
if (wiced_apps_read( dct_location, buff, offset, write_size) == 0)//Darius - if read ok, so need write
{
if ( platform_write_flash_chunk(dest_loc, buff, write_size ) != 0)
{
return WICED_ERROR;
}
}
offset += write_size;
dest_loc += write_size;
size -= write_size;
}
return WICED_SUCCESS;
}
Show LessIn file sflash_write.c need comment out at end of file, because only first time working, at second time spi deinited (don't tuch in 3.7.0)
............
back_to_idle:
//deinit_sflash( &sflash_handle); darius her problem in 3.5.2
data_transfer.command = MFG_SPI_FLASH_COMMAND_NONE;
Show LessProblem:
Wiced with freertos working incorectly, because using counting semaphore.
Quick way to resolve in fuction hostinitsemaphore create mutex with xCreateSemaphoreBinary.
And need remove 2 assert in hostsetsemaphore and it must allways return true.
Example problem:
1. Uart init semaphore and enable interupt
2. Interupt occurs - counting semaphore increase self value to 1
3. UartReceive fuction getsemaphore for waiting data - semaphore decrease it value to 0 but not block. Uart receive 0 bytes or not full pscket..
4. Goto 2 point....
After correction:
1. Uart init semaphore and enable interupt
2. Interupt occurs - unlock semaphore
3. UartReceive fuction getsemaphore (lock) for waiting data in block mode.
4. Interupt fullrx occurs setsemaphore (unlock) task in 3 point receive full packet.
Similar scenarious can occurs anywhere.
Show Lesshi,
i want to wifi config with bluetooth. For this, Is the app available? or should i add btstack in to my wiced application?
how do i.
finally, no example bluemix in WICED-SDK-3.7.0. Where can I find this example?
Show Lessbasically my application is multi threaded and i'm creating multiple communication points.
but at a time i can create only one
there some api list which i'm using
wiced_result_t wiced_tcp_enable_tls( wiced_tcp_socket_t* socket, void* context );
wiced_result_t wiced_tcp_create_socket( wiced_tcp_socket_t* socket, wiced_interface_t interface ); |
wiced_result_t wiced_tcp_connect( wiced_tcp_socket_t* socket, const wiced_ip_address_t* address, uint16_t port, uint32_t timeout_ms ); |
wiced_result_t wiced_tcp_disconnect( wiced_tcp_socket_t* socket );
wiced_result_t wiced_tcp_delete_socket( wiced_tcp_socket_t* socket ); ....
Show Less