PX4-Autopilot icon indicating copy to clipboard operation
PX4-Autopilot copied to clipboard

Add ktd202x RGB(W) LED driver

Open rolandash opened this issue 1 year ago • 1 comments

This PR includes PX4 software driver implementation for ktd202x series.

KTD202x series are constant current RGB(W) LED driver ICs from Kinetic. The ICs can be controlled from I2C interface. The datasheet can be found here.

This IC features very small footprint (1.5x1.5mm only) while still in an UDFN package, which makes its PCB assembly process much easier and more solid than BGA/CSP package.

Source code in this PR has been tested on real hardware running PX4 release v1.14.

Driver usage:

nsh> rgbled_ktd202x
Usage: rgbled_ktd202x <command> [arguments...]
 Commands:

   start
     [-I]        Internal I2C bus(es)
     [-X]        External I2C bus(es)
     [-b <val>]  board-specific bus (default=all) (external SPI: n-th bus (default=1))
     [-f <val>]  bus frequency in kHz
     [-q]        quiet startup (no message if no device found)
     [-a <val>]  I2C address
                 default: 48
     [-w]        use white channel for ktd2027
     [-o <val>]  RGB PWM Assignment
                 default: 123
     [-z <val>]  Specify the limit of output current in step of 0.125mA, valid between 1(0.25mA) and 255(24mA)
                 default: 255

   stop

   status        print status info
nsh>

@dagar @julianoes @davids5

rolandash avatar Feb 11 '24 11:02 rolandash

This pull request has been mentioned on Discussion Forum for PX4, Pixhawk, QGroundControl, MAVSDK, MAVLink. There might be relevant details there:

https://discuss.px4.io/t/support-ktd202x-rgb-led-driver/36831/1

DronecodeBot avatar Feb 17 '24 16:02 DronecodeBot

This driver has been moved to MindRacer Gen.3 board specific source commit, as seems no one interested in put it into mainline.

rolandash avatar Aug 07 '24 17:08 rolandash

Sorry, I missed this. @dagar?

julianoes avatar Aug 07 '24 20:08 julianoes