From 398997e5a5b2670f700dc4f5b8bee6268b91ffb4 Mon Sep 17 00:00:00 2001 From: Rozhuk Ivan Date: Mon, 12 Sep 2022 13:11:25 +0300 Subject: [PATCH] comms/py-cc2538-bsl: add 20220803 --- comms/py-cc2538-bsl/Makefile | 46 +++++++++++++++++++++++++++++++++ comms/py-cc2538-bsl/distinfo | 3 +++ comms/py-cc2538-bsl/pkg-descr | 5 ++++ comms/py-cc2538-bsl/pkg-message | 16 ++++++++++++ 4 files changed, 70 insertions(+) create mode 100644 comms/py-cc2538-bsl/Makefile create mode 100644 comms/py-cc2538-bsl/distinfo create mode 100644 comms/py-cc2538-bsl/pkg-descr create mode 100644 comms/py-cc2538-bsl/pkg-message diff --git a/comms/py-cc2538-bsl/Makefile b/comms/py-cc2538-bsl/Makefile new file mode 100644 index 000000000000..d860f33cb742 --- /dev/null +++ b/comms/py-cc2538-bsl/Makefile @@ -0,0 +1,46 @@ +PORTNAME= cc2538-bsl +DISTVERSION= 20220803 +CATEGORIES= comms python +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} + +MAINTAINER= rozhuk.im@gmail.com +COMMENT= TI CC13xx/CC2538/CC26xx Serial Boot Loader +WWW= https://github.com/JelmerT/cc2538-bsl + +LICENSE= BSD3CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE.md + +RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pyserial>=3.4:comms/py-pyserial@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}intelhex>=0:devel/py-intelhex@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}python-magic>=0:devel/py-python-magic@${PY_FLAVOR} + +USES= python:3.4+ shebangfix +USE_PYTHON= flavors +USE_GITHUB= yes +GH_ACCOUNT= JelmerT +GH_TAGNAME= 538ea0deb99530e28fdf1b454e9c9d79d85a3970 +SHEBANG_FILES= cc2538-bsl.py + +NO_ARCH= yes +NO_BUILD= yes + +post-patch: + @${REINPLACE_CMD} -e "s|tty.usbserial|cua|g" \ + ${WRKSRC}/cc2538-bsl.py + +# This is to prevent Mk/Uses/python.mk do-configure target from firing. +do-configure: + @${ECHO} 'No configure' + +do-install: + ${INSTALL_SCRIPT} ${WRKSRC}/cc2538-bsl.py ${STAGEDIR}${PREFIX}/bin/ + ${CHMOD} +x ${STAGEDIR}${PREFIX}/bin/cc2538-bsl.py + +post-install: + # Regenerate .PLIST.pymodtemp to get all installed files from + # ${STAGEDIR}. + @${FIND} ${STAGEDIR} -type f -o -type l | \ + ${SORT} | ${SED} -e 's|${STAGEDIR}||' \ + >> ${WRKDIR}/.PLIST.mktmp + +.include diff --git a/comms/py-cc2538-bsl/distinfo b/comms/py-cc2538-bsl/distinfo new file mode 100644 index 000000000000..5f7d60abbe57 --- /dev/null +++ b/comms/py-cc2538-bsl/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1662975013 +SHA256 (JelmerT-cc2538-bsl-20220803-538ea0deb99530e28fdf1b454e9c9d79d85a3970_GH0.tar.gz) = 51e589638fe9f597db646fd4ebe4ad8f37a4ab32970244d8b383c2007566627f +SIZE (JelmerT-cc2538-bsl-20220803-538ea0deb99530e28fdf1b454e9c9d79d85a3970_GH0.tar.gz) = 17962 diff --git a/comms/py-cc2538-bsl/pkg-descr b/comms/py-cc2538-bsl/pkg-descr new file mode 100644 index 000000000000..181d491b05d2 --- /dev/null +++ b/comms/py-cc2538-bsl/pkg-descr @@ -0,0 +1,5 @@ +This folder contains a python script that communicates with the boot +loader of the Texas Instruments CC2538, CC26xx and CC13xx SoCs +(System on Chips). +It can be used to erase, program, verify and read the flash of those +SoCs with a simple USB to serial converter. diff --git a/comms/py-cc2538-bsl/pkg-message b/comms/py-cc2538-bsl/pkg-message new file mode 100644 index 000000000000..7283326232ac --- /dev/null +++ b/comms/py-cc2538-bsl/pkg-message @@ -0,0 +1,16 @@ +[ +{ type: install + message: <