Go to advanced search

by HiassofT
Thu Sep 12, 2019 6:23 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: STICKY: The I2S sound thread.
Replies: 924
Views: 453518

Re: STICKY: The I2S sound thread.

Rather than spend all the time developing my own driver and figuring out how to interface it, do you know of any built-in driver that has an I2S client with I2C master? There are plenty - eg pcm512x or wm8804 are common codecs and used in several RPi audio cards. If you use one of these chips you c...
by HiassofT
Sun Aug 18, 2019 9:00 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: ANNOYING I2S modes
Replies: 1
Views: 922

Re: ANNOYING I2S modes

Read through the various device tree overlay examples using simple audio card or audio graph card posted in the I2S thread https://www.raspberrypi.org/forums/view ... =44&t=8496

bcm2835-i2s slave mode can be easily set by setting bitclock and frameclock master to the codec.

so long,

Hias
by HiassofT
Mon Aug 05, 2019 7:35 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: STICKY: The I2S sound thread.
Replies: 924
Views: 453518

Re: STICKY: The I2S sound thread.

Have a look at the kernel documentation - Documentation/sound in the kernel tree or online here: https://www.kernel.org/doc/html/v4.19/sound/index.html "Writing an ALSA driver" is a good start, it contains also info what hw_parans should do and how ALSA in general works. The ASoC sections may also b...
by HiassofT
Thu Aug 01, 2019 10:56 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: STICKY: The I2S sound thread.
Replies: 924
Views: 453518

Re: STICKY: The I2S sound thread.

You need to have a codec driver that handles sample rate / clock switching (in .hwparams). That stuff is very specific to the codec / clock generator you are using (some use I2C, some SPI, some a bunch of GPIOs) so unless you are using some codec that's already supported in linux you need to write o...
by HiassofT
Wed Jul 24, 2019 5:24 pm
Forum: Advanced users
Topic: Does LIRC support hardware PWM?
Replies: 3
Views: 213

Re: Does LIRC support hardware PWM?

yes, if you use the pwm-ir-tx dtoverlay instead of gpio-ir-tx

so long,

Hias
by HiassofT
Wed Jul 24, 2019 9:30 am
Forum: Troubleshooting
Topic: New Lirc (0.10.1-5.2) is not working on Raspbian
Replies: 3
Views: 290

Re: New Lirc (0.10.1-5.2) is not working on Raspbian

This sounds a lot like you are hitting this Debian packaging bug: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=932779 Fortunately, the bug report mentions a simple workaround: when the installation fails, manually create the lirc_options.conf file: sudo cp /etc/lirc/lirc_options.conf.dist /etc/...
by HiassofT
Fri Jul 19, 2019 11:40 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: STICKY: The I2S sound thread.
Replies: 924
Views: 453518

Re: STICKY: The I2S sound thread.

No, you are not missing anything. bcm2835-i2s will only transfer (max) 2 samples/channels per frame - this is what I meant with "stereo only".

You'll have to use one of the tricks I posted to pack 4 stereo frames into an 8-channel one.

so long,

Hias
by HiassofT
Fri Jul 19, 2019 11:15 am
Forum: General discussion
Topic: Pi 4 firmware, software stability improvements
Replies: 83
Views: 17896

Re: Pi 4 firmware, software stability improvements

My eyes are a tad weird. To me, less than 50Hz is not smooth; I can look at a source and more or less immediately tell you if it's 24/25, 30, 50, or 60. It's not only your eyes. (almost) all people perceive it that way. For desktop use a simple test is to scroll a document/webpage/... At 60Hz (whic...
by HiassofT
Fri Jul 19, 2019 9:37 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: STICKY: The I2S sound thread.
Replies: 924
Views: 453518

Re: STICKY: The I2S sound thread.

Setting up the interface at four-times stereo rate is a good start. If you run the bcm2835-i2s in clock slave mode FSLEN doesn't matter, it only check for the leading LRCLK edge. Just set it up as usual (eg 1 for DSP mode or sample length for I2S). There is a quirk in bcm2835-i2s, once it's seen a L...
by HiassofT
Thu Jul 18, 2019 12:29 pm
Forum: General discussion
Topic: Usefull / good programs to have on your Pi
Replies: 22
Views: 1449

Re: Usefull / good programs to have on your Pi

HermannSW wrote:
Thu Jul 18, 2019 7:32 am
Another reason is that Salea logic analyzer software does not run on arm as well :-(
You could give sigrok a try, it's in Raspbian repo and supports a bunch of Salae logic analyzers https://sigrok.org/wiki/Supported_hardware

so long,

Hias
by HiassofT
Thu Jul 18, 2019 10:46 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: STICKY: The I2S sound thread.
Replies: 924
Views: 453518

Re: STICKY: The I2S sound thread.

With bare metal code you can completely ignore the DT overlays, unless you have some code to interpret the FDT passed in from the bootloader. With Linux the DT overlays are used to configure the linux drivers. Concerning TDM: While the bcm I2S block offers very flexible configuration it doesn't supp...
by HiassofT
Tue Jul 09, 2019 3:28 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: STICKY: The I2S sound thread.
Replies: 924
Views: 453518

Re: STICKY: The I2S sound thread.

You may need to use bitclock-master and frame-master properties with the codec phandle in the CPU node, like this: cpu_port: port { cpu_endpoint: endpoint { remote-endpoint = <&codec_endpoint>; frame-master = <&codec_endpoint>; bitclock-master = <&codec_endpoint>; dai-format = "i2s"; }; }; Not sure ...
by HiassofT
Tue Jul 09, 2019 2:22 pm
Forum: Advanced users
Topic: Pi4 vs Pi3 Audio Performance
Replies: 9
Views: 1128

Re: Pi4 vs Pi3 Audio Performance

Can you check with a WAV file and play it with "aplay -v 1khz.wav"?

Please test this on RPi3 Stretch, RPi3 Buster and RPi4 Buster and post the output of above command and your THD measurements.

Could well be that Audacity in Buster behaves differently to the version from Stretch.

so long,

Hias
by HiassofT
Mon Jul 08, 2019 5:54 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: STICKY: The I2S sound thread.
Replies: 924
Views: 453518

Re: STICKY: The I2S sound thread.

bitclock-slave and frame-slave aren't valid device tree properties, so they'll be simply ignored. You have to set bitclock-master and frame-master on the other (codec) endpoint instead. see https://github.com/raspberrypi/linux/blob/rpi-4.19.y/Documentation/devicetree/bindings/sound/audio-graph-card....
by HiassofT
Mon Jul 08, 2019 11:38 am
Forum: Raspbian
Topic: Raspbian Buster Lite on RPi2B cannot update/upgrade trough apt
Replies: 9
Views: 1269

Re: Raspbian Buster Lite on RPi2B cannot update/upgrade trough apt

Raspbian Lite on my RPi4 and Debian Buster on my x86 PC didn't interactively ask me if I'd like to accept the release info change, but using the --allow-releaseinfo-change option worked fine (you'll only need to do this once) sudo apt-get --allow-releaseinfo-change update Edit: this is how it looked...
by HiassofT
Tue Jul 02, 2019 9:53 pm
Forum: General discussion
Topic: Raspberry Pi 4 Thread - general discussion
Replies: 861
Views: 87532

Re: Raspberry Pi 4 Thread - general discussion

Sorry, I'm not going to run random bash scripts from the internet. I used the commands as on the Raspberry Pi Dramble microSD benchmarks site. Most benchmarkers though recommend to set the performance governor as ondemand can skew the results and make them impossible to compare - see the update to m...
by HiassofT
Tue Jul 02, 2019 9:22 pm
Forum: General discussion
Topic: Raspberry Pi 4 Thread - general discussion
Replies: 861
Views: 87532

Re: Raspberry Pi 4 Thread - general discussion

ok, Is this a better solution? Can someone here please go to https://www.pidramble.com/wiki/benchmarks/microsd-cards or here https://www.raspberrypi.org/forums/viewtopic.php?f=63&t=140461 and use one of the methods listed on this page to get a good reading from their Pi 4 for the SD card speed and ...
by HiassofT
Sun Jun 30, 2019 9:27 pm
Forum: General discussion
Topic: Kodi is broken on raspbian buster
Replies: 28
Views: 5613

Re: Kodi is broken on raspbian buster

Thanks for the info, I read about it in Kodi and LibreElec forums, and I already saw the new branch in popcornmix github. One question: compiling this branch against the Mesa libs, will it work on the older Pies using the vc4-fkms ? I haven't tested that myself yet - we kept older RPis builds as is...
by HiassofT
Sun Jun 30, 2019 8:41 pm
Forum: General discussion
Topic: Kodi is broken on raspbian buster
Replies: 28
Views: 5613

Re: Kodi is broken on raspbian buster

Kodi 18 isn't quite there yet with support for the new (v4l2) video drivers, this will be tackled in Kodi 19 (maybe stuff can be backported to Kodi 18, but it's way too early to tell). Also there's no HEVC v4l2 decoder at the moment (only an ffmpeg userspace implementation, which works quite fine th...
by HiassofT
Sun Jun 30, 2019 8:48 am
Forum: General discussion
Topic: Not all RPI 4's are equal?
Replies: 34
Views: 3847

Re: Not all RPI 4's are equal?

300mW, not 300mA :-) so about 60mA less.

These are the screenshots from my bench top power supply, setup to output 5.1V:

current release firmware:
00013701.png
00013701.png (3.56 KiB) Viewed 2178 times
updated testing firmware:
000137a8.png
000137a8.png (3.58 KiB) Viewed 2178 times
so long,

Hias
by HiassofT
Sun Jun 30, 2019 8:31 am
Forum: General discussion
Topic: Not all RPI 4's are equal?
Replies: 34
Views: 3847

Re: Not all RPI 4's are equal?

To clarify things: RPi4 not only has an upgradeable bootloader in an SPI EEPROM but also the VIA USB3 controller has upgradeable firmware in an EEPROM - the latter is what the CNX article is talking about. I also did some quick tests with the newer USB controller firmware (which is currently in inte...
by HiassofT
Tue Jun 25, 2019 8:04 pm
Forum: General discussion
Topic: Raspberry Pi 4 Thread - general discussion
Replies: 861
Views: 87532

Re: Raspberry Pi 4 Thread - general discussion

I was using and adapter then used a cable from Sony 4K camcorder in both cases it does 4K 30 at most, I know is not the cable or the adapter, in any case I went with 1080p 60 and the experience was not good at all What kind of TV are you using? I ran into a similar issue when testing LibreELEC on m...
by HiassofT
Sat Jun 01, 2019 9:39 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: How to enable CTS RTS for Raspberry Pi 3 b+ UART
Replies: 5
Views: 605

Re: How to enable CTS RTS for Raspberry Pi 3 b+ UART

For the PL011 (/dev/ttyAMA0) UART use the uart-ctsrts overlay from the github link I posted above.

so long,

Hias
by HiassofT
Wed May 29, 2019 12:24 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: How to enable CTS RTS for Raspberry Pi 3 b+ UART
Replies: 5
Views: 605

Re: How to enable CTS RTS for Raspberry Pi 3 b+ UART

You can do this with a small, custom device tree overlay file. A couple of months ago I faced the same issue and created a bunch of overlays - you can download them from here https://github.com/HiassofT/AtariSIO/tree/master/contrib/rpi For ttyS0 you need to copy "miniuart-ctsrts.dtbo" to /boot/overl...
by HiassofT
Thu May 23, 2019 8:37 am
Forum: HATs and other add-ons
Topic: Cirrus Logic Sound Card for R-Pi3 control issue
Replies: 8
Views: 527

Re: Cirrus Logic Sound Card for R-Pi3 control issue

You can control the headphone output volume with "HPOUT1 Digital", the lineout volume with "HPOUT2 Digital". When recording audio adjust "IN3L" and "IN3R" for line-in - there are separate controls for left/right. The WM5102 chip supports very complex signal routing, therefore I wrote a bunch of (she...

Go to advanced search