Go to advanced search

by knute
Sun Jun 16, 2019 4:24 pm
Forum: Automation, sensing and robotics
Topic: How do I take a monitor screen and have the Pi be able to "watch it"
Replies: 1
Views: 75

Re: How do I take a monitor screen and have the Pi be able to "watch it"

I know that you can capture an image of a portion of the screen with Java. I assume that other languages have methods to do that as well.
by knute
Sat Jun 15, 2019 5:52 pm
Forum: Java
Topic: Having Trouble Stopping Audio Capture with Java
Replies: 1
Views: 118

Re: Having Trouble Stopping Audio Capture with Java

You don't say what device the TargetDataLine is connected to. If connected to a device such as a microphone, drain() will never return because the mixer connected to the microphone will continue to send data to the TargetDataLine's buffer which drain() will attempt to empty but never succeed. Just c...
by knute
Thu Jun 13, 2019 8:56 pm
Forum: Java
Topic: JavaFX application not working on Raspbian Stretch/Raspberry Pi Zero W 1.1
Replies: 8
Views: 6403

Re: JavaFX application not working on Raspbian Stretch/Raspberry Pi Zero W 1.1

ralphcorrales wrote:
Tue Jun 11, 2019 7:18 am
Have you succeeded in building OpenJFX for ARM Hard Float? Or don't you need anymore? Apparently, I lack skills to do that...
You don't have to build it, just install it:

apt install openjdk-8-jdk openjfx

and you are good to go.
by knute
Wed May 15, 2019 9:54 pm
Forum: Advanced users
Topic: Raspberry pi socket connection delay for receiving message.
Replies: 4
Views: 249

Re: Raspberry pi socket connection delay for receiving message.

I'm not sure what is causing your problem but you could send some dummy messages every so often and maybe that would keep things tuning along nicely when you need it?
by knute
Fri May 10, 2019 9:44 pm
Forum: General discussion
Topic: Execute Java code with inputs
Replies: 1
Views: 71

Re: Execute Java code with inputs

Take a look at the java.io.Console class.
by knute
Thu May 09, 2019 9:34 pm
Forum: Troubleshooting
Topic: enabling perl
Replies: 18
Views: 552

Re: enabling perl

... if you follow the instructions I gave above. Some of those instructions are unsafe. The script should not be owned by www-data, in the group www-data, or in any way writable by the account www-data. You could make the script readable and executable and not writable by the owner www-data but it ...
by knute
Thu May 09, 2019 5:11 pm
Forum: Troubleshooting
Topic: enabling perl
Replies: 18
Views: 552

Re: enabling perl

It seems that CGI in other directories is disabled by default in Apache 2.4! apache can't access files that it doesn't own or have permission to access. You can put the cgi files anywhere you want as long as apache can read and/or execute them. sudo a2enmod cgi and Options +ExecCGI Addhandler cgi-s...
by knute
Tue May 07, 2019 1:32 pm
Forum: C/C++
Topic: GCC 9.1 released
Replies: 26
Views: 2638

Re: GCC 9.1 released

Is there an uninstall script in case one doesn't like it?
by knute
Mon May 06, 2019 8:10 pm
Forum: Troubleshooting
Topic: enabling perl
Replies: 18
Views: 552

Re: enabling perl

I didn't compile it myself but I got it running with the info here: https://perl.apache.org/docs/2.0/user/i ... _fast.html

There is however an error in their configuration file and it won't work with it. That took me a while to figure out. If you want instructions let me know.
by knute
Thu May 02, 2019 7:54 pm
Forum: Other programming languages
Topic: Perl module Rpi::PIGPIO?
Replies: 0
Views: 245

Perl module Rpi::PIGPIO?

So I found this webpage: https://metacpan.org/pod/RPi::PIGPIO and wondered if there is a package for the Pi to get this Perl module or if I have to download it with CPAN?
by knute
Thu May 02, 2019 7:37 pm
Forum: Troubleshooting
Topic: enabling perl
Replies: 18
Views: 552

Re: enabling perl

DougieLawson wrote:
Thu May 02, 2019 6:23 pm
libcgi-pm-perl is an excellent module that makes writing Perl common gateway interface programs easier. It's not the stuff to get Perl running under Apache2.
Can you point me to some documentation on libcgi-pm-perl? I'm clearly not looking in the right place.

Thanks!
by knute
Thu May 02, 2019 6:20 pm
Forum: Troubleshooting
Topic: enabling perl
Replies: 18
Views: 552

Re: enabling perl

You don't need either file. sudo apt install apache2 sudo a2enmod cgid sudo systemctl restart apache2 create your perl script and put it in /usr/lib/cgi-bin set owner and group to www-data: sudo chown www-data:www-data set executable: sudo chmod 750 point your browser to: localhost/cgi-bin/test.pl i...
by knute
Thu May 02, 2019 3:35 pm
Forum: Graphics, sound and multimedia
Topic: Low level sound API documentation
Replies: 3
Views: 271

Re: Low level sound API documentation

I wrote a simple point to point intercom for the Pi and Windows using JavaSound. It is simple to program and has the advantage of running the same code on both systems. You can see the code here: pi.knutejohnson.com.
by knute
Mon Apr 29, 2019 9:23 pm
Forum: Beginners
Topic: Finding small monitors
Replies: 6
Views: 302

Re: Finding small monitors

Thanks!
by knute
Mon Apr 29, 2019 1:34 am
Forum: Beginners
Topic: Finding small monitors
Replies: 6
Views: 302

Re: Finding small monitors

Waveshare makes some nice little screens. I've got a touch screen that is the same dimensions as the Pi and works great. Guess it kind of depends on what you want to show.

What is pen testing?
by knute
Mon Apr 29, 2019 1:20 am
Forum: General discussion
Topic: Learning to code with Pi.
Replies: 5
Views: 274

Re: Learning to code with Pi.

And the best way to learn how to code is to code! It's like playing a musical instrument, practice, practice, practice...
by knute
Wed Apr 24, 2019 1:40 pm
Forum: Other projects
Topic: Setup button and programing in JAVA
Replies: 1
Views: 86

Re: Setup button and programing in JAVA

I'm not sure what your problem with your circuit is but I would change the way it works to use a pull up on the input pin and then just ground the gpio pin with the button. No resistor needed.
by knute
Mon Apr 22, 2019 9:12 pm
Forum: Advanced users
Topic: Simple GUI config - wifi, IP, timezone
Replies: 3
Views: 205

Re: Simple GUI config - wifi, IP, timezone

I can think of a lot of ways to do this but off the top of my head, I would say run your configuration program as a desktop entry and once the user enters the applicable data, write a message to a file that says it has been set or erase the desktop entry or? You could have another icon on the deskto...
by knute
Sat Apr 13, 2019 5:03 pm
Forum: Automation, sensing and robotics
Topic: Looking for help with DHT11 humidity and temperature sensor
Replies: 12
Views: 556

Re: Looking for help with DHT11 humidity and temperature sensor

The simplest way is to use the dht11 overlay. You just read the data out of a file. It works fine. Thanks for the reply knute, Do you have some instructions you could link me to for using the dht11 overlay? Thank you :) Turn off your pi and disconnect the power. Connect the + lead of your DHT senso...
by knute
Fri Apr 12, 2019 3:07 am
Forum: Networking and servers
Topic: Creating a 2 Player Java game using the PI B+
Replies: 2
Views: 148

Re: Creating a 2 Player Java game using the PI B+

That sounds like a fun project. Before you actually code it, you should decide exactly how the game and the players are going to interact. Then you can decide on what messages you need to pass between the clients and the server. So big picture I can see the first player logs into the server and he b...
by knute
Fri Apr 05, 2019 1:58 am
Forum: Automation, sensing and robotics
Topic: Looking for help with DHT11 humidity and temperature sensor
Replies: 12
Views: 556

Re: Looking for help with DHT11 humidity and temperature sensor

The simplest way is to use the dht11 overlay. You just read the data out of a file. It works fine.
by knute
Fri Mar 29, 2019 8:13 pm
Forum: Troubleshooting
Topic: Pi won't play sounds from Java Midi Library
Replies: 5
Views: 182

Re: Pi won't play sounds from Java Midi Library

Your MidiTest code works fine on my RaspberryPi. I tested it with Oracle Java 8, OpenJDK 8 and OpenJDK 11. I am sending my audio through the HDMI port so maybe your problem is with the headphone jack or directing the audio there. If you are using OpenJDK 8 from the repository you need to modify the ...
by knute
Mon Mar 25, 2019 8:08 pm
Forum: Troubleshooting
Topic: SSH out of Raspberry Pi
Replies: 11
Views: 416

Re: SSH out of Raspberry Pi

Just so I'm sure I understand your setup, you've got two computers, a Pi and Windows PC on a LAN. Both connect to the Linux box's network via VPN but only the Windows PC can ssh into the Linux box? Or are you using the LAN's router to VPN to the Linux box's network? So I would turn on the VPN on the...
by knute
Mon Mar 25, 2019 4:11 pm
Forum: Troubleshooting
Topic: SSH out of Raspberry Pi
Replies: 11
Views: 416

Re: SSH out of Raspberry Pi

Is the Windows PC on 192.168.1.? or a different subnet completely from the Pi's VPN network? If it is then maybe the 'firewall' (whatever that is) is rejecting addresses from 192.168.1.*.
by knute
Mon Mar 25, 2019 12:22 am
Forum: Troubleshooting
Topic: SSH out of Raspberry Pi
Replies: 11
Views: 416

Re: SSH out of Raspberry Pi

You don't need sudo. Can you ping the firewall at that address? Do you really need to log in as root?

Go to advanced search