use PINE64::MAX7219; my $max = PINE64::MAX7219->new(0,1,2); $max->turn_on(1); $max->set_scanlimit(1); $max->set_intensity('max'); #display test (all on / all off)) $max->disp_teston(); sleep(2); $max->disp_testoff(); #clockwise circles $max->clockwise_circles(10); #counter clockwise circles $max->countercw_circles(10); #print a sentence, 0.5sec / word $max->print_sentence("perl rules on pine64", 500000); #endless KnightRider effect! for(;;){ $max->bullets_lrmid(1); $max->bullets_rlmid(1); }#end for
This module is a driver for 8-digit seven-segment MAX7219 displays. It is implemented as bit-banged SPI. Using the object's methods, you can set the intensity of the display, print words, and cascade multiple displays. It also comes with several built-in effects.
Only three GPIO pins are required: SPI clk, SPI data, and SPI chip select. This modules uses the PINE64::GPIO numbering scheme.
Takes the GPIO pin numbers that will be used to inplement the bit-bang SPI interface to the MAX7219 as arguments. Returns an object to control an 8-digit display.
1 POD Error
The following errors were encountered while parsing the POD:
=pod directives shouldn't be over one line long! Ignoring all 3 lines of content
To install PINE64::MAX7219, copy and paste the appropriate command in to your terminal.
cpanm
cpanm PINE64::MAX7219
CPAN shell
perl -MCPAN -e shell install PINE64::MAX7219
For more information on module installation, please visit the detailed CPAN module installation guide.