'''
License
-------
No Copyright

The person who associated a work with this deed has dedicated the work to the
public domain by waiving all of his or her rights to the work worldwide under
copyright law, including all related and neighboring rights, to the extent
allowed by law.

You can copy, modify, distribute and perform the work, even for commercial
purposes, all without asking permission.

See https://creativecommons.org/share-your-work/public-domain/cc0/ for more
information on the license.


Project
-------
This file is part of the wedding pictogram project, made by
Maarten Tromp <maarten@geekabit.nl>.

More info on the project:
https://www.geekabit.nl/projects/wedding-gift-sprite/
'''


# 24 neopixel are connected to io15 (pin23)

from machine import Pin
from neopixel import NeoPixel
import time

l = 4
m = 10
pin = Pin(15, Pin.OUT)	# set GPIO15 to output to drive NeoPixels
np = NeoPixel(pin, l)	# create NeoPixel driver on GPIO0 for 24 pixels

while True:
	for i in range(l):
		np[i] = (m, 0, 0)	# set the first pixel to red
	np.write()		# write data to all pixels
	time.sleep(1)
	for i in range(l):
		np[i] = (0, 0, 0)	# set the first pixel off
	np.write()
	time.sleep(1)


# end of file
