Alternate between 2 text messages

Hi All,

New here, but I am looking for a way to alternate between 2 text messages on one Matrix Board.
e.g.
5sec it displays “Hello” then the other 5sec is displays “World”

Can anybody help me please?

Thanks in advance,
Regards,
Dieter

this is a basic programming question you should ask on another forum. We only discuss issues specific to the driver and hardware, and that’s on a best effort basis

Hi Marc,

thanks for the response - can you please forward me to the correct forum please?

Thanks in advance,
Regards,
Dieter

With a bash script ? (note the ‘&’ to have a delay)

sudo ./text-scroller -f /home/pi/rpi-rgb-led-matrix/fonts/5x8.bdf --led-cols=32 --led-rows=16 --led-row-addr-type=2 -s0 “Hello”&
sleep 5s
sudo killall text-scroller
sudo ./text-scroller -f /home/pi/rpi-rgb-led-matrix/fonts/5x8.bdf --led-cols=32 --led-rows=16 --led-row-addr-type=2 -s0 “world”&
sleep 5s
sudo killall text-scroller

Hi Alex,
Thanks for the response, I believe this script will only show “Hello” for 5seconds and then “World” for 5seconds and then stop, correct?
But I would need continuously alternating.

Put it in a loop:

#!/bin/sh
while :
do
sudo ./text-scroller -f /home/pi/rpi-rgb-led-matrix/fonts/5x8.bdf --led-cols=32 --led-rows=16 --led-row-addr-type=2 -s0 “Hello”&
sleep 5s
sudo killall text-scroller
sudo ./text-scroller -f /home/pi/rpi-rgb-led-matrix/fonts/5x8.bdf --led-cols=32 --led-rows=16 --led-row-addr-type=2 -s0 “world”&
sleep 5s
sudo killall text-scroller
done

you are asking people about basic programming, please bet basic programming books/resources, in this case for unix.
or you can hope that someone will answer your questions one by one, but it’s really better if you learn it yourself so you don’t depend on others :slight_smile: