Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[max7219digit] add actions for the common display functions. #4164

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 42 additions & 0 deletions components/display/max7219digit.rst
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,48 @@ Configuration variables:
- **chip_lines_style** (*Optional*): How are the lines in Multiline Mode connected? Possible values are ``zigzag`` and ``snake``. Defaults to ``snake``
- **flip_x** (*Optional*, boolean): Flip the horizontal axis on the screen. Defaults to ``false``.

.. _display-max7219digit_actions:

Actions
-------
The following actions are replicas of the LAMBDA functions shown in the next section.

.. _display-max7219digit_actions_invert_on_off>:

`MAX7219.invert_on` & `MAX7219.invert_off` Action
=================================================

This action ``MAX7219.invert_on`` will invert the display. So background pixels are on and texts pixels are
off. ``MAX7219.invert_off`` sets the display back to normal. The background pixels are only set at the next update, the pixels drawn in
the various function like print, line, etc. are directly influenced by the invert command.

.. _display-max7219digit_actions_turn_on_off:

`MAX7219.turn_on` & `MAX7219.turn_off` Action
=============================================

The display can be switched on and off "dynamically" with the actions `MAX7219.turn_on` & `MAX7219.turn_off`.


.. _display-max7219digit_actions_reverse_off:

`MAX7219.reverse_on` & `MAX7219.reverse_off` Action
===================================================

With this actions you can reverse the display direction from left to right to right to left.


.. _display-max7219digit_actions_intensity:

`MAX7219.intensity` Action
===========================

The intensity of the screen can be set "dynamically" within the lambda code with the following command: it.intensity(``0`` .. ``15``).

- **intensity** (int): The intensity with which the MAX7219 should drive the outputs. Range is
from ``0``, least intense to ``15`` the brightest. Defaults to ``15``.


.. _display-max7219digit_lambda:

Rendering Lambda
Expand Down