cancel
Showing results for 
Search instead for 
Did you mean: 

WICED Smart Bluetooth

Anonymous
Not applicable
In hello_sensor.c, it says hello_sensor_interrupt_handler allows for three interrupt inputs where the buttons are defined as..

Button1 : value&0x01

Button2 : (value&0x02)>>1

Button3 : (value&0x04)>>2

When I press SW1 on the TAG board, this registers as Button1. If I were to add more buttons, how would I configure them as Button2 and Button3? I do realize I have to initialize as buttons/inputs/low/interrupt, but I am guessing there is more to it than that.

Thanks
0 Likes
1 Solution
VictorZ_46
Employee
The Tag board which is provided with SDK has only 1 button exposed.  If you can wire GPIO pins, any unused GPIO can be used as buttons 2 or 3.  You will need to modify hello_sensor_gpio_cfg to add the pin number and the flags.  Check the button definition in WICED_Smart_SdkInlcudePlatformsBCM920732TAG_Q32platform.h.  For button 2 flags would look something like that

#define GPIO_SETTINGS_BUTTON2  (GPIO_INPUT  | GPIO_INIT_LOW  | GPIO_BUTTON2 | GPIO_INT)

View solution in original post

20 Replies
VictorZ_46
Employee
The Tag board which is provided with SDK has only 1 button exposed.  If you can wire GPIO pins, any unused GPIO can be used as buttons 2 or 3.  You will need to modify hello_sensor_gpio_cfg to add the pin number and the flags.  Check the button definition in WICED_Smart_SdkInlcudePlatformsBCM920732TAG_Q32platform.h.  For button 2 flags would look something like that

#define GPIO_SETTINGS_BUTTON2  (GPIO_INPUT  | GPIO_INIT_LOW  | GPIO_BUTTON2 | GPIO_INT)

View solution in original post

Anonymous
Not applicable
Thank you! This is exactly what I needed.
0 Likes
Anonymous
Not applicable
So I was tweaking the code, trying to figure out how button interrupts work. And in the middle of tweaking, I realized that the interrupt handler doesnt get called when I push the button. After a day debugging/reverting my code so that itll work again, Ive decided to re-download and re-install the IDE. I enabled trace messages and downloaded the stock hello_sensor.c program onto the tag board and the program still does not seem to run the interrupt handler when I push the button. In my hyperterminal screen, I can see trace messages whenever I connect/read/write from my smartphone, but the button doesnt do anything(interrupt, flash LEDs like before, increment in the characteristic). Im not sure what to do next do be able to use interrupts again.

Do you have any suggestions to remedy this situation?

Thanks.
0 Likes
VictorZ_46
Employee
Unless you broke the button ore rewired something it should work.  Check the Wiced-Smart-SDKIncludePlatformsBCM920732TAG_Q32platform.h.  It should have

#define GPIO_PIN_BUTTON       0

#define GPIO_SETTINGS_BUTTON  (GPIO_INPUT  | GPIO_INIT_LOW  | GPIO_BUTTON | GPIO_INT)

hello_sensor_gpio_cfg to have GPIO_PIN_BUTTON and GPIO_SETTINGS_BUTTON.

And Create function to have

    bleprofile_GPIOInit(bleprofile_gpio_p_cfg);

and

    bleprofile_regIntCb((BLEPROFILE_SINGLE_PARAM_CB) hello_sensor_interrupt_handler);
Anonymous
Not applicable
Thanks for your reply.

I have all the code that you have listed and it still does not work. DOes this suggest an hardware issue?

Thanks
0 Likes
VictorZ_46
Employee
If the same software used to work and does not work anymore, it is probably hardware, although Ive never seen the big white button going bad (hope that is what you are pushing).
0 Likes
Anonymous
Not applicable
Thank you for your reply. It is the big white button I am pressing.

So I decided to probe the switch to see what was going on.

  • SW1 pin4/VDDIO was measured to be 1.812V.
  • SW1 pin 1 was measured to be 1.614V.
  • When I pressdown SW1, the voltage goes to 1.796V.

Is this correct? I do have SW1 configured as GPIO_PIN_BUTTON with GPIO_SETTINGS_BUTTON, which means that it is initialized low as in input at P0.

Thanks.
0 Likes
Anonymous
Not applicable

Hi all, I am new to the forum, I was trying to build a program for the BCM20732. When I choose Build Target in the Make target window, the problem says :

12:44:48 **** Build of configuration blood_pressure_monitor-BCM920732TAG_Q32 for project WICED-Smart-SDK ****

"C:\\Users\\vyin\\Documents\\WICED\\WICED-Smart-SDK-1.1.0\\WICED-Smart-SDK\\make.exe" test

make: *** No rule to make target 'test'.  Stop.

12:44:48 Build Finished (took 317ms)

Anybody knows how to result the issue?

Thanks a lot.

0 Likes
MichaelF_56
Moderator
Moderator

Are you attempting to build/program to a BCM920732 Tag board using the following make file: RAM.hello_sensor-BCM920732TAG_Q32 download

If yes, what if any changes have you made to the example code?

Which Windows based SDK are you using?

I'm using SDK 1.1.0 and am seeing a clean console output based on the provided application code (see below):

13:24:26 **** Build of configuration blood_pressure_monitor-BCM920732TAG_Q32 for project WICED-Smart-SDK ****
"C:\\Users\\mfortner\\Documents\\WICED\\WICED-Smart-SDK-1.1.0\\WICED-Smart-SDK\\make.exe" RAM.hello_sensor-BCM920732TAG_Q32 download
Linking target ELF
OK, made elf.
Writing Hex image
Call to hello_sensor_spar_crt_setup @ 00209641
OK, made C:/Users/mfortner/Documents/WICED/WICED-Smart-SDK-1.1.0/WICED-Smart-SDK/Wiced-Smart/spar/../../build/hello_sensor-BCM920732TAG_Q32-rom-ram-Wiced-release/A_20732A0-hello_sensor-rom-ram-spar.full.hex.

OK, made C:/Users/mfortner/Documents/WICED/WICED-Smart-SDK-1.1.0/WICED-Smart-SDK/Wiced-Smart/spar/../../build/hello_sensor-BCM920732TAG_Q32-rom-ram-Wiced-release/A_20732A0-hello_sensor-rom-ram-spar.cgs. MD5 sum is:
51eeb6b9e0d41f8ea7731d50350188ab *../../build/hello_sensor-BCM920732TAG_Q32-rom-ram-Wiced-release/A_20732A0-hello_sensor-rom-ram-spar.cgs

--------------------------------------------------------------------------------
Patches start at                  0x00205918 (RAM address)
Patches end at                    0x00208B1C (RAM address)
Application starts at             0x00208A08 (RAM address)
Application ends at               0x0020963D (RAM address)

Patch size (including reused RAM)      12804 bytes
Patch size                             12528 bytes
Application size                        3125 bytes
                                      ------
Total RAM footprint                    15653 bytes (15.3kiB)

Converting CGS to HEX...
Conversion complete

Creating OTA images...
Conversion complete

Detecting device...
Device found

Downloading application...
Download complete

Application running

13:24:50 Build Finished (took 24s.71ms)

0 Likes
Anonymous
Not applicable

Hello,

Thanks you so much for your quick response. Here are my steps to have these problems.

1) I try to build/program to a BCM920732 Tag board

2) I chose a project in the Projector explorer panel on the left side of the IDE

3) I right click a project such as Automation_IO and choose “Make Targets” and then “Create” to have below window:

4) Target (test1) was created in the Make Target panel on the right part of IDE as below

5) I right click the “test1” target and choose “Build target” and get the error message:

13:44:11 **** Build of configuration blood_pressure_monitor-BCM920732TAG_Q32 for project WICED-Smart-SDK ****

"C:
Users
vyin
Documents
WICED
WICED-Smart-SDK-1.1.0
WICED-Smart-SDK
make.exe" test1

make: *** No rule to make target 'test1'. Stop.

13:44:11 Build Finished (took 169ms)

6) I wonder what’s the rule to build a target. The error happens to all the project on the left panel of Project explorer.

However if I “Build target” for the existing target files it works fine. See below:

7) So I must did something wrong, or my IDE has a wrong settings. Please help me. Thanks. My settings are:

0 Likes
MichaelF_56
Moderator
Moderator

Go here and download the Quick Start Guide: WICED Smart Documentation


Take a look at the "Building your First App" sample...


This method of copying, then pasting and renaming a new target in the right hand Make Target window is what I've used.

For custom development, you will also want to copy an existing sample App such as Automation_IO by right-clicking on the Project folder and copying the project.  You will then want to paste and rename it back into the Apps/RAM folder with a new name (this will preserve the original example app).

Within the Make Target window on the right, you will want to make sure your cut and pasted copy also has the same name as your renamed project folder, for example if you named the new project "newwidget" you would want the copied Make Target named RAM.newwidget-xxxxx

Anonymous
Not applicable

Dear there,

Thanks for your help again.

I followed the procedure in page 11 of 23 in the attached guide. It still shows errors:

1) Copy “RAM.automation_io-BCM920732TAG_Q32 download target”

2) Paste it to same place to have “Copy of RAM.automation_io-BCM920732TAG_Q32 download”

3) Build Target for it, the error is

17:22:59 **** Build of configuration blood_pressure_monitor-BCM920732TAG_Q32 for project WICED-Smart-SDK ****

"C:
Users
vyin
Documents
WICED
WICED-Smart-SDK-1.1.0
WICED-Smart-SDK
make.exe" Copy of RAM.automation_io-BCM920732TAG_Q32 download

Makefile:173: *** Platform makefile not found: Platforms//.mk. Stop.

17:22:59 Build Finished (took 124ms)

4) I think if you uninstall your IDE and reinstall it by default, you may see same problem. I don’t know how my problem happened and how to fix it, file path is wrong?

Thanks

Victory

0 Likes
VictorZ_46
Employee

Hi Victory,

Read the instructions carefully.  When you rename remote the "Copy " in the beginning and you will be fine.  Good luck.

Thanks,

Victor

0 Likes
Anonymous
Not applicable

Hello Victor,

I have problem also after I rename a target file from RAM.automation_io-BCM920732TAG_Q32 download to ROM.automation_io-BCM920732TAG_Q32 download

18:36:13 **** Build of configuration blood_pressure_monitor-BCM920732TAG_Q32 for project WICED-Smart-SDK ****

"C:
Users
Victory
Documents
WICED
WICED-Smart-SDK-1.0.1
WICED-Smart-SDK
make.exe" ROM.automation_io-BCM920732TAG_Q32 download

makefile:52: ../../Apps//makefile.inc: No such file or directory

makefile:96: "Warning: ELF_LIST is undefined."

makefile:96: "Warning: NUM_PATCH_ENTRIES is undefined."

makefile:96: "Warning: PATCH_ENTRY_SIZE is undefined."

makefile:96: "Warning: LMPREV is undefined."

make.exe[1]: *** No rule to make target '../../Apps//makefile.inc'. Stop.

Makefile:277: recipe for target 'ROM.automation_io-BCM920732TAG_Q32' failed

make: *** Error 2

18:36:13 Build Finished (took 468ms)

1) Can you send me your IDE’s file path, C++ build settings and behavior settings? I want to compare if it is same as mine.

2) Can I set up a webx so you can my screen so that you can help to figure out problem?

3) Can you see my emails below if you can find something wrong?

Thanks

Victory

I followed the procedure in page 11 of 23 in the attached guide. It still shows errors:

1) Copy “RAM.automation_io-BCM920732TAG_Q32 download target”

2) Paste it to same place to have “Copy of RAM.automation_io-BCM920732TAG_Q32 download”

3) Build Target for it, the error is

17:22:59 **** Build of configuration blood_pressure_monitor-BCM920732TAG_Q32 for project WICED-Smart-SDK ****

"C:
Users
vyin
Documents
WICED
WICED-Smart-SDK-1.1.0
WICED-Smart-SDK
make.exe" Copy of RAM.automation_io-BCM920732TAG_Q32 download

Makefile:173: *** Platform makefile not found: Platforms//.mk. Stop.

17:22:59 Build Finished (took 124ms)

4) I think if you uninstall your IDE and reinstall it by default, you may see same problem. I don’t know how my problem happened and how to fix it, file path is wrong?

Thanks

Victory

Thanks you so much for your quick response. Here are my steps to have these problems.

1) I try to build/program to a BCM920732 Tag board

2) I chose a project in the Projector explorer panel on the left side of the IDE

3) I right click a project such as Automation_IO and choose “Make Targets” and then “Create” to have below window:

4) Target (test1) was created in the Make Target panel on the right part of IDE as below

5) I right click the “test1” target and choose “Build target” and get the error message:

13:44:11 **** Build of configuration blood_pressure_monitor-BCM920732TAG_Q32 for project WICED-Smart-SDK ****

"C:
Users
vyin
Documents
WICED
WICED-Smart-SDK-1.1.0
WICED-Smart-SDK
make.exe" test1

make: *** No rule to make target 'test1'. Stop.

13:44:11 Build Finished (took 169ms)

6) I wonder what’s the rule to build a target. The error happens to all the project on the left panel of Project explorer.

However if I “Build target” for the existing target files it works fine. See below:

7) So I must did something wrong, or my IDE has a wrong settings. Please help me. Thanks. My settings are:

0 Likes
VictorZ_46
Employee

Hi Victory,

If you look carefully at the target name for example "RAM.automation_io-BCM920732TAG_Q32 download".  The first part is the name of the directory under Apps which is "RAM".  After dot there is a name of a subdirectory which is "automation-io".  This is the place where build process is looking for makefile.inc.  Then there is a name of the directory under Platforms which specifies for what platform you are building "BCM920732TAG_Q32".  The rest are not arbitrary words but something that make understand.  For example the word "download" indicates that you want to download resulting image to the tag.  If you change RAM.automation-io to ROM.automation-io, it will not build because there is no directory ROM.automation-io.  Also putting random word "target" in the string will not help things up.

To build and download the image you need to double click on the application under Make Target in the top right pane of the IDE.

If you want to clean everything up, uninstall the package and then delete all the user files that were installed.  By default they are in users\<user name>\Documents\WICED directory.

Good luck,

-Victor

Anonymous
Not applicable

Hi Victor,

Thanks a lot. This is very helpful. I’ll try tomorrow. How can find you later on if I still have other issues?

Thanks again.

Victory

0 Likes
VictorZ_46
Employee

I am on the East Coast :-).  Post the message on the board and we will take care of you!

0 Likes
Anonymous
Not applicable

Hello Victor,

We are tempting to program the connect BCM20732S with BCM20732TAG_Q32 JTAG connector. We did this way with bare SIP chip (no PCB, only soldered wires to the chip) to connect to the JTAG and the Smart IDE doesn’t detect the SIP chip when building target. The dip switch was switched on-off-on-off. So the issue is not from here.

Can you check if we missed something?

Thanks

Victory

The JTAG connecter on the BCM20732TAG_Q32 is as following:

· BCM20732TAG_Q32 JTAG Pin 1 = UART Tx which needs to go to BCM20732S UART Tx Pin 19

· BCM20732TAG_Q32 JTAG Pin 2 = GND which needs to go to BCM20732S G GND Pins 2, 4, 5, 6, 7, 8, 9, 11, 12, 13, 14, 15, 16, , 17, 20. 23, 24, 29 , 38, 45, 46, 47, 48

· BCM20732TAG_Q32 JTAG Pin 3 = UART Rx which needs to go to BCM20732S UART Rx Pin 18

· BCM20732TAG_Q32 JTAG Pin 4 = VBAT which needs to go to BCM20732S VBAT Pin 3

The chips pin map is

The JTAG connector on the BCM920732 Tag board is:

Connecting:

3 Battery +

18 UART_RX

19 UART_Tx

2 GND.

0 Likes
MichaelF_56
Moderator
Moderator

You are attempting to program the BCM20732S directly?  Via a header connected to the HCI UART?

You may find these instructions helpful: Information: Programming your BCM20732S-based board from an onboard UART header

What's key is that you power your board up while making sure that RXD is held high during power up. This will put the part into Programming mode.  Otherwise, if low, it will default to Application mode.

The best bet here is to work with your local distributor/BRCM Sales to obtain a BCM20732S Evaluation board and a BCM920732 Tag board, then use the Tag board to program the 20732S Eval Kit.  There is a doc we can send that walks you through this methodology if you end up using it.

0 Likes
Anonymous
Not applicable

Hi Victor,

It worked for me. Thanks.

For the naming convention below you mentioned, where can I find the official documentation for it because I want to know if there are other thnings I need to pay attention.

Thanks a lot,

Victor

0 Likes