about summary refs log tree commit diff
path: root/nixpkgs/pkgs/applications/misc/audio/wavrsocvt/default.nix
blob: c9f97c5602b209ef6913b938b810f455ef63d2bb (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
{ lib, stdenv, fetchurl }:

stdenv.mkDerivation {
  pname = "wavrsocvt";
  version = "1.0.2.0";

  src = fetchurl {
    url = "https://bricxcc.sourceforge.net/wavrsocvt.tgz";
    sha256 = "15qlvdfwbiclljj7075ycm78yzqahzrgl4ky8pymix5179acm05h";
  };

  unpackPhase = ''
    tar -zxf $src
  '';

  installPhase = ''
    mkdir -p $out/bin
    cp wavrsocvt $out/bin
  '';

  meta = with lib; {
    description = "Convert .wav files into sound files for Lego NXT brick";
    longDescription = ''
      wavrsocvt is a command-line utility which can be used from a
      terminal window or script to convert .wav files into sound
      files for the NXT brick (.rso files). It can also convert the
      other direction (i.e., .rso -> .wav). It can produce RSO files
      with a sample rate between 2000 and 16000 (the min/max range of
      supported sample rates in the standard NXT firmware).
      You can then upload these with e.g. nxt-python.
    '';
    homepage = "https://bricxcc.sourceforge.net/";
    license = licenses.mpl11;
    maintainers = with maintainers; [ leenaars ];
    platforms = with platforms; linux;
  };
}