the following packages should be installed
$ sudo apt-get install mysql-client mysql-server qt5-default libmysqlclient-dev libqt5-mysql
mysql-client, mysql-server : just in case mysql is not installed in the host
qt5-default: basic qt5 package so that we can build qt5 projects. just included for my own convenience to build qt5 without full qt5 installation.
libmysqlclient-dev: my guess is that this package contains something like ‘headers’ for using mysql.
libqt5-mysql: seems to be qt5 specific files that are needed to access the mysql.
For raspberry pi, I had no problems using the qt5 with mysql after installing these packages. BTW, I am using raspberry pi 3 model b.
After bumping up my confidence with adding a simple custom command in uboot for raspberry pi, I searched on how I can implement a custom poweroff command.
However, it looks like a perfect poweroff command is impossible due to hardware limitations. My googling suggests that rpi doesn’t have any hardware support that can allow software to cut the incoming power. Such neat practices require ACPI or PMIC.
I should check out the rpi schematic to see if there really is no PMIC chip in rpi.
Also, if I can’t get it to poweroff neatly at least I can try to mimic one by turning of the SOC perhaps?
Progress so far:
- tried to build a uboot image for rpi3. Miserably failed. some setting with the compilers seems to be off.
- fortunately, rpi2 build works very well. I can get get the build images.
- confirmed that the vanilla build works well with rpi2. Made some changes in the ‘config.txt’ file in /boot partition of the rpi sd card so that I can access the uboot prompt through UART communication.
- succeeded adding a very simple custom command in uboot.
- wanted to display some picture or whatever with uboot.
The failure with displaying a picture on the display with uboot seems to be a complicated matter. I think there are two problems that I should tackle
- enabling BMP command
From various uboot splashscreen tutorials, most of them utilize a ‘bmp’ command. Apparently, this is the command that will display a bmp image file to the display. However, this command is not included in the default uboot .config option. One must manually add ‘CONFIG_CMD_BMP’ configuration.
Further digging suggested that enabling ‘CONFIG_CMD_BMP’ alone is not enough. In order to this to work properly, one must also turn on other ‘CONFIG_’s as well.
2. raspberry display related address is messed up
One of the replies written in this thread suggests that raspberry pi’s default address configuration is messed up in a way that the display driver will corrupt other critical memory regions whenever it will try to show something up on the display.
Here is what the comment says:
Hi a little (headache) contributed from me:
If you want use the Splash screen of bitmap display in bootmap , there is a bug in the video driver.
The panel_info.cmap is not allocated and have a NULL value. So the cmap is fill at 0x0 and lot’s of essential data like device tree too (at 0x100) is overwritten.
index 7867fe3..6f450b2 100644
@@ -102,14 +102,16 @@ void lcd_ctrl_init(void *lcdbase)
panel_info.vl_col = w;
panel_info.vl_row = h;
panel_info.vl_bpix = LCD_COLOR16;
- gd->fb_base = msg_setup->allocate_buffer.body.resp.fb_address;
+ panel_info.cmap=malloc(256 * NBITS(panel_info.vl_bpix) / 8);
+ gd->fb_base = msg_setup->allocate_buffer.body.resp.fb_address;
+ gd->fb_base &= ~0xc0000000;
I haven’t looked deep into this yet.
$ cd /var/log
$ cat auth.log | grep 'Accepted'
this one is for listing lines including the ip addresses that have successfully connected to server.
could tweak it various ways to show info user wants.
found out that my rspi was under constant root login attempts from unknown IPs. Needed to block their attacks and good practice is to disable root ssh login.
$ vi /etc/ssh/sshd_config
disable comment by removing ‘#’ of ‘PermitRootLogin’ and change value to ‘no’
restart sshd service. for rspi, can do this with following command:
$ sudo service ssh restart
after this, attempts to login with root account will be denied by default.
here’s a video recording of access to my wordpress on top of raspberry pi. Continue reading “wordpress+raspberry pi speed performance”
For some reason when I try to configure the routing of my Ethernet connection by changing the /etc/network/interfaces file, the changes do not apply properly and it keeps giving errors such as “SIOCADDRT: file exists” “SIOCADDRT: network unreachable”. After many attempts to get this right, I gave up and instead used another method to achieve my goal. Continue reading “bypassing route config problem in raspi”