-
Initial Video Production Testing
11/23/2021 at 13:06 • 0 commentsOne of my favorite hobbies is video production. I feel I currently suck at it, and am still learning the workflow and deciding on tools, but I enjoy it all the same. I have an MSI GE60 from 2013 that I've been using, but wanted to get away from that giant old power hog and try out the Pi 400 as a video editing system. I've got all my project files from an unfinished video project loaded onto the Pi, and have decided on a few software tools already. I will be using kdenlive for the video editing, Audacity for audio editing, and Inkscape for image editing. kdenlive is set up to create proxy clips for any video file over 480 pixels. This will allow me to play back and scrub through the files at a decent speed on this Pi. I will be working with 4K video files shot with a GoPro Hero 7 Silver, and audio files recorded on a Zoom H5 audio recorder.
I'm using a Pi 400 overclocked to 2GHz, running Pop!_OS 21.10 from a 32GB Samsung Bar flash drive on the USB 3.0 port. The project files reside on that boot drive. Read and write speeds are acceptable, and far better than running from micro SD. I'll be using the display on the Vilros Pidock 400 for the video monitor, and either my MEE Audio M6 Pro in ear monitors(fancy headphones), or my Creative Stage Air Bluetooth sound bar for audio monitoring. I'll likely edit with the monitors and check the final result on the sound bar.
Between the 4K video files, high bit rate audio files, limited power of the Pi 400, heat issues caused by the Pidock 400, and untested GPU hardware acceleration, this should be a great test of what the Pi is really capable of. I know there are a few videos out there where kdenlive is used to make videos n the Pi 400, but I want to know what it would be like to learn the entire process on a Pi and use only the Pi for video production. In the future I will add active cooling to the Pidock and overclock the Pi even further for better performance. When I get around to verifying GPU hardware acceleration for FFMPEG, I will turn it on in kdenlive and test performance on various file types and resolutions.
For now, I am going with a fairly stock Pi set up running under Pop!_OS using the software available from the PopShop. This is a setup attainable for the average person who just needs something super cheap and simple to get started. Results of the next test in the next log entry.
-
Pidock 400: Rubber Bumper Screen Protectors
11/21/2021 at 22:59 • 2 commentsIn the image above, notice the little round thing in the top left corner. It's a little self adhesive rubber foot I got at Home Depot. I have one on each side. I put them on the lid instead of the deck to avoid having them get in the way. I don't even notice them up there, and I can close the lid with confidence now. Without them on the screen lid, the screen touches the keyboard of the Pi 400 and will damage it. There is already some back light bleed on the edge of the screen from such unwanted physical contact. The rubbers keep such unwanted contact at bay, while still allowing for a pleasurable experience. Cheap, simple, easy protection. Highly recommended.
On a semi related note, The above image was too large to upload to this log, so I used Inkscape on the Pi to compress the image. Well, lower the image size, which reduced the file size. It was 7.8MB and the limit is 5MB. I divided 5 by 7.8 to get about 64, which I rounded down to 60. This gave me 60%. I reduced the image dimensions to 60% of the original size, exported as a png, and uploaded the now 4.5MB file to this very log, on the Pi this log is about. Pretty neat. Inkscape was perfectly responsive, to the point I forgot I was using a Pi to run it.
The Pi 400 daily driver experiment is going quite well so far. I was able to watch Futurama with a nice bluetooth sound bar while eating popcorn before dinner. I call that a success.
-
Video Encoding/Other Uses
11/21/2021 at 18:24 • 0 commentsLast night before bed, I decided to put my idle Pi to work while I slept. I've got a movie file that needed converted to a modern format as the Pi was struggling to play it. I fired up Handbrake and put in the file. Went to bed and woke up with a finished file. One more small piece of a very large project completed. I am going to run a few files through every night to get things ready for when I hit the road. I'm ordering a new laptop soon which can churn through videos very quickly, but I really don't want to tie up my main machine with such things. I very well may order another Pi 400 to just sit around on a UPS and chug through my entire library until it's all done. $70 to free up my main work PC and my development system seems a reasonable price to me. I know some would consider it a waste, but it's basically spending $70 to set up a project to finish itself while I do more interesting things. I'm ok with that. I want to really push one of these Pi 400s and see what happens, and CPU video Encoding is a great way to do it.
When done with this project, the secondary Pi 400 would be set up as a permanent lab computer, freeing up my Pi laptop to live in it's travel bag so it's always ready to go. I'm just tired of my main PCs being tied up with random work such as backing things up, file compression and co version, and downloading software.
I realized that I need another Pi 4 to finish my camcorder project. I could even use that to process things when it's idle to free up the lab computer. I'm starting to collect Raspberry Pis... I'm ok with that. They're wonderful little machines. I'll get an 8GB model for that. It can be my camcorder/storage server. Strange combination, but that's quite alright. I have strange requirements.
So far, the Pi 400 is making a decent every day computer for me. I installed Kdenlive last night and will test it out soon. It's still a little sluggish, but will speed up eventually when the GPU drivers are sorted. No luck installing Steam link yet, but I haven't given up. I will download the 32 bit Buster version of Raspberry Pi OS and try again later. So far, so good.
-
SSD and Pidock 400
11/20/2021 at 13:45 • 0 commentsI have 2 old SATA SSDs laying around, and wanted to use them with the Pi 400 in the Pidock. Sadly, they're far too large to fit under the Pi in the tiny space where the cables run. I've never opened an SSD before so figured I could try to fit the bare board. I didn't have the right screw driver, so I used a tiny flat head to get one out, then tore the case apart after peaking inside to confirm it would be small enough. I was surprised at how tiny the PCB was, and quite happy. I threw the mangled case away. I'm able to fit the board nearly under the Pi, and may be able to find a SATA to USB adapter that will fit as well. If so, I'll have a SATA boot drive tucked neatly underneath the Pi in my little laptop. It still takes up a valuable USB 3.0 port, but I find the added responsiveness and reliability well worth it. After the Pi corrupted and destroyed my 256GB SD card, I'd had enough. I'm currently booting from a 32GB Samsung Bar flash drive, with a 32GB SD card used to hold TimeShift backups. The otherwise unused SD slot has been great for just adding extra storage. I plan to add a 512GB SD card for media and backup storage, and will carry extra cards to swap out as needed. I'm currently using a 256GB Samsung Fit Flash drive to store media, but it's already full. Once I buy a new laptop and compress all my media, I should be able to take my entire collection with me.
I took a few pictures as words don't do it justice.
I hadn't considered doing this until I started researching USB M.2 drive enclosures,and realized that I have SSDs laying around. I need a SATA SSD to USB adapter for data recovery as it is, so I'll just make sure to get the smallest one I can find, or one that can be trimmed down easily. I may even be able to get 1TB+ drives that would fit in like the one above. I'll order the adapter sometime next week and get it set up. May also order cooling fans for the Pidock. It needs a little help.
-
Bluetooth, Pop!_OS, Video Encoding, Overclocking
11/18/2021 at 14:25 • 0 commentsBluetooth
I HATE bluetooth the vast majority of the time. I find it unreliable and just tedious. I was pleasantly surprised when I turned on my Creative Stage Air bluetooth speaker, and was able to connect to it in a matter of seconds under Pop!_OS. I can't remember ever having less trouble with bluetooth. It just worked and I have some awesome tunes to work to. Under Raspberry Pi OS, I gave up on bluetooth after multiple failed attempts to connect and stay connected. I consider this a huge win as I begrudgingly use bluetooth quite often. Well done System76.
Pop!_OS and System76
This has become my favorite OS of all time in just a few days. It just makes sense to me and gets out of my way while I'm working. My second favorite is still Linux Mint, which is where I started with Linux. I run it on my other laptop, which is due for replacement anyway. I finally decided on my next laptop: System76 Pangolin. The one I want comes in at $1,500+ with an 8 core AMD CPU. I have never owned a nice computer like that in my life, so I think it's about time. I already have my every day PC(this Pi), but I plan to travel and make adventure videos and need some proper power. System76 is all about the linux and so am I. As soon as I heard of them, I started researching and decided they were a great fit for me. I hate Intel and Microsoft these days. Too much drama and expense. I built a PC for a graphics designer friend years ago with an AMD FX8350 CPU if I remember correctly. It was the first 8 core desktop CPU. It was affordable and very powerful. It has aged a bit, but is still perfectly usable to this day. I have been a huge fan of AMD since. They started innovating a while back and never stopped. Same with System76. A System76 laptop with Pop!_OS and AMD CPU is perfect for me. I just like what they do. I'm picky.
Video Encoding Test
I finally put the poor Pi 400 through a video encoding torture test last night. I encoded a 2.7GB HD video file from h265 to h264 last night. I don't think the h265 hardware decoder was working, nor do I think the h264 hardware encoder was in play either. The Pi did it with CPU power. It took almost exactly 7 hours to encode this video, but I ended up with a beautiful 2.1GB file that plays and looks great on the Pi, which is the target system. I can't wait for the GPU to be fully supported under Pop!_OS. That shall be a glorious day.
Overclocking Test
I overclocked the Pi a few different times yesterday, and ran into stability issues. I settled o 2GHz and left it there. I left the initial_turbo=60 setting as it forces max clock speed for 60 seconds on boot to speed up the boot process. I love that this is an option. The overclock did get me a few more frames per second on the video encode last night, but wasn't too noticeable. I've had this Pi running stable at 2.4GHz on accident after a typo in the config.txt. That was under Raspberry Pi OS and I didn't keep it there very long as the Pi sits in a dock that keeps it toasty. I'm happy with the current overclock and will push it harder when I get some good fans going on inside the Pidock.
Other Thoughts
I'm surprised by the lack of Pi 400 projects out there. It's been out a year already and not much is going on. I was surprised to see this project page pop up under "Trending Projects" over at Hackaday yesterday. Pleasant surprise, but makes me wish there was more going on in the Pi 400 world. It's a fantastic machine. I'm about to switch to a new job that will give me set times off and more time off. I'll be able to take side jobs, work on my projects, sleep, and get more done. I have a massive adventure coming up and need to get stuff done. Having this Pi laptop is helping me tremendously. I've got to take the tow truck in for new brakes today, and am going to take it with me and work in the truck, running the Pi off the truck's 12 volt power outlet. It may not have a battery, but it's still the most convenient way to take a Pi on the road. I love that the Pidock 400 is completely free of branding. I love simple and practical. I doubt anyone in public will think twice abut my laptop until I start plugging weird wires and circuit boards into the back. When the PiCarts are ready, they may even go unnoticed. That reminds me: I need to design a way of connecting them to the Pidock without an extension cable, which is the current solution. I'll worry about that later. I still need a working prototype.
-
Installing My First Program: VideoCodecRename
11/17/2021 at 21:01 • 0 commentsI started off this section by logging into Github and downloading the files for VideoCodecRename, which is a program I made to learn programming and get something done. There was no program to do what I wanted, and I had a friend who is a software engineer convince me to just make it myself. That's where this ugly bit of code came from. It evolved from a janky command line tool to something that actually looks like a program people would use. I used tkinter for the interface, as it's a standard tool used with Python. I wanted to keep things simple. I may use it for my PiCarts project as well, since it has a rather old school look to it. I am currently stuck on getting tkinter installed and working. Current error when running my program:
VideoCodecRename-main/VideoCodecRename_1.2.py", line 19, in <module>
import tkinter as tk
ModuleNotFoundError: No module named 'tkinter'Silly me, I ran
sudo apt install python-tk
when I should have run:
sudo apt install python3-tk
Notice the "3" in the second command. That installs the Python 3 version, which is what this program is written with. I got past that error, but now get the following, which I already knew about:
VideoCodecRename-main/VideoCodecRename_1.2.py", line 21, in <module>
from ffprobe3 import FFProbe
ModuleNotFoundError: No module named 'ffprobe3'My previous notes on this call for the following:
sudo pip3 install ffprobe3
. The program now opens. It appears to be working, but only ever returns the codec tag [ERROR], which is used to cover literally any error in the program. Digging through the output reveals that the ffprobe module is not found, so the video file isn't even being opened. Fixed by installing ffmpeg:
sudo apt install ffmpeg
Now the program is working on two different codec types. It seems to fail on a particular file with the H265 codec. No errors, no output. It simply does not rename the file. It is skipping the file for some reason. I get the following error:
FutureWarning: Possible nested set at position 1
BaseName = re.sub('[[@*&?].*[]@*&?]', '', CurrentName)Testing on another H265 file:
Same result. In this folder, there are two files; H264 and H265. H265 fails, H264 does not. Opening the H265 file manually:
Both play using VLC. I suspect it may have something to do with support for the H265 codec on the Pi. Unable to get it to load the ffprobe3 module in the Thonny editor, though it uses the same Python executable as the terminal, which does load it. I got ffprrobe3 installed in Thonny using the built in package manager. My program now runs and can be tweaked in Thonny. I can finally get back to development on it.
This is too involved for me to deal with right now. It's about time for me to get sent back out to work, so I need to get dinner and get ready.
I know this is supposed to be a log for getting this Pi set up for basic software development, and it still is. I was able to code and work on it without any real problems caused by the Pi itself. I am used to a full size keyboard on my 17 inch laptop, so typing is taking some getting used to. Otherwise, the experience was perfectly fine.
Going to run another system back up and take a break.
-
Deciding On Game Development Tools
11/17/2021 at 19:30 • 0 commentsI tried to take a nap, found a video on game development I really like, wrote the previous log, and now I sit at my Pi trying to get a game engine working so I can at least start learning game development. So far, so frustrating.
Between the crappy internet connection(only a problem on the Pi), and me being tired, it's off to a slightly rocky start. I did manage to get Godot game engine running on here, but it's so slow as to be basically unusable. I am too tired to deal with that, so I'm working on getting Pygame installed. I'd prefer Pygame as it will teach me more than other game engines. I'm not great with Python yet and need to be, so it works out great. I couldn't even get pip3 installed, so I had to use my phone's hotspot to get a stable enough internet connection to download and install it.
Installing Pip3 worked, Pygame is still running. It tried to create a new keyring, but I denied it after it failed the first time. Seems to be installing now. Will test when done. The Aliens example game worked great, so I at least now have Pygame working on the Pi 400 under Pop!_OS.
I am starting with This Tutorial and working my way up from there. Assuming I know nothing, as I basically do. I'll start reading through that later. Too tired to absorb any of it right now. Don't become a tow truck driver... 2/10, do not recommend...
I think a better path for me to take, and a little later, would be to get my VideoCodecRenameUtility program running on the Pi and start working with it to get more experience. I made that little Python program to open a video file with ffmpeg, find the codec used for the video stream, then send it back out to Python, where it inserts it into the file name in square brackets. It works well enough, but has plenty of bugs I need to work out. It's on my Github, which I also need to set up on here. Another reason to start on that project again. I use that program to find various types of files and prioritize their connversion to more reasonable formats.
I find software development daunting, but I understand the basic concepts well enough. I just can't code when tired and anxious about work. Once I get that program on here, I can start getting back into the groove, and decide what program I want to code with.
As much as I want to use something as fancy as Godot or Unity to make my games, it's important to me that I do so on something lower level and on the machine I have. If the program can't even run on the Pi 400, I won't use it. Uninstalling Godot engine now...Done. Pygame it is. I like to watch DaFluffyPotato on YouTube as he works with Pygame and does some neat stuff
I was quite excited to get some coding done, but I don't think I will. I've pushed myself too hard in the past on projects and often gotten burned out and either stopped working on the project for long periods of time, or gave up entirely. I'll spend some of my driving time thinking of what to do next.
Actually, I decided what to do next before posting this and laying down. I'm seeing if I can get Inkscape installed and working on the Pi, then if I can set it up for creating pixel art and such. I like Inkscape and would like to get to know it better. Inkscape installed and runs fine on here from what I can tell so far. I made a bunch of shapes, drug them all around and just played with things. Very little slow down. I think I can make this work. I'll learn more Inkscape later.
That's it for this log. Going to set up the Pi to convert a video for me and see how long that takes. Separate log on that later.
-
Defining My Various Use Cases
11/17/2021 at 18:19 • 0 commentsAs tired as I am after a long and difficult tow truck adventure this morning, I'm too excited to rest at the moment. I discovered devduck on YouTube and his Dauphin game. It's a RPG game where a marine biologist travels the world to clean it up and clean up the seas. It's exactly the kind of game I'd love to play. I plan on joining his monthly support subscription here soon and learning what I can from him. My PiCarts project is both hardware and software, but I'm working mostly to create a platform for excellent software. I'd love to release a Dauphin cart some day. I may propose the idea when development is far enough along, but it's a far off dream for now. Stardew Valley is another wholesome game I'd love to see on the platform. I don't even think there is a version out right now that will run on the Pi...
This log is you outline what I need my Pi 40p to do, and how I might go about doing it.
Game Development
I plan to use Pygame for game development if I can ever get the time to learn it. I'm also considering the Godot game development engine as it's available in the PopShop on Pop!_OS, which is my new every day OS on the Pi 400. I've been trying to avoid a game engine and doing things the easy way, as I want to develop more skill. In the end, I need to make progress on this project, so small, easy victories are in order. It's like how I'll use a chainsaw to fell a tree, just to cut and shape parts of it with an axe and hand tools.Graphic Design
This should be simple enough, as I know of a few programs off hand I can use. Inkscape is my go-to, with GIMP being another solid option. Pixel art programs should exist for the Pi these days as well. I may also cheat and buy some indie game asset packs just to get going. The Pi 400 should have enough power for such tasks. I'll add active cooling to the Pidock 400 and overclock to 2.3GHz as well.Video Editing, Management, and Encoding
This isn't a task related to any of my current documented projects, but is a separate hobby of mine. I work with video files all of the time. I plan to produce my own adventure videos as I travel, and I have media backups totalling about 5TB from over the years. Some files are very recent 4K recordings from my GoPro, some are DVD and VHS backups from many years ago. The plan is to be able to compress the 4K files and reduce them to 1080p and edit on the Pi, and also convert all old formats to something modern. I'd like to convert everything to H265. The Pi struggles very hard with that codec, as I haven't gotten hardware acceleration working, but it's possible. Slow. I may get a second Pi 4 just to run 24/7 and convert videos, or I may buy a Ryzen 9 Zen 3 based mini computer to handle the initial conversion. Either way, have much to do with video files these days. The first program I ever wrote actually was for the video clean up project I started in 2013. I wrote it about a year ago or so to find the codec of a video file and write it to the filename in square brackets. It helped me immensely as I tried to see what all I am working with. I've never seen another program like it. That's why I made it myself. I can run that on the Pi easily. It's Python. As far as software goes, I'm looking into Kdenlive for video editing, Handbrake for video conversions, my custom program to find and prioritize files to be converted, HBBatchbeast for bulk conversion, and Audacity for simple audio editing.General Software Development
I typically use Thonny for Python, Arduino IDE for microcontrollers, and am testing out Notepadqq for notes, programming and replacing things. The Pi 400 is plenty fast enough for this task and I've had no problems with it. I am trying to avoid doing general development with Raspberry Pi OS as I find it's pain to use. It is the target platform for quite a few things, but I can keep that in mind as I develop elsewhere.There isn't too much else I can think of. I'll start testing some software and workflows here soon. I've got to record some very important audio for a friend soon and will do the editing on the Pi. I've got some video clips I can convert from 4K to 1080p and work with in the editor. I've got tons of video files that need sorted and checked for corruption. I've got games, programs, and interfaces to develop. I've got plenty to do and am curious to see how much of it the Pi 400 can handle. Plenty more updates to come.
-
Installing Jellyfin Media Server: Attempt 1
11/17/2021 at 16:43 • 0 commentsHaving used Jellyfin o this Pi 400 under Raspberry Pi OS, I know it can work very well. However, I could not get it to install now that I'm running Pop!_OS 21.10, or whatever version it is. It turns out that Jellyfin only supports the LTS versions of Ubuntu and Ubuntu based OSs, the latest being 20.04, which this is not. I wouldn't give up this OS for Jellyfin though, as much as I love running a media server from my Pi. I just found out there is a way to enable hardware accelerated video transcoding as well, but that will have to wait until I get it running.
There may be a way though: Docker. I have never used Docker, but have been curious for a few years now. I'll look into what it will take to run, and if it would even work on the Pi. If so, I will give it a try. I just worry about the overhead of a media server and Docker both running on the Pi's already stressed hardware. It's a capable little machine, but is already rather slow. I'm hoping hardware acceleration will become available on the Pi4/400 for Pop!_OS soon, as that would smooth out the entire experience quite a bit. Until then, I shall patiently wait on things to load and appear on screen.
Without Jellyfin running on the Pi, I can still access the media on my old laptop, which runs 24/7 and hosts a Jellyfin server with my full collection of media. That may be for the best as that laptop can easily transcode my media for easy playback on the meager hardware of the Pi 400.
The Pi is still running quite hot these days, and I suspect it's due to the fact that the Pidock isn't letting the heat escape very well. I'll be tearing it down to install fans here soon.
Other than the Jellyfin issues, the experience has still been very positive. I am typing this on the Pi now, and it feels perfectly natural to me. I often forget I'm using a Raspberry Pi...a wonderful feeling.
-
Pop!_OS after day 1
11/16/2021 at 17:07 • 0 commentsI spent all last night working on setting up Pop!OS on the Pi, and finally got it where I can get most of my work done. It was slow going, but I expect that. The entire experience is rather slow compared to even my old laptop from 2013. Had I gone into this expecting the same level of performance, I'd have been very frustrated. Instead, I accepted a slower pace and just came up with ways to deal with it. One of them is installing Mahjong from the PopShop so I have something to play while I wit for things or just sit idle. It's one of my favorite puzzle games and the only one I really play anymore. When system updates are running and slowing down we browsing, I start that up and play a round. Perfectly fine.
I had to order some canvas wax online this morning, something I normally do from my Android phone, and decided to do it on the Pi. No problems there. So far I know I can watch my movies and TV collection on here, browse online, order stuff, play some simple games, listen to music, read and research, and write up my logs on here. If I have the time and energy today, I'll try out the Arduino IDE with my Arduino Mega and Raspberry Pi Pico. I still have to sort out GPIO on here as well.
Pop is really for my daily use, not project use. I will be using Raspberry Pi OS for most of my development as that's the target OS for my main project. I plan to do video editing and conversion, audio editing, photo editing, and pretty much anything else I need to do. I am learning video production on the side and would love to be able to produce good videos from a Pi like this. I know this is not a great system for such things, but I can let rendering run overnight. The Pi sits idle while I sleep, and it's low power consumption means I can let it run on battery power when I hit the road on a motorcycle. I can edit the video, hit render, then put it in a ventilated bag and let it run off the motorcycle battery and alternator while I ride. I wouldn't do that with a normal laptop. It's slow, but I am patient.
I really just want to show what's possible. This is my favorite computer so far and it deserves more than just web browsing. When GPU hardware acceleration is sorted out on the Pi 400, I suspect the entire experience will improve greatly. Until then, I'll just work on adding active cooling to the system and overclock it. I found plenty of vents in the bottom of the Pidock 400, so I'll be adding a fan soon. Until then, it shall remain at the stock clock speeds.
I do plan on getting a secondary PC for more serious stuff like proper fast video editing and 4K editing. I'm considering the Minisforum Elite HX90. I prefer AMD these days, and the APU packs some serious power. The power to power consumption ratio is quite good as well. I can use the Pidock 400 as a monitor for it, and the Pi 400 as a keyboard and mouse over USB C using some clever code. I have tons of old media backups that I'd like to convert and compress, but I don't feel like asking my Pi or old laptop to convert 5TB to H265. They might die... That PC should have little trouble plowing through such tasks. I also wish to play games as I travel, so i Could use that as a Steam server and the Pi as a client. I'll be testing that setup when I can.Overall, I am quite pleased. I know the Pi can run far better at 2.3GHz, but it runs far too hot in the Pidock. Until I sort out cooling, I shall chug along slow and steady.