Go to advanced search

by jwatte
Sun Sep 02, 2018 5:53 pm
Forum: Camera board
Topic: Is there a flexible cable for the RPi Camera?
Replies: 4
Views: 1717

Re: Is there a flexible cable for the RPi Camera?

The cables worked fine for me!
by jwatte
Sun Mar 11, 2018 11:41 pm
Forum: Advanced users
Topic: Is there a race condition in the pthread_condvar implementation?
Replies: 1
Views: 622

Re: Is there a race condition in the pthread_condvar implementation?

I figured out approximately what was causing this weird problem. I was using a software rendering library that didn't clip input parameters, and thus rendered outside the pixel buffer. This ended up overwriting a variety of globals and perhaps even some stack variables, which would then cause random...
by jwatte
Sun Mar 11, 2018 9:14 pm
Forum: Advanced users
Topic: Is there a race condition in the pthread_condvar implementation?
Replies: 1
Views: 622

Is there a race condition in the pthread_condvar implementation?

I have an application that uses "desktop GL" mode with fake KMS. It captures data from the camera, and displays it in a GL window, after processing. When I furiously click on the window while this process is going, the hand-off between capture and display locks up. Looking at the involved threads, h...
by jwatte
Sat Jan 20, 2018 6:55 pm
Forum: Troubleshooting
Topic: Pi 3 intermittent boot failure; dmesg warning when suceeding
Replies: 0
Views: 545

Pi 3 intermittent boot failure; dmesg warning when suceeding

I am using a Pi 3, attached to a Waveshare 7" 1024x640 HDMI/USB touchscreen, Ethernet, Logitech keyboard/mouse dongle, and 64 GB USB memory stick mounted on /var/tmp. I use fake KMS desktop GL, because I also use the camera, but need to run a non-ES (windowed) GL program. There is also a Teensy 3.2 ...
by jwatte
Sun Dec 31, 2017 4:59 am
Forum: Troubleshooting
Topic: Raspberry Pi 3 UART doesn't pull TXD high
Replies: 8
Views: 1438

Re: Raspberry Pi 3 UART doesn't pull TXD high

Latest Raspbian (from 2017-11-29) re-imaged boots, and pulls both TXD and RXD high.
The previous image was older, and had been apt-get updated and dist-upgraded regularly, so apparently that's not good enough?
by jwatte
Sun Dec 31, 2017 3:35 am
Forum: Troubleshooting
Topic: Raspberry Pi 3 UART doesn't pull TXD high
Replies: 8
Views: 1438

Re: Raspberry Pi 3 UART doesn't pull TXD high

Okay, so what software configuration is wrong, in that the TXD (pin 8 on the header) of the Pi doesn't go high, even though I have enabled the UART? I have simplified the config.txt slightly, to the following: disable_overscan=1 # Enable audio (loads snd_bcm2835) #dtparam=audio=on start_x=1 gpu_mem=...
by jwatte
Fri Dec 29, 2017 11:11 pm
Forum: Troubleshooting
Topic: Raspberry Pi 3 UART doesn't pull TXD high
Replies: 8
Views: 1438

Re: Raspberry Pi 3 UART doesn't pull TXD high

Boards bad? According to other threads related to bad UARTs on this forum, some Pis had some kind of accidental junction (solder junction?) between the pin and GND. That would certainly cause the TXD to not go high! However, I see the same behavior from a brand new Pi 3 I just got from Element14, s...
by jwatte
Fri Dec 29, 2017 11:07 pm
Forum: Troubleshooting
Topic: Raspberry Pi 3 UART doesn't pull TXD high
Replies: 8
Views: 1438

Re: Raspberry Pi 3 UART doesn't pull TXD high

Thanks for the answer: [13:54] pi@crunch:~ $ sudo apt-get install pigpio Reading package lists... Done Building dependency tree Reading state information... Done pigpio is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. [13:55] pi@crunch:~ $ sudo pigpiod [1...
by jwatte
Fri Dec 29, 2017 7:30 pm
Forum: Troubleshooting
Topic: Raspberry Pi 3 UART doesn't pull TXD high
Replies: 8
Views: 1438

Raspberry Pi 3 UART doesn't pull TXD high

I'm using a Raspberry Pi 3 with latest Raspbian. I have disabled console on the UART, but enabled UART swapping and turbo mode in config.txt. I am hooking a scope to pins 8 and 10. It seems like pin 8 doesn't ever go high (idle.) The serial devices exist, and are linked appropriately: [11:11] pi@cru...
by jwatte
Fri Nov 24, 2017 2:11 am
Forum: OpenGLES
Topic: GLES gets super slow when also running video capture
Replies: 6
Views: 3591

Re: GLES gets super slow when also running video capture

I finally got to measure this change, and it made a huge difference! Awesome!
Thank you, @6by9.
by jwatte
Tue Oct 31, 2017 6:25 pm
Forum: OpenGLES
Topic: GLES gets super slow when also running video capture
Replies: 6
Views: 3591

Re: GLES gets super slow when also running video capture

Thanks, that sounds like something I should try!
by jwatte
Tue Oct 31, 2017 4:53 pm
Forum: OpenGLES
Topic: GLES gets super slow when also running video capture
Replies: 6
Views: 3591

Re: GLES gets super slow when also running video capture

This is not at all doing what I'm doing, so I don't understand how it would help?
Could you be a little more specific in what you think the problem is, and how this link helps illustrate a possible solution?
by jwatte
Sun Oct 22, 2017 3:00 pm
Forum: OpenGLES
Topic: GLES gets super slow when also running video capture
Replies: 6
Views: 3591

Re: GLES gets super slow when also running video capture

It is very clear -- when the VideoCore gets busy, the OpenGL layer starts taking a long time for each command. Is there some way to batch up all commands in the stream and let them go at the end, so I don't have to wait for VC turn-around more than once per frame? Also, is there any documentation on...
by jwatte
Thu Oct 19, 2017 4:38 am
Forum: OpenGLES
Topic: GLES gets super slow when also running video capture
Replies: 6
Views: 3591

GLES gets super slow when also running video capture

I have set up the video capture to capture at 640x480, at 90 fps. I also use the h264 encoder. The "preview" output is set to send YUV420 data to the ARM side. I don't need screen preview, but I need the data for analysis, and this seems more efficient than using a splitter like RaspiVid does. Now, ...
by jwatte
Thu Oct 19, 2017 1:05 am
Forum: Graphics programming
Topic: hello_videocube.bin runs at 1-2 fps
Replies: 2
Views: 1248

Re: hello_videocube.bin runs at 1-2 fps

Thank you. A fresh update to latest did indeed fix it. Super weird! Now, I'm still somewhat stuck on GLES being slow as soon as I touch some resource that's used in the frame. Uploading a texture each frame, or updating a vertex buffer object each frame, seems to stall the renderer, getting low-ish ...
by jwatte
Wed Oct 18, 2017 2:14 am
Forum: Graphics programming
Topic: How to free unused dispmanx layer (in case of SIGSEGV)
Replies: 7
Views: 3088

Re: How to free unused dispmanx layer (in case of SIGSEGV)

last state of this dispmanx layer is still present on display
Are you sure the process has actually died? If you check for it with "ps aux | grep <procname>" is it still alive?
It sounds like a pretty bad driver bug if somehow the OS lets resources stay allocated after a process goes away.
by jwatte
Wed Oct 18, 2017 2:09 am
Forum: Graphics programming
Topic: hello_videocube.bin runs at 1-2 fps
Replies: 2
Views: 1248

hello_videocube.bin runs at 1-2 fps

I have a Raspberry Pi 3. It's been running Raspbian for many months, and I've been having okay success using GLES2 to drive a small display. However, recently I did a full update -- apt-get update, apt-get upgrade, raspi-config -> update Now, my program runs at < 1 fps. The hello_videocube.bin demo ...
by jwatte
Mon Sep 04, 2017 2:01 am
Forum: Troubleshooting
Topic: glTexSubImage2D() using GLES2.0 hangs
Replies: 0
Views: 314

glTexSubImage2D() using GLES2.0 hangs

I am running into a problem, where glTexSubImage2D() seems to hang the very first time it's called. My code will first create a MIP map cascade for a texture, using NULL arguments to glTexImage2D() to allocate the RAM without filling it in. Then, it will actually attempt to put the data in, using gl...
by jwatte
Mon Sep 04, 2017 1:43 am
Forum: Troubleshooting
Topic: Raspberry PI3 B+ overheating
Replies: 9
Views: 3903

Re: Raspberry PI3 B+ overheating

BS170 is a good cheap MOSFET if you want to use that instead. It's also called 2N7000. Another idea is to put the Pi on its side, and orient the heat sinks so that the air can flow from down to up in that orientation. (Orientation is impotant for E-profile heat sinks; not important for pin-profile h...
by jwatte
Sun Aug 27, 2017 11:50 pm
Forum: Camera board
Topic: How to use a MMAL buffer as GLES texture?
Replies: 2
Views: 809

Re: How to use a MMAL buffer as GLES texture?

Perfect; thanks! I've been working in RaspiVid a whole lot, and wasn't thinking to look in RaspiStill :-)
by jwatte
Sun Aug 27, 2017 10:02 pm
Forum: Camera board
Topic: How to use a MMAL buffer as GLES texture?
Replies: 2
Views: 809

How to use a MMAL buffer as GLES texture?

Looking through the "userspace" repository and the "hello_pi" source code examples, I can't find something that combines using MMAL to capture video from the camera, and then mapping that as a GLES texture. The few examples of "video into textures" I can find use OpenIL, and hello_videocube uses vid...
by jwatte
Sun Aug 27, 2017 9:43 pm
Forum: Camera board
Topic: How to use a MMAL buffer as GLES texture?
Replies: 0
Views: 400

How to use a MMAL buffer as GLES texture?

Looking through the "userspace" repository and the "hello_pi" source code examples, I can't find something that combines using MMAL to capture video from the camera, and then mapping that as a GLES texture. The few examples of "video into textures" I can find use OpenIL, and hello_videocube uses vid...
by jwatte
Thu Aug 10, 2017 11:45 pm
Forum: Troubleshooting
Topic: Getting Teensy 3.2 USB Audio working
Replies: 1
Views: 857

Re: Getting Teensy 3.2 USB Audio working

snd-usb-audio 1-1.5:1.2: cannot find the slot for index 0 (range 0-0), error: -16 The answer is that the USB audio module wants sound card slot 0 for the first USB audio device, but that slot is already taken by the BCM host audio. The fix is to create a new file such as /etc/modprobe.d/snd_usb_aud...
by jwatte
Thu Aug 10, 2017 11:43 pm
Forum: Raspbian
Topic: How do I select my USB Sound Card for output?
Replies: 8
Views: 29779

Re: How do I select my USB Sound Card for output?

The ALSA parameters have moved into other places (such as /usr/share/alsa) However, the reason the Teensy doesn't by default succeed in loading, is that the snd_usb_audio module wants "index 0" that's already taken by the BCM audio. The fix is to create a new file in modprobe.d (I call mine /etc/mod...
by jwatte
Tue Aug 08, 2017 11:12 pm
Forum: Troubleshooting
Topic: Getting Teensy 3.2 USB Audio working
Replies: 1
Views: 857

Getting Teensy 3.2 USB Audio working

I'm hooking a Teensy 3.2 board up to a Raspberry Pi 2 B. I'm using Raspbian updated last month. (debian_version says 8.0, uname -a says Linux robot-raspberrypi 4.9.35-v7+ #1014 SMP Fri Jun 30 14:47:43 BST 2017 armv7l GNU/Linux) I am building an "Audio" sketch for the Teensy, which makes it appear as...

Go to advanced search