Features Demonstrated
- GPIO commands and variables:
- get gp u - List GPIO usage, direction and initialization.
- Controlling LEDs
- Controlling a speaker
GPIO Functions and Pins
Viewing GPIO Usage
> get gp u
! # Description
# 0 i2c_sda
# 1 i2c_scl
# 2 user_tx
# 3 none
# 4 none
# 5 user_rx
# 6 none,factory
# 7 reserved
# 8 none
# 9 mode_sel
# 10 status_led
# 11 none
# 12 none
# 13 speaker
# 14 stream_gpio
PWMs
gfu <GPIO> none
. The the GPIO is set to the pwm
function with the command gfu <GPIO> pwm
. Then the pwm command assigns the frequency and duty cycle.LEDs
Wahoo GPIO | LED Color |
---|---|
14 | Red |
10 | Green |
11 | Blue |
status_led
function on Wahoo. It must be de-assigned to none
before it can be used for another purpose.TruConnect commands | Comments |
---|---|
|
|
TruConnect commands | Comments |
---|---|
|
|
gfu 10 none
gfu 11 none
gfu 14 none
gfu 10 pwm
gfu 11 pwm
gfu 14 pwm
low_count
and high_count
arguments determines the duty cycle of the PWM, as described in the pwm command documentation. The duty cycle impacts the brightness of the LED, lower duty cycles provide make the LED brighter. The lowest available PWM frequency, about 128Hz, may be used without any detectable flashing of the LED.pwm 14 614 409
pwm 10 818 205
pwm 11 409 614
Speaker
pwm
function on GPIO 13:gfu 13 none
gfu 13 pwm
pwm 13 250 250
pwm 13 stop
speaker
function with the gfu command.> gfu 13 none
Success
> gfu 13 speaker
Success
> save
Success
> reboot
[COMMAND MODE]
> beep 100
Success