Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Semisomnum
Aug 22, 2006

Half Asleep


This is probably a long shot but does anyone here have experience running NixOS on a Pi4? I'm having some trouble getting config.txt settings to apply, mainly HDMI related stuff like overscan. This is the guide I followed. Which says to alter the config.txt you have to mount the firmware partition and change the config.txt there, which seems to actually apply the overscan settings, but only for the initial UBoot screen that then loads into NixOS, where the settings are immediately reverted.

I've tried recreating the config.txt file in the /boot directory of the NixOS partition but that doesn't seem to accomplish anything. I've also tried some alternative methods suggested in various guides like using a cmdline.txt (on both partitions) string to alter the overscan settings. So far the only thing that seems to "work" is using xrandr in a desktop environment (XFCE) to change display margins, but that obviously doesn't work for the initial boot scroll or for a command-line only environment. Ideally I could just alter the display settings for the TV its connected to but apparently it's too old to have any settings like that.

There are also settings in the NixOS configuration.nix that claim to be able to alter the config.txt but they're both ineffective (likely because the firmware partition isn't being mounted to /boot in NixOS) and apparently deprecated.

I'm hesitant to try any more drastic steps like trying to mount the firmware partition to /boot in NixOS or switching to a UEFI based boot setup since they're both potentially destructive and seem unlikely to work. Any guidance would be appreciated.

Adbot
ADBOT LOVES YOU

Semisomnum
Aug 22, 2006

Half Asleep


Holy poo poo dude thank you so much. Searching around the framebuffer hint led me down the path to the answer which was to use the boot.kernelParams options with the string all those guides told me to put into cmdline.txt. My screen finally fits properly.

On the off chance someone else runs into this problem and winds up here for the solution:

code:
#hardware-configuration.nix
boot.kernelParams = [ "video=HDMI-A-1:1920x1080@60,margin_left=40,margin_right=40,margin_top=32,margin_bottom=32" ];

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply