Skip to content

Commit

Permalink
Version 1.0.1: doc update
Browse files Browse the repository at this point in the history
  • Loading branch information
pierremolinaro committed Jun 10, 2021
1 parent d7d7ae9 commit 42a7f5b
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 11 deletions.
Binary file modified extras/rp2040-charlieplexing.pdf
Binary file not shown.
4 changes: 2 additions & 2 deletions library.properties
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name=RP2040_PIO_Charlieplexing
version=1.0.0
version=1.0.1
author=Pierre Molinaro
maintainer=Pierre Molinaro <pierre@pcmolinaro.name>
sentence=A RP2040 PIO program for 6-leds and 5-leds Charlieplexing.
paragraph=The PIOs integrated in the RP2040 microcontroller enable the refresh to be performed automatically, without processor intervention. The 6-leds version requires 11 PIO instructions, the 5-leds version requires 7 PIO instructions.
paragraph=The PIOs integrated in the RP2040 microcontroller enable the refresh to be performed automatically, without processor intervention. The 6-leds version requires 11 PIO instructions, the 5-leds version requires 7 PIO instructions. This library uses Raspberry Pi Pico/RP2040 board manager by Earle F. Philower, III, see https://github.com/earlephilhower/arduino-pico
category=Display
url=https://github.com/pierremolinaro/rp2040-charlieplexing
architectures=*
Expand Down
40 changes: 31 additions & 9 deletions src/call-pioasm.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,40 @@

#---------------------------------------------------------------------------------------------------

def RED () :
return '\033[91m'

#---------------------------------------------------------------------------------------------------

def ENDC () :
return '\033[0m'

#---------------------------------------------------------------------------------------------------

def BOLD () :
return '\033[1m'

#---------------------------------------------------------------------------------------------------

#--- Get script absolute path
scriptDir = os.path.dirname (os.path.abspath (sys.argv [0]))
os.chdir (scriptDir)
#---
pioasmTool = os.path.expanduser ("~/Library/Arduino15/packages/rp2040/tools/pqt-pioasm/1.1.0-a-81a1771/pioasm")
#--- charlieplexing5
returncode = subprocess.call ([pioasmTool, "charlieplexing5.pioasm", "pio-charlieplexing5.h"])
if returncode != 0 :
sys.exit (returncode)
#--- charlieplexing6
returncode = subprocess.call ([pioasmTool, "charlieplexing6.pioasm", "pio-charlieplexing6.h"])
if returncode != 0 :
sys.exit (returncode)
toolDir = os.path.expanduser ("~/Library/Arduino15/packages/rp2040/tools/pqt-pioasm")
found = False
for aDir in sorted (os.listdir (toolDir)) :
pioasmTool = (toolDir + "/" + aDir + "/pioasm")
if os.path.exists (pioasmTool) :
found = True
#--- charlieplexing5
returncode = subprocess.call ([pioasmTool, "charlieplexing5.pioasm", "pio-charlieplexing5.h"])
if returncode != 0 :
sys.exit (returncode)
#--- charlieplexing6
returncode = subprocess.call ([pioasmTool, "charlieplexing6.pioasm", "pio-charlieplexing6.h"])
if returncode != 0 :
sys.exit (returncode)
if not found :
print (RED () + BOLD () + "Cannot find pioasm" + ENDC ())

#---------------------------------------------------------------------------------------------------

0 comments on commit 42a7f5b

Please sign in to comment.