Skip to content

Commit

Permalink
python3Packages.amshan: init at 2.1.1
Browse files Browse the repository at this point in the history
  • Loading branch information
bjornfor committed Jan 13, 2025
1 parent 7d4cd94 commit 8a31789
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 0 deletions.
45 changes: 45 additions & 0 deletions pkgs/development/python-modules/amshan/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
construct,
paho-mqtt,
pyserial-asyncio,
}:

buildPythonPackage rec {
pname = "amshan";
version = "2.1.1";
pyproject = true;

src = fetchFromGitHub {
owner = "toreamun";
repo = "amshan";
rev = version;
hash = "sha256-aw0wTqb2s84STVUN55h6L926pXwaMSppBCfXZVb87w0=";
};

build-system = [
setuptools
];

dependencies = [
construct
paho-mqtt
pyserial-asyncio
];

pythonImportsCheck = [ "han" ];

meta = {
description = "Decode smart power meter data stream of Cosem HDLC frames used by MBUS";
longDescription = ''
The package has special support of formats for Aidon, Kaifa and Kamstrup
meters used in Norway and Sweden (AMS HAN).
'';
homepage = "https://github.com/toreamun/amshan";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ bjornfor ];
};
}
2 changes: 2 additions & 0 deletions pkgs/top-level/python-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -588,6 +588,8 @@ self: super: with self; {

amqtt = callPackage ../development/python-modules/amqtt { };

amshan = callPackage ../development/python-modules/amshan { };

anchor-kr = callPackage ../development/python-modules/anchor-kr { };

ancp-bids = callPackage ../development/python-modules/ancp-bids { };
Expand Down

0 comments on commit 8a31789

Please sign in to comment.