Smart Bluetooth Forum Discussions
Hello,
I read through the blog posts about how to program the BD Address, and the methods mentioned are more difficult and risky than they should be. On ChipLoad, please add a command line option to write in a specified BD Address. It would be desirable to also have an option to have ChipLoad generate a random number (with 2 most significant bits being 11) and write that instead. Both options are useful.
Including it as a command line argument makes it easier for automating this process during production.
Show LessSo if I have a characteristic that only has read permissions, does that mean it can't be changed at all or that only a device connected to the peripheral can't change it?
Show LessI tested the ota_firmware_upgrade on the BCM920737TAG Board.
I flashed the application to the controller, then I added a trace-message and created the application again.
I tried the Update on android (with a update-application I found on the forum here) and on a virtual machine with windows 8 and the application provided with the ota_firmware_upgrade.
It seems, the file is sent ok, the CRC at the end are OK.
This is what I get:
Command:3 State:2
ws_verify rcvd:3c2de77d calculated:3c2de77d
send_status 0
hello_sensor_timeout:421
@$*#04FF0EF7009201010000E5750402FF0000ws_upgrade_create_upgrade_ss()...
done
ws_upgrade_invalidate_active_ss()
done
bleapputil_cpuIntDisable()
bleappfwu_watchdogExpired(0
But the controller won't boot again. Each time I have to recover it. I also added the crystal warmup workaround.
My SDK-Version is 2.2.1.
So I need some hints what else I could do.
Show LessAfter calling bleprofile_Init(bleprofile_p_cfg) in create function, current consumption looks higher.
So I added bleprofile_InitPowersave() and bleprofile_StartPowersave() end of the function.
Then the power consumption becomes lower.
Is this correct usage?
Show LessHi dmiya
Just came across this post: Does I2C write have length limitation? (How about size > 16B) - Con't
It seems the documentation is quite confusing.
For "datasheet of BCM20737", are you referring to this document? WICED™ Smart Hardware Interfaces
1. In this doc, it says "maximum transaction length of 16 bytes." But the comment of function "cfa_bsc_OpExtended" says "the size of the address plus the size of the data must be <= 8". Could you confirm it's 8 or 16?
2. Is maximum transaction length referring to (bufCount + addrCount)?
CFA_BSC_STATUS cfa_bsc_OpExtended(UINT8* buf,
UINT16 bufCount,
UINT8* addr,
UINT8 addrCount,
UINT8 slaveAdr,
UINT8 operation);
ps. one comment of function "cfa_bsc_OpExtended" is "
both addressed and unaddressed
// The amount of data read/written can (not?) exceed 8", which I guess it's a typo?
Show LessHello, I tried to connect two devices with encryption and the slave sends "LL_Reject_Ind ErrorCode 6" to the master. Any idea what might cause the error? I compared my codes to hello_client and hello_sensor and all the security related functions are called within the "connection_up" function, including lesmp_sendSecurityRequest and lesmp_startPairing. I am not sure what else I could miss. Thank you.
Show LessWe have issues installing the SDK2.2 on a Windows XP Pro machine.
Following the documentation here (page 10): http://community.broadcom.com/servlet/JiveServlet/previewBody/1016-102-3-1031/MMPWICED-QSG203-R.pdf I would expect to be able to install on this type of OS no problem.
The installation fails with a pop-up see attached.
What could be the problem?
Hi
I am trying to install WICED-Smart-SDK-2.2.1-IDE-Installer in my windows XP but it fails. Is there any other version of SDK-IDE that works on windows XP?
Ras
Show LessHi,
I am trying to set up the peripheral to continue sending advertisements after it is connected to a central. I would like other centrals to know that the peripheral is around but currently connected to another central. (I'm also planning to change the advertisement data slightly to reflect when this peripheral expects to be done with its current connection).
However, I'm unable to get the peripheral to advertize in such a way that it doesn't accept a second connection. I essentially want BLE 4.0 behavior, not BLE 4.1 behavior. That is, only one connection from a peripheral to a central. Here is what I've tried:
void app_connection_up(void)
{
// Other code snipped
blecm_setAdvDuringConnEnable( TRUE );
blecm_disableConMux(); // If I take this line out, there is no difference in behavior
blecm_enablescatternet(); // If I take this line out, it doesn't advertise after the connection is up
bleprofile_Discoverable( LOW_UNDIRECTED_DISCOVERABLE, 0x00 );
}
However, I either able to:
(a) Advertise after connecting, but then it will connect to other centrals too
(b) Not advertise after connecting at all (if I take the enablescatternet() call out).
I'm developing on OS X with SDK version 2.2.0 (still waiting for 2.2.1 on OS X).
Any pointers on what I can do to get the desired behavior? Greatly appreciate any assistance!
Regards,
Arvind
Show LessHi, I have a question about how to setup RX FIFO depth.
From SDK examples, I followed same setup for RX FIFO.for puart in my application see my capture below.
// BEGIN - puart interrupt
// The following lines enable interrupt when one (or more) bytes
// are received over the peripheral uart interface. This is optional.
// In the absense of this, the app is expected to poll the peripheral
// uart to pull out received bytes.
// clear interrupt
P_UART_INT_CLEAR(P_UART_ISR_RX_AFF_MASK);
// set watermark to 1 byte - will interrupt on every byte received.
P_UART_WATER_MARK_RX_LEVEL(1);
// enable UART interrupt in the Main Interrupt Controller and RX Almost Full in the UART
// Interrupt Controller
P_UART_INT_ENABLE |= P_UART_ISR_RX_AFF_MASK;
// Set callback function to app callback function.
//puart_rxCb = puart_control_rx_callback;
puart_rxCb = PUartRxCallback;
// also register a listener from the caller if callback is valid
if (callback)
onReceiveCB = callback;
// Enable the CPU level interrupt
puart_enableInterrupt();
From the above logics, the RX will be interrupted per byte received, which is correct behavior,but upon Rx interrupt callback, I observed in every case in my application, 1st interrupt callback found fifo is empty after 1 byte is received, and then the subsequent interrupt callback can fetch all characters in one pass until Rx FIFO is empty.
This looks to me strange, why not simply fetch all bytes until RX FIFO is empty in just one interrupt call back call?
To handle this behaviour, I need to save out received bytes to a global rx buffer and keep track for next buffer save location until either the rx buffer is full or upon a delimiter is received to signal response is valid. though with this logic my application can fetch all rx data I needed, but can I do it a simpler way to set the correct RX FIFO so I can do just in one pass to load my global rx buffer instead of segment it into consecutive saving until valid response is met?
See my workaround capture
// Application thread context uart interrupt handler.
// unused - Unused parameter.
void PUartRxCallback(void* unused) {
// save received characters
UINT32 number_of_received_bytes;
char *pBuf;
BOOL bResp = FALSE;
if (BleAppConfig.Size < CFG_CMD_BUFSZ)
{
// Set receive buffer pointer to next save location
pBuf = (char *)BleAppConfig.StrBuf + BleAppConfig.Size;
number_of_received_bytes = PUartReceiveBytes(pBuf, CFG_CMD_BUFSZ-BleAppConfig.Size);
ble_trace1("PUartRxCallback >> number_of_bytes_read: %d\r\n", number_of_received_bytes);
ble_tracen((char *)BleAppConfig.StrBuf, number_of_received_bytes);
if (number_of_received_bytes)
{
BleAppConfig.Size += number_of_received_bytes;
if (BleAppConfig.Size >= CFG_CMD_BUFSZ)
{
BleAppConfig.Size = CFG_CMD_BUFSZ;
bResp = TRUE;
}
else
{
UINT8 i;
for (i=0; i<BleAppConfig.Size; i++)
{
if (BleAppConfig.StrBuf == '\n')
{
bResp = TRUE;
break;
}
}
}
if (bResp)
{
onReceiveCB(BleAppConfig.StrBuf, BleAppConfig.Size);
}
}
}
else
{
// reset receive buffer and size
BleAppConfig.Size = 0;
memset(BleAppConfig.StrBuf, 0, sizeof(BleAppConfig.StrBuf));
}
// clear the interrupt
P_UART_INT_CLEAR(P_UART_ISR_RX_AFF_MASK);
// enable UART interrupt in the Main Interrupt Controller and RX Almost Full in the UART Interrupt Controller
P_UART_INT_ENABLE |= P_UART_ISR_RX_AFF_MASK;
}
// Attempts to receive data from the peripheral uart.
// buffer - The buffer into which to read bytes.
// length - The number of bytes to read.
// Return The actual number of bytes read.
UINT32 PUartReceiveBytes(UINT8* buffer, UINT32 length) {
UINT32 number_of_received_bytes = 0;
// Need to receive at least 1 byte.
if(!buffer || !length)
return 0;
// Try to receive length bytes
while(length--)
{
if(!puart_read(buffer++)) {
// If the FIFO is empty, break out, no more bytes are available.
break;
}
number_of_received_bytes++;
}
// Return the actual number of bytes read.
return number_of_received_bytes;
}
Any suggestions?
Show Less