Grove wiring for tests

Overview

This shield is less a plug-on module in the conventional sense than more a wiring for interconnection of certain signals. It can be used to run most samples from Zephyr and Bridle that require special aliases or chosen entries on device tree level or other specific Kconfig setups.

Requirements

This shield requires a board, maybe with additional connected shields, which provides a configuration that allows:

When the board is not equipped with the required shield connectors, but instead an Arduino UNO R3 header, then the Grove Base Shield V2 can be plugged in between.

Note

Sometimes boards declare standard headers like Arduino UNO R3 but not define all connections. Make sure that the board you are using have all definitions to avoid build errors (see Shields for more details).

Supported variations

Modules

Port Type

Grove Base Shield V2

Grove LED Shields

Grove Digital Layout [1]

D6 (PWM)

Grove Buzzer Shields (not yet)

Grove Digital Layout [1]

D5 (PWM)

Grove OLED Shields (not yet)

Grove I2C Layout [4]

I2C

Grove Button Shields

Grove Digital Layout [1]

D4

Grove Rotary Potentiometer Shields (not yet)

Grove Analog Layout [2]

A0

Grove Sound Sensor Shields (not yet)

Grove Analog Layout [2]

A2

Grove Light Sensor Shields (not yet)

Grove Analog Layout [2]

A3

Grove Temperature & Humidity Sensor Shields (not yet)

Grove Digital Layout [1]

D3

Grove Air Pressure Sensor Shields (not yet)

Grove I2C Layout [4]

I2C

Grove 3-Axis Accelerator Sensor Shields (not yet)

Grove I2C Layout [4]

I2C

Hint

The Grove Base Shield V2 together with all the sensors and actuators can be easily replaced by the Arduino Sensor Kit – Base [5] as also done in the examples below.

Wiring Schematics

Common Wiring Schematics

Build and Programming

Set -DSHIELD=<shield designation> when you invoke west build. For example:

Using west:

west build -b <board_name> -p --shield "<shield_name_with_grove_connectors> grove_btn_d4 grove_led_d6 grove_pwm_led_d6 x_grove_testbed" -d build/<sample_name>-x_grove_testbed <sample_folder>
west flash -d build/<sample_name>-x_grove_testbed

Using CMake and ninja:

# Use cmake to configure a Ninja-based buildsystem:
cmake -Bbuild/<sample_name>-x_grove_testbed -GNinja -DBOARD=<board_name> -DSHIELD=""<shield_name_with_grove_connectors> grove_btn_d4 grove_led_d6 grove_pwm_led_d6 x_grove_testbed"" <sample_folder>

# Now run the build tool on the generated build system:
ninja -Cbuild/<sample_name>-x_grove_testbed flash

This is based on the Zephyr board ST Nucleo F303RE.

ST Nucleo F303RE Wiring Schematics

This is based on the Zephyr sample Blinky.

Using west:

west build -b nucleo_f303re -p --shield \
"seeed_grove_base_v2 grove_btn_d4 grove_led_d6 grove_pwm_led_d6 x_grove_testbed" -d build/blinky-nucleo_f303re-x_grove_testbed zephyr/samples/basic/blinky
west flash -d build/blinky-nucleo_f303re-x_grove_testbed

Using CMake and ninja:

# Use cmake to configure a Ninja-based buildsystem:
cmake -Bbuild/blinky-nucleo_f303re-x_grove_testbed -GNinja -DBOARD=nucleo_f303re -DSHIELD="\
"seeed_grove_base_v2 grove_btn_d4 grove_led_d6 grove_pwm_led_d6 x_grove_testbed"" zephyr/samples/basic/blinky

# Now run the build tool on the generated build system:
ninja -Cbuild/blinky-nucleo_f303re-x_grove_testbed flash

References