Studio Bluetooth Forum Discussions
I have faced MIC(Message Integrity Check) error for LE connection. I can see same issue on following link, could you help how to resolve?
For more information, please refer to the following.
https://community.infineon.com/t5/Studio-Bluetooth/Bug-report-Connection-Terminated-Due-to-MIC-Failure-0x3d-WICED-6/td-p/245462
https://community.infineon.com/t5/Studio-Bluetooth/Bug-report-BLE-cant-reconnect-to-a-bonded-device/m-p/35458#M163
1. Test environment
1) H/W
- Local H/W : CYW920706WCDEVAL
- Peer device :
> LG Stylus2
>> Android version 7.0
>> BR/EDR public BD address : DO:13:FD:50:F8:C8
> HUAWEL P9 lite. (Model number : HUAWEL VNS-L22)
>> Android version 7.0
2) S/W
- SDK : ModusToolBox 2.3 and LE_Hello_sensor application
- SDK LIB : Wiced_btsdk baselib release v3.0.0
- Peer Apps : LightBlue, local developed BLE application.
2. Test procedure
- Step 1. Hello_sensor build & download
- Step 2. Pairing with android phone.
- Step 3. Connection success.
- Step 4. Remote disconnect after pairing success.
- Step 5. Start connection from andoid phone.
- Step 6. Link connection fail due to MIC error. (error code 0x3d)
3. Test Results
- I tested other BLE peripheral with two android phones and it works well. (No MIC error)
- CYW920706WCDEVAL works fine with iphone, and other many android phone.
- HCI fail : HCI_Encryption_Change event status code 0x3d. (mic error)
5. attached log file.
- mic_error_app_log.txt : application log with MIC error.
- mic_error_btspy.txt : MIC error with CYW920706WCDEVAL and LG android phone.
- no_mic_with_iphone.txt : No MIC error with CYW920706WCDEVAL and iphone.
Thanks.
Show LessHi,
While looking for topics and knowledge database to use the CYBT-343151-02 bluetooth module, I found various entries :
* The knowledge database KBA225450 indicate a procedure to start the CYW2070*-A2 based devices (and list the one I'm using) in HCI mode, where all Bluetooth HCI standard commands are available. The interesting part is the SPI2_MOSI signal which must be setup correctly to 'force' the HCI mode when the device has an embedded firmware (which is the case for the CYBT-343151-02 module which is factory programmed with the EZ-Serial firmware).
* This blog article (https://community.infineon.com/t5/Resource-Library/Run-CYW20706-in-HCI-Mode/ta-p/246397) also gives a method to enter HCI mode on the same chipset, but the method is different (this time, the UART CTS pin must be pulled to HIGH during power up to enable HCI mode).
* This topic (https://community.infineon.com/t5/Studio-Bluetooth/CYBT-333047-02-via-HCI-interface-on-Raspberry-Pi/td-p/124669) seems to confirm my observations that I will try to describe bellow.
All tests bellow have been done on a CYBT-343026-EVAL board where the chipset has been replaced with the CYBT-343151-02.
* TEST 1 : With stock firmware (EZ-Serial), the device will most of the time not accept HCI commands (we still have a setup where it seems to work but depends on timings).
* TEST 2 : With stock firmware and CTS pulled high (as per blog article), the behavior is almost the same as with the firmware running (I've observed that the HCI UART RTS stays high after a few seconds, therefore the configuration of the module via HCI H4 is stopped)
* TEST 3: With the stock firmware and only SPI2_MOSI pulled to ground during boot, then the HCI reset command is accepted (using cybluetool), other commands are not acknowledged. Seems like this is the download mode described in the datasheet of the module, the airoc hci protocl manual and the CYW20706 datasheet).
* TEST 4: With the stock firmware, CTS set HIGH and SPI2_MOSI set LOW during power-on (press the recovery button while plugging the USB cable), then all HCI commands are accepted (in the limit of the chipset HCI supported commands). I can do almost all configuration, but the device is not discoverable nor can detect other device (even after using the 'enable radio' vendor command in cybluetootl).
* TEST 5: Same procedure as TEST4, with bluez hciattach/hcitool utilities (to workaround the problem described in the third listed entries at the top of this topic, I've just send a HCI reset command to the module using cybluetool before running the hciattach command, because a hcidump told me that the module was not accepting the commands, and during the numerous tests that I did, I saw that this was due to a missing HCI reset command). This test ends in the same way as the TEST 4, event after sending the radio enable command, I can't detect other devices and the device can't be discovered.
* TEST 6: Using the empty_wiced_bt example from the ModusToolbox software, the HCI interface works (using cybluetool to enable scan, and radio, or using the bluez tools). I can discover the device, do an inquiry
Questions are :
* Why do the device need a firmware to run to make the bluetooth really work ? Is it related to the patched that the firmware embeds (and which might configure the radio properly, which is not the case when the firmware is bypassed using the SPI2_MOSI / CTS pin forced levels) ?
* Can you confirm that the ROM code needs both SPI2_MOSI and CTS pins to be forced to specific levels to boot in HCI mode (or tell me why this is needed, if it is not related to the CYW20706 ROM) ?
* Is there any way to make the module work using HCI commands and the stock EZ-Serial firmware ?
Regards, Jerome
Show LessWe have a device using CYBT-343026 module with EZ-Serial Firmware. During initialization the application calls gap_get_device_name to set some application specific name. Using a typical Android BLT scanner/pairing app the device appears in the scan list with the device name that was set by the application. When an attempt is made to pair with the device the name shown in any pairing pop-up boxes is of the form "EZ-Serial E8:B9:12_BT" rather than the device name.
Is there a way to get the pairing operation to use the device name rather the default "EZ-Serial..."?
Show LessHello,
I have questions about operation of HID Device.
I tried to test with two of laptops, it is different to operate on HID connection each laptops.
The SW information and test process are as below.
SW Information
- Chipset & EVK : CYW20706 & F1DC2076 EVB (made in F1media)
- WICED SDK version : WCIED 6.2.1
- Test application : HID Device
Test Process
- Connect from Windows PC to F1DC2706(CYW20706)
- Send the HID data.
- Result
#1) it seems that enter to sniff mode normally
Notebook (LG - 15U560)
- manufacturer : Intel Corporation
- F/W version : HCI 8.4096 / LMP 8.4096
- Driver provider : Intel Corporation
- Driver date : 2017-04-07
- Driver version : 19.60.0.3
#2) it seems that enter to sniff mode, but its connect/disconnect to SDP and RFCOMM repeatly,
and also enter/exit sniff mode repeatly by connect/disconnect.
Notebook (LG –15ZD980-GX50K)
- Manufacturer : Intel Corporation
- F/W version : HCI 8.256 / LMP 8.256
- Driver provider : Intel Corporation
- Driver date : 2017-05-04
- Driver version : 20.60.0.4
Snoop Log
- refer to attatched files. its name is written name of laptop.
Why is the different each for laptops? Does it problem of compability?
Or, am i missed anything that need to set?
I want to know why is the different to operate on HID connection.
Please, could you help me anybody who know?
Show Less
Hello infineon community,
I am contacting you because we are not able to program the CYBT343026-01 that is used on our prototype,
The configuration is :
1. Hardware:
we are using the HCI interface of an CYBT-343026-EVAL board, switch are configured to low (if we consider the position given in the screen below) and wires have been soldered to connect eval board to our prototype.
Detail of CYBT343026-01 connection on PROTOTYPE :
uarts, "Reset" and "Recover" pin are connected to a microcontroller that is setting the connected pin to high impedance during flash.
2. Software:
Before starting programming the sequence given below is realized:
“Press and hold the 'Recover' button on the kit.
Press and hold the 'Reset' button on the kit.
Release the 'Reset' button.
After one second, release the 'Recover' button.”
Then ChipLoader programming tool is used to program the CYBT and the result is given below :
C:\Cypress\Wiced_Smart_SDK\WICED-Smart-SDK\Tools\ChipLoad\Win32>ChipLoad.exe -BLUETOOLMODE -PORT COM5 -NOVERIFY -MINIDRIVER C:\Cypress\Wiced_Smart_SDK\WICED-Smart-SDK\Tools\ChipLoad\Win32\minidriver.hex -BTP C:\Cypress\Wiced_Smart_SDK\WICED-Smart-SDK\Tools\ChipLoad\Win32\CYP_TCV4.btp -CONFIG C:\Cypress\Wiced_Smart_SDK\WICED-Smart-SDK\Tools\ChipLoad\Win32\CYP_TCV4_download.hex
Download minidriver successfully had written 249 bytes to address 0x000D0200
Download minidriver successfully had written 249 bytes to address 0x000D02F9
Download minidriver successfully had written 249 bytes to address 0x000D03F2
Download minidriver successfully had written 249 bytes to address 0x000D04EB
Download minidriver successfully had written 249 bytes to address 0x000D05E4
Download minidriver successfully had written 249 bytes to address 0x000D06DD
Download minidriver successfully had written 249 bytes to address 0x000D07D6
Download minidriver successfully had written 249 bytes to address 0x000D08CF
Download minidriver successfully had written 249 bytes to address 0x000D09C8
Download minidriver successfully had written 249 bytes to address 0x000D0AC1
Download minidriver successfully had written 249 bytes to address 0x000D0BBA
Download minidriver successfully had written 249 bytes to address 0x000D0CB3
Download minidriver successfully had written 249 bytes to address 0x000D0DAC
Download minidriver successfully had written 249 bytes to address 0x000D0EA5
Download minidriver successfully had written 249 bytes to address 0x000D0F9E
Download minidriver successfully had written 249 bytes to address 0x000D1097
Download minidriver successfully had written 249 bytes to address 0x000D1190
Download minidriver successfully had written 249 bytes to address 0x000D1289
Download minidriver successfully had written 249 bytes to address 0x000D1382
Download minidriver successfully had written 249 bytes to address 0x000D147B
Download minidriver successfully had written 249 bytes to address 0x000D1574
Download minidriver successfully had written 249 bytes to address 0x000D166D
Download minidriver successfully had written 249 bytes to address 0x000D1766
Download minidriver successfully had written 249 bytes to address 0x000D185F
Download minidriver successfully had written 249 bytes to address 0x000D1958
Download minidriver successfully had written 249 bytes to address 0x000D1A51
Download minidriver successfully had written 249 bytes to address 0x000D1B4A
Download minidriver successfully had written 249 bytes to address 0x000D1C43
Download minidriver successfully had written 249 bytes to address 0x000D1D3C
Download minidriver successfully had written 249 bytes to address 0x000D1E35
Download minidriver successfully had written 249 bytes to address 0x000D1F2E
Download minidriver successfully had written 249 bytes to address 0x000D2027
Download minidriver successfully had written 249 bytes to address 0x000D2120
Download minidriver successfully had written 249 bytes to address 0x000D2219
Download minidriver successfully had written 249 bytes to address 0x000D2312
Download minidriver successfully had written 237 bytes to address 0x000D240B
Launch minidriver at 0x000D0200 succeeded
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Executing -- erasing chip
Downloaded 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Verified 0 code bytes ( 0.0%) and 0 data bytes ( 0.0%). Current state: Terminated with error
Chip erase timeout (nLastProgressReportTime)
Any solution would be really appreciated 😄
Regards
Show Less@Hello.
I review CYW20706 and found that I cannot use i2c and PUART flow control. because puart flow control shares i2c.
Or can you tell me how I can configure it?
I am using a RS232 FTDI adapter to download a hello_sensor_app through the HCI interface. The communication goes fine and the minidriver is launched OK but the log file shows the module memory has a mistmatch in the bytes writen and read.
I append here the last lines of the log:
A total of 2 contiguous memory areas were filled:
[FF000000..FF000027] DATA (40 bytes)
[FF003000..FF01419B] DATA (70044 bytes)
Download config error trying to verify 40 bytes at address 0xFF000000 (SOURCE: CONFIG Configuration data build/hello_sensor-CYBT_343026_EVAL-rom-ram-Wiced-release/hello_sensor-CYBT_343026_EVAL-rom-ram-Wiced-release.hex) (Data mismatch at address 0xFF000000. Expected byte value 0x01 but device contains 0x66)
Please, help.
Thanks,
Show LessI want to wire a CYBT-353027-EVAL to the CODEC MAX 98090 via I2S running the Headset Demo Application.
Try #1: CYBT-353027 is I2S Master
I programmed the Headset app into the BT module and paired it to a cell phone. I wired the I2S to the MAX 98090 Eval Board. I started a music player on the phone. As a consequence, I can hear music in the earphones connected to the MAX 98090. I can also see that there is an I2S BCLK, I2S LRCLK and I2S Data going on using a Logic Analyzer. The LRCLK rate is 48 kHz.
I ended the music player app on the phone an initiated a phone call to another cell phone. The I2S BCLK and I2S LRCLK changed. The LRCLK is now running on 16 kHz. However, there is *nothing* to be seen on the SDIN and SDOUT lines. I disconnected the SDIN and SDOUT lines and, funny enough, there is a signal on the SDOUT line at least.
I assumed, it is pulled to low by the MAX 98090 CODEC.
So I decided to change the roles and make the CODEC the I2S master and the BT module the slave.
Try #2: MAX 98090 is I2S Master
I changed the source code to make the Headset Demo app configure the BT module as I2S Slave and set up the MAX 98090 as I2S master, running the LRCLK at 16 kHz with BCLK set to 64 x fs and an MCLK of 12 MHz.
I checked with the music player app on the phone - it works (although the sound is too loud and clipped).
I tried to make a phone call and again - nothing is on SDIN and SDOUT.
Question: Does this even work?
Which CODEC is recommended to use with the CYBT-353027 to get the I2S working in a bidirectional manner?
Show LessHi,
我想把hci_audio_gateway demo里的hci_ag_cfg_settings里的ble_scan_cfg.high_duty_scan_duration=0设置成永远都在high scan,但是测试下来以后,好像scan了一轮后就不scan了。如下是我的的配置。请帮我确认一下
In our existing project we use CYBT-353027-02 module and WICED Studio 6.4. The CYBT module is running in embedded mode. The module is connected to a host CPU via UART. CYBT firmware update is done via UART, using correspondent minidriver.
Question: after loading minidriver to RAM we execute HCI_FLASH_ERASE command (0x01, 0xCE, 0xFF, 0x04, 0x00, 0x00, 0x00, 0xFF). Is it really necessary? Our goal is to keep application data in CYBT untouched after firmware upgrade, i.e. to keep link keys, BT MAC address and so on. Is it possible?
Show Less