pinout.vvzero.com/src/en/overlay/piborg-ledborg.md

56 lines
1.3 KiB
Markdown
Raw Normal View History

2015-11-10 02:05:51 +08:00
<!--
---
2016-06-25 06:26:20 +08:00
name: PiBorg LEDBorg
2016-01-31 19:03:17 +08:00
class: board
type: led
formfactor: Custom
2016-06-25 06:57:03 +08:00
image: 'piborg-led-borg.png'
2015-11-16 00:56:26 +08:00
manufacturer: PiBorg
2015-11-10 02:05:51 +08:00
description: A single RGB LED for your Raspberry Pi
2015-11-16 00:56:26 +08:00
url: https://www.piborg.org/ledborg-new/install
2015-11-10 02:05:51 +08:00
buy: https://www.piborg.org/ledborg
2015-11-16 00:56:26 +08:00
pincount: 26
eeprom: no
2015-11-10 02:05:51 +08:00
pin:
'11':
name: Red LED
direction: output
active: high
description: PiBorg Red LED
'13':
name: Green LED
direction: input
active: high
description: PiBorg Green LED
'15':
name: Blue LED
direction: output
active: high
description: PiBorg Blue LED
-->
###The PiBorg LedBorg is an ultra-bright RGB LED board for the Raspberry Pi.
2015-11-16 00:56:26 +08:00
the PiBorg Ledborg has its own driver, so you don't need to drive it manually.
2015-11-10 02:05:51 +08:00
If you want a much, much wider range of colours, though, you can drive it manually using softPwm in WiringPi. The pin assignments for this are as follows:
WiringPi pin 0: Red LED
WiringPi pin 2: Green LED
WiringPi pin 3: Blue LED
This is easy using WiringPi in Python:
```python
import wiringpi2 as wiringpi
wiringpi.wiringPiSetup()
wiringpi.softPwmCreate(0,0,100)
wiringpi.softPwmCreate(2,0,100)
wiringpi.softPwmCreate(3,0,100)
# Purple!
wiringpi.softPwmWrite(3,100) # Full Blue
wiringpi.softPwmWrite(0,100) # Full Red
wiringpi.softPWMWrite(2,0) # No Green
2016-01-31 19:03:17 +08:00
```