Set_device_brightness for APA102 not working

Hi,

I’m trying to use the APA102 attribute set_device_brightness while running an animation, but get the error:

ERROR - project_runner - Unable to create drivers
Unknown attribute for driver APA102: "set_device_brightness"

My code is as follows:

driver:
  typename: SPI
  c_order: BGR
  ledtype: APA102
  num: 60
  interface: PYDEV
  set_device_brightness: 2

As far as I can tell from here, that should work I think.
Am I putting set_device_brightness in the wrong place?

That option is really meant for internal use - just use the regular brightness option.

Ahhh and will that pass through to set_device_brightness and use the APA102 hardware option then?

Yes, we tried to make it “just do the right thing”

Great, thanks! I’m sure it’s in the documentation, but I’m struggling to find it - where should I put the brightness please? Not in the driver: section it seems

Seems like it should perhaps be in layout section, but putting it in there returns:

ERROR - project_runner - Unable to create layout
No "datatype" field in section "layout"

The tutorial for the layout section appears incomplete, so I’m not sure…

Ahh, figured it out. For anyone else who gets stuck, brightness: can’t be in the layout section by itself, it needs typename: to be filled out too, e.g.

layout:
  typename: strip
  brightness: 16