Source: how to know when a EEPROM address is empty? – Using Arduino / Programming Questions – Arduino Forum
Engineering and technology notes
14.04 – How do I disable automatic screen locking in Xubuntu? – Ask Ubuntu
You can edit the file at /etc/xdg/autostart/light-locker.desktop and add the line
Hidden=true
as documented here. This will disable light-locker globally, which is nice if your family starts complaining that they cannot unlock their desktops. You can copy the file to ~/.config/autostart first to disable it for a specific user only.
Source: 14.04 – How do I disable automatic screen locking in Xubuntu? – Ask Ubuntu
String indexOf() and lastIndexOf() Method | Arduino Documentation | Arduino Documentation
String indexOf() and lastIndexOf() Method
The String object indexOf() method gives you the ability to search for the first instance of a particular character value in a String. You can also look for the first instance of the character after a given offset. The lastIndexOf() method lets you do the same things from the end of a String.
In this case,
firstClosingBracket
equals 5, because the first
>
character is at position 5 in the String (counting the first character as 0). If you want to get the second closing bracket, you can use the fact that you know the position of the first one, and search from
firstClosingBracket + 1
as the offset, like so:
Source: String indexOf() and lastIndexOf() Method | Arduino Documentation | Arduino Documentation
networking – DNS issues after upgrading to 20.04
sudo systemd-resolve --set-dns=8.8.8.8 --interface=<interface name>
Source: networking – DNS issues after upgrading to 20.04 – Ask Ubuntu
c – How to check if a given file descriptor stored in a variable is still valid?
int is_valid_fd(int fd)
{
return fcntl(fd, F_GETFL) != -1 || errno != EBADF;
}
Source: c – How to check if a given file descriptor stored in a variable is still valid? – Stack Overflow
Storing Data in Node-Red Variables
mysql – mysqldump throws: Unknown table ‘COLUMN_STATISTICS’ in information_schema
You can disable it by adding
--column-statistics=0. The command will be something like:mysqldump --column-statistics=0 --host=<server> --user=<user> --password=<password>