Giter Site home page Giter Site logo

tools's People

Contributors

brunetton avatar handyandy80 avatar jepperc avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

tools's Issues

IR Pin conflict on GP25 with other Hat (touchscreen)

Am I able to simply change the code on line 43 in IQ_ir.c to reference another GPIO or are there other references I need to change as well?

GP25 is used by the touchscreen I have as an Interupt.

As an aside on the board I have there is an 8pin header with IO27, mute L,R and 0V, is this a header for the Amp?

There is also a 5 Pin header labeled P6, is there any information as to the functionality of this?

The board is a Pi-DAC+ dated 2018 with PCB 003/v4 printed on it.
Thanks

error on running

Latest PiCorePlayer (1.21, Linux kernel 4.1.*).
Compiles fine, after finding all of the libraries (phew!).
Runs with error:IQ_rot: simple.c:282: snd_mixer_selem_get_playback_volume_range: Assertion `elem' failed.
No function.

Any suggestions?

Unable to run sudo IQ_rot

Dears,

many thanks for this great utility although I didn't manage to work so far. I am a real newbie to this. So, probably sorry for this question. I use following hardware/software setup:

  • raspberry pi 3 Model B+
  • iqaudio DAC+
  • rotary encoder shown in your manual
  • volumio Version 2.575

I connected the rotary encoder to following pins:

  • Left connector to pin 16
  • Middle connector to pin 14
  • Right connector to pin 18

I executed following commands:

  • sudo apt-get update
  • sudo apt-get upgrade
  • git clone git://git.drogon.net/wiringPi
  • cd wiringPi
  • cd
  • git pull origin
  • git clone https://github.com/iqaudio/tools
  • cd tools
  • sudo IQ_rot
    I always get the message sudo: IQ_rot: command not found

Could you please advice me what I have to change that this rotary encoder will work? Many thanks in advance for any help and support.

Please find below all the details:
volumio@volumio:~$ cd volumio@volumio:~$ sudo apt-get update Get:1 http://archive.volumio.org jessie InRelease [14.9 kB] Get:2 http://archive.volumio.org jessie InRelease [22.9 kB] Get:3 http://archive.volumio.org jessie/main Sources [7762 kB] Get:4 http://archive.volumio.org jessie/contrib Sources [64.5 kB] Get:5 http://archive.volumio.org jessie/non-free Sources [113 kB] Get:6 http://archive.volumio.org jessie/rpi Sources [1132 B] Get:7 http://archive.volumio.org jessie/main armhf Packages [9539 kB] Get:8 http://archive.volumio.org jessie/contrib armhf Packages [43.3 kB] Get:9 http://archive.volumio.org jessie/non-free armhf Packages [88.1 kB] Get:10 http://archive.volumio.org jessie/rpi armhf Packages [1356 B] Get:11 http://archive.volumio.org jessie/main Sources [57.1 kB] Get:12 http://archive.volumio.org jessie/ui Sources [17.4 kB] Get:13 http://archive.volumio.org jessie/main armhf Packages [171 kB] Get:14 http://archive.volumio.org jessie/ui armhf Packages [58.9 kB] Ign http://archive.volumio.org jessie/contrib Translation-en Ign http://archive.volumio.org jessie/main Translation-en Ign http://archive.volumio.org jessie/non-free Translation-en Ign http://archive.volumio.org jessie/rpi Translation-en Ign http://archive.volumio.org jessie/main Translation-en Ign http://archive.volumio.org jessie/ui Translation-en Fetched 18.0 MB in 16s (1083 kB/s) Reading package lists... Done volumio@volumio:~$ volumio@volumio:~$ sudo apt-get upgrade Reading package lists... Done Building dependency tree Reading state information... Done Calculating upgrade... Done The following packages will be upgraded: dhcpcd5 e2fslibs e2fsprogs firmware-ralink libblas-common libblas3 libcairo2 libcomerr2 libdrm2 libfreetype6 liblapack3 liborc-0.4-0 libpam-modules libpam-modules-bin libpam-runtime libpam0g libpango-1.0-0 libpangocairo-1.0-0 libpangoft2-1.0-0 libpixman-1-0 libsdl1.2debian libss2 libva1 x11-common 24 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Need to get 6288 kB of archives. After this operation, 1994 kB of additional disk space will be used. Do you want to continue? [Y/n] y Get:1 http://archive.volumio.org/debian/ jessie/main e2fslibs armhf 1.43.3-1~bpo8+1 [195 kB] Get:2 http://archive.volumio.org/debian/ jessie/main e2fsprogs armhf 1.43.3-1~bpo8+1 [899 kB] Get:3 http://archive.volumio.org/debian/ jessie/main libpam0g armhf 1.1.8-3.1+deb8u2+rpi3 [121 kB] Get:4 http://archive.volumio.org/debian/ jessie/main libpam-modules-bin armhf 1.1.8-3.1+deb8u2+rpi3 [101 kB] Get:5 http://archive.volumio.org/debian/ jessie/main libpam-modules armhf 1.1.8-3.1+deb8u2+rpi3 [288 kB] Get:6 http://archive.volumio.org/debian/ jessie/main libdrm2 armhf 2.4.71-1+rpi1 [32.4 kB] Get:7 http://archive.volumio.org/debian/ jessie/main libfreetype6 armhf 2.6-2rpi1rpi1g [400 kB] Get:8 http://archive.volumio.org/debian/ jessie/main liborc-0.4-0 armhf 1:0.4.22-1rpi1rpi1g [123 kB] Get:9 http://archive.volumio.org/debian/ jessie/ui libpango-1.0-0 armhf 1.36.8-3+rpi1 [274 kB] Get:10 http://archive.volumio.org/debian/ jessie/main libpixman-1-0 armhf 0.33.3+git20151011-7de61d8-rpi1 [156 kB] Get:11 http://archive.volumio.org/debian/ jessie/main libcairo2 armhf 1.14.0-2.1+deb8u2+rpi1 [662 kB] Get:12 http://archive.volumio.org/debian/ jessie/ui libpangoft2-1.0-0 armhf 1.36.8-3+rpi1 [208 kB] Get:13 http://archive.volumio.org/debian/ jessie/ui libpangocairo-1.0-0 armhf 1.36.8-3+rpi1 [197 kB] Get:14 http://archive.volumio.org/debian/ jessie/main libsdl1.2debian armhf 1.2.15-10+rpi1 [162 kB] Get:15 http://archive.volumio.org/debian/ jessie/main libcomerr2 armhf 1.43.3-1~bpo8+1 [62.5 kB] Get:16 http://archive.volumio.org/debian/ jessie/main libpam-runtime all 1.1.8-3.1+deb8u2+rpi3 [213 kB] Get:17 http://archive.volumio.org/debian/ jessie/main libss2 armhf 1.43.3-1~bpo8+1 [65.9 kB] Get:18 http://archive.volumio.org/debian/ jessie/main dhcpcd5 armhf 6.7.1-1+rpi5 [122 kB] Get:19 http://archive.volumio.org/debian/ jessie/main firmware-ralink all 1:0.43+rpi6 [46.1 kB] Get:20 http://archive.volumio.org/debian/ jessie/main libblas-common armhf 3.7.0-1~bpo8+1 [14.1 kB] Get:21 http://archive.volumio.org/debian/ jessie/main libblas3 armhf 3.7.0-1~bpo8+1 [112 kB] Get:22 http://archive.volumio.org/debian/ jessie/main liblapack3 armhf 3.7.0-1~bpo8+1 [1535 kB] Get:23 http://archive.volumio.org/debian/ jessie/main libva1 armhf 1.7.3-2 [46.7 kB] Get:24 http://archive.volumio.org/debian/ jessie/main x11-common all 1:7.7+16 [251 kB] Fetched 6288 kB in 2s (2568 kB/s) perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LANGUAGE = (unset), LC_ALL = (unset), LC_CTYPE = "UTF-8", LANG = (unset) are supported and installed on your system. perl: warning: Falling back to the standard locale ("C"). locale: Cannot set LC_CTYPE to default locale: No such file or directory locale: Cannot set LC_ALL to default locale: No such file or directory debconf: delaying package configuration, since apt-utils is not installed (Reading database ... 20649 files and directories currently installed.) Preparing to unpack .../e2fslibs_1.43.3-1~bpo8+1_armhf.deb ... Unpacking e2fslibs:armhf (1.43.3-1~bpo8+1) over (1.42.12-2) ... Processing triggers for libc-bin (2.19-18+deb8u10) ... Setting up e2fslibs:armhf (1.43.3-1~bpo8+1) ... Processing triggers for libc-bin (2.19-18+deb8u10) ... (Reading database ... 20649 files and directories currently installed.) Preparing to unpack .../e2fsprogs_1.43.3-1~bpo8+1_armhf.deb ... Unpacking e2fsprogs (1.43.3-1~bpo8+1) over (1.42.12-2) ... Setting up e2fsprogs (1.43.3-1~bpo8+1) ... Installing new version of config file /etc/mke2fs.conf ... update-initramfs: deferring update (trigger activated) Processing triggers for initramfs-tools (0.120+deb8u3) ... (Reading database ... 20654 files and directories currently installed.) Preparing to unpack .../libpam0g_1.1.8-3.1+deb8u2+rpi3_armhf.deb ... Unpacking libpam0g:armhf (1.1.8-3.1+deb8u2+rpi3) over (1.1.8-3.1+deb8u2) ... Processing triggers for libc-bin (2.19-18+deb8u10) ... Setting up libpam0g:armhf (1.1.8-3.1+deb8u2+rpi3) ... locale: Cannot set LC_CTYPE to default locale: No such file or directory locale: Cannot set LC_ALL to default locale: No such file or directory Processing triggers for libc-bin (2.19-18+deb8u10) ... (Reading database ... 20654 files and directories currently installed.) Preparing to unpack .../libpam-modules-bin_1.1.8-3.1+deb8u2+rpi3_armhf.deb ... Unpacking libpam-modules-bin (1.1.8-3.1+deb8u2+rpi3) over (1.1.8-3.1+deb8u2) ... Setting up libpam-modules-bin (1.1.8-3.1+deb8u2+rpi3) ... (Reading database ... 20654 files and directories currently installed.) Preparing to unpack .../libpam-modules_1.1.8-3.1+deb8u2+rpi3_armhf.deb ... locale: Cannot set LC_CTYPE to default locale: No such file or directory locale: Cannot set LC_ALL to default locale: No such file or directory Unpacking libpam-modules:armhf (1.1.8-3.1+deb8u2+rpi3) over (1.1.8-3.1+deb8u2) ... Setting up libpam-modules:armhf (1.1.8-3.1+deb8u2+rpi3) ... (Reading database ... 20654 files and directories currently installed.) Preparing to unpack .../libdrm2_2.4.71-1+rpi1_armhf.deb ... Unpacking libdrm2:armhf (2.4.71-1+rpi1) over (2.4.58-2) ... Preparing to unpack .../libfreetype6_2.6-2rpi1rpi1g_armhf.deb ... Unpacking libfreetype6:armhf (2.6-2rpi1rpi1g) over (2.5.2-3+deb8u2) ... Preparing to unpack .../liborc-0.4-0_1%3a0.4.22-1rpi1rpi1g_armhf.deb ... Unpacking liborc-0.4-0:armhf (1:0.4.22-1rpi1rpi1g) over (1:0.4.22-1) ... Preparing to unpack .../libpango-1.0-0_1.36.8-3+rpi1_armhf.deb ... Unpacking libpango-1.0-0:armhf (1.36.8-3+rpi1) over (1.36.8-3) ... Preparing to unpack .../libpixman-1-0_0.33.3+git20151011-7de61d8-rpi1_armhf.deb ... Unpacking libpixman-1-0:armhf (0.33.3+git20151011-7de61d8-rpi1) over (0.32.6-3) ... Preparing to unpack .../libcairo2_1.14.0-2.1+deb8u2+rpi1_armhf.deb ... Unpacking libcairo2:armhf (1.14.0-2.1+deb8u2+rpi1) over (1.14.0-2.1+deb8u2) ... Preparing to unpack .../libpangoft2-1.0-0_1.36.8-3+rpi1_armhf.deb ... Unpacking libpangoft2-1.0-0:armhf (1.36.8-3+rpi1) over (1.36.8-3) ... Preparing to unpack .../libpangocairo-1.0-0_1.36.8-3+rpi1_armhf.deb ... Unpacking libpangocairo-1.0-0:armhf (1.36.8-3+rpi1) over (1.36.8-3) ... Preparing to unpack .../libsdl1.2debian_1.2.15-10+rpi1_armhf.deb ... Unpacking libsdl1.2debian:armhf (1.2.15-10+rpi1) over (1.2.15-10) ... Preparing to unpack .../libcomerr2_1.43.3-1~bpo8+1_armhf.deb ... Unpacking libcomerr2:armhf (1.43.3-1~bpo8+1) over (1.42.12-2) ... Processing triggers for libc-bin (2.19-18+deb8u10) ... Setting up libcomerr2:armhf (1.43.3-1~bpo8+1) ... Processing triggers for libc-bin (2.19-18+deb8u10) ... (Reading database ... 20653 files and directories currently installed.) Preparing to unpack .../libpam-runtime_1.1.8-3.1+deb8u2+rpi3_all.deb ... Unpacking libpam-runtime (1.1.8-3.1+deb8u2+rpi3) over (1.1.8-3.1+deb8u2) ... Setting up libpam-runtime (1.1.8-3.1+deb8u2+rpi3) ... locale: Cannot set LC_CTYPE to default locale: No such file or directory locale: Cannot set LC_ALL to default locale: No such file or directory (Reading database ... 20653 files and directories currently installed.) Preparing to unpack .../libss2_1.43.3-1~bpo8+1_armhf.deb ... Unpacking libss2:armhf (1.43.3-1~bpo8+1) over (1.42.12-2) ... Processing triggers for libc-bin (2.19-18+deb8u10) ... Setting up libss2:armhf (1.43.3-1~bpo8+1) ... Processing triggers for libc-bin (2.19-18+deb8u10) ... (Reading database ... 20653 files and directories currently installed.) Preparing to unpack .../dhcpcd5_6.7.1-1+rpi5_armhf.deb ... Unpacking dhcpcd5 (6.7.1-1+rpi5) over (6.0.5-2) ... Preparing to unpack .../firmware-ralink_1%3a0.43+rpi6_all.deb ... Unpacking firmware-ralink (1:0.43+rpi6) over (20161130-4~deb8u1) ... dpkg: error processing archive /var/cache/apt/archives/firmware-ralink_1%3a0.43+rpi6_all.deb (--unpack): trying to overwrite '/lib/firmware/rt2661.bin', which is also in package firmware-misc-nonfree 20161130-4~deb8u1 Preparing to unpack .../libblas-common_3.7.0-1~bpo8+1_armhf.deb ... Unpacking libblas-common (3.7.0-1~bpo8+1) over (1.2.20110419-10) ... Preparing to unpack .../libblas3_3.7.0-1~bpo8+1_armhf.deb ... Unpacking libblas3 (3.7.0-1~bpo8+1) over (1.2.20110419-10) ... Preparing to unpack .../liblapack3_3.7.0-1~bpo8+1_armhf.deb ... Unpacking liblapack3 (3.7.0-1~bpo8+1) over (3.5.0-4) ... Preparing to unpack .../libva1_1.7.3-2_armhf.deb ... Unpacking libva1:armhf (1.7.3-2) over (1.4.1-1) ... Preparing to unpack .../x11-common_1%3a7.7+16_all.deb ... Unpacking x11-common (1:7.7+16) over (1:7.7+7) ... Processing triggers for systemd (215-17+deb8u8) ... Processing triggers for libc-bin (2.19-18+deb8u10) ... Errors were encountered while processing: /var/cache/apt/archives/firmware-ralink_1%3a0.43+rpi6_all.deb E: Sub-process /usr/bin/dpkg returned an error code (1) volumio@volumio:~$ git clone git://git.drogon.net/wiringPi Cloning into 'wiringPi'... remote: Counting objects: 1199, done. remote: Compressing objects: 100% (999/999), done. remote: Total 1199 (delta 837), reused 212 (delta 142) Receiving objects: 100% (1199/1199), 371.42 KiB | 0 bytes/s, done. Resolving deltas: 100% (837/837), done. Checking connectivity... done. volumio@volumio:~$ cd wiringPi volumio@volumio:~/wiringPi$ git pull origin Already up-to-date. volumio@volumio:~/wiringPi$ cd volumio@volumio:~$ cd volumio@volumio:~$ git clone https://github.com/iqaudio/tools Cloning into 'tools'... remote: Enumerating objects: 113, done. remote: Total 113 (delta 0), reused 0 (delta 0), pack-reused 113 Receiving objects: 100% (113/113), 49.12 KiB | 0 bytes/s, done. Resolving deltas: 100% (52/52), done. Checking connectivity... done. volumio@volumio:~$ ls tools wiringPi volumio@volumio:~$ cd tools volumio@volumio:~/tools$ ls ButtonPress.py IQ_ir IQ_rot README.md IQSetupMix.c IQ_ir.c IQ_rot.c cosmiccontroller.py volumio@volumio:~/tools$ sudo IQ_rot [sudo] password for volumio: sudo: IQ_rot: command not found volumio@volumio:~/tools$ cd volumio@volumio:~$ sudo IQ_rot sudo: IQ_rot: command not found

"Unable to determine hardware version." after System Update

Hey, I've updated my Raspberry Pi B+ to the latest versions yesterday.

root@raspberrypi:~# uname -a
Linux raspberrypi 4.9.24-v7+ #993 SMP Wed Apr 26 18:01:23 BST 2017 armv7l GNU/Linux

root@raspberrypi:~# cat /etc/os-release
PRETTY_NAME="Raspbian GNU/Linux 8 (jessie)"
NAME="Raspbian GNU/Linux"
VERSION_ID="8"
VERSION="8 (jessie)"
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"

This also updated wiringPi to version 2.44.

Now, whenever I try to start IQ_rot, I get the following message:

root@raspberrypi:~# /home/pi/iqaudio/tools/IQ_rot
IQaudIO.com Pi-DAC Volume Control support Rotary Encoder) v1.5 Aug 30th 2015

Unable to determine hardware version. I see: Hardware   : BCM2835
,
 - expecting BCM2708 or BCM2709.
If this is a genuine Raspberry Pi then please report this
to [email protected]. If this is not a Raspberry Pi then you
are on your own as wiringPi is designed to support the
Raspberry Pi ONLY.

and then it exits.

Update volume level in Volumio 2 UI

Hi,
I've taken the liberty to fork your project and make some minor modifications in the code in IQ_rot.c so that the change in volume level is reflected in the UI. Please review it if you get the time and give your suggestions.
Thanks.

Pi 3 struggling to get sudo IQ_ir& working

Hi,
I have the DAC+ and am attempting to control the volume using Infrared. My only previous programming experience is Cobol. I have had a good time playing with Python et al. I am using the DAC+ to listen to flac files and internet radio using mpd and some python code to control things.

I have installed an IR receiver on the "black" DAC+ card. I setup the boot/config.txt as follows
dtoverlay=lirc-rpi:gpio_in_pin=25,gpio_in_pull=down
I have installed lirc and set it up and it is working with the IR receiver (i get stuff when I use irx and press the keys on my remote that I have mapped in my lircd.conf.

So I thought I would use the code provided to manipulate the volume.

I have cloned the code into a dir "tools". If i do sudo IQ_ir& it fails "sudo: IQ_ir: command not found"

I wasn't surprised because in alsamixer the volume control is shown as "Digital" rather than PCM. So I changed IQ_ir.c and IQSetupMix.c to use "Digital". I then compiled IQSetupMix.c using the instructions in the file. Compiled clean. Then compiled IQ_ir.c which compiles with warnings
(compiled these with the cli in issue 4 that discusses compiling)
gcc -include /usr/include/lirc/lirc_client.h -o IQ_ir IQ_ir.c -llirc_client -lasound -lwiringPi
IQ_ir.c:36:0: warning: "TRUE" redefined
#define TRUE 1
^
In file included from IQ_ir.c:17:0:
/usr/include/wiringPi.h:32:0: note: this is the location of the previous definition

define TRUE (1==1)

^
IQ_ir.c:37:0: warning: "FALSE" redefined
#define FALSE 0
^
In file included from IQ_ir.c:17:0:
/usr/include/wiringPi.h:33:0: note: this is the location of the previous definition

define FALSE (!TRUE)

^
If I sudo IQ_ir& i get the same failure as above

Frankly I am pretty lost.
So I am wondering

  1. Any idea regarding how I can proceed to get IQ_ir.c to work
    or
  2. Can you advise whether I can use python to do the same thing - finding it relatively easy to understand compared to C.

Thank You in advance.

Fork

Hi,
I forked your code and have added command line input and a bit more functionality. I broke the fork because I don't know how to use git very well and couldn't get rid of some files that I uploaded. If you want to pull it back then feel free or just leave it with me to develop a bit more. It's at alidaf/raspberryPi. I took a bit of a liberty by licensing it as GPL2. If that isn't compatible with any licensing restrictions you have then let me know. I've renamed it as rotencvol as it can be used without the IQaudioDAC.
Regards.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.