[OS] Debian Buster for ODROID N2

User avatar
mad_ady
Posts: 9685
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, C4, N1, N2, H2, Go, Go Advance
Location: Bucharest, Romania
Has thanked: 609 times
Been thanked: 721 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by mad_ady »

There was hot plug detection (hpd) in boot.ini. You can try to turn it off and see if hdmi remains on.

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

i think in the boot.ini you can also set the HDMI to always be connected even if no cable is plugged in and even if the tv is off.
Also make sure CEC is turned off, as it may interfere when you turn off the TV
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

bscuderi
Posts: 9
Joined: Fri Dec 29, 2017 5:51 am
languages_spoken: english
ODROIDs: XU4 (now broken RIP), and N2
Has thanked: 0
Been thanked: 0
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by bscuderi »

Changing this option and commenting out the other was the ticket in boot.ini just wasn’t super intuitive I guess and the comments in each section of boot ini didn’t really explain what each thing does so I had to dig around more to find out what I was actually changing. I knew it had to be in that document somewhere i had already tried a bunch of changes with no effect It also could have been the auto detect display I also turned that off at the same time. Thanks for the help guys it’s surviving turning the tv off now.

# HPD enable/disable option
setenv disablehpd "true"
#setenv hpd "true"

BadPritt
Posts: 187
Joined: Wed Jan 17, 2018 4:08 am
languages_spoken: english dutch french spanish german
ODROIDs: Odroid C2
Odroid XU4Q
Has thanked: 32 times
Been thanked: 33 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by BadPritt »

Hi Meveric.
I'm testing the N2+ for review. Just installed Debian Buster. All works very nice.
Just the clockspeeds for N2+ aren't available.
Would you have an idea when this could be added please? For now only the Ubuntu's have the higher clockspeeds. I wonder if PPSSPP would run better with it. It does use a lot of cpu.

Nice to see different GPU drivers in the works for it. I hope VPU is being worked on too, haven't found much on it.
Greetings, NicoD

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

I just recently got my N2+ due to some delay in delivery and some personal stuff that I had to do.
I wasn't able to update the packages for N2+ yet. I will do this the next couple days.
These users thanked the author meveric for the post:
BadPritt (Thu Aug 06, 2020 4:39 am)
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

Slaminger
Posts: 292
Joined: Tue Jul 16, 2019 12:30 am
languages_spoken: English, French
ODROIDs: XU4, N2, N2+, C2, C4, OGA, OGA-BE, H2+, OGS, OGST
Location: Canada
Has thanked: 25 times
Been thanked: 78 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by Slaminger »

Do you have a buster that supports the new N2+?

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

Slaminger wrote:
Tue Oct 20, 2020 4:25 am
Do you have a buster that supports the new N2+?
Technically the current image already supports the N2+.
If you take this image and update it with the latest Kernel it has the dtb file for N2+.
Currently you manually need to adjust the boot.ini to switch from meson64_odroidn2.dtb to meson64_odroidn2_plus.dtb.

Code: Select all

fatload mmc ${devno}:1 ${dtb_loadaddr} meson64_odroidn2_plus.dtb
But I'm looking into it if there's a way to do this automatically without having to create a new image.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

Slaminger
Posts: 292
Joined: Tue Jul 16, 2019 12:30 am
languages_spoken: English, French
ODROIDs: XU4, N2, N2+, C2, C4, OGA, OGA-BE, H2+, OGS, OGST
Location: Canada
Has thanked: 25 times
Been thanked: 78 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by Slaminger »

meveric wrote:
Tue Oct 20, 2020 4:53 am
Slaminger wrote:
Tue Oct 20, 2020 4:25 am
Do you have a buster that supports the new N2+?
Technically the current image already supports the N2+.
If you take this image and update it with the latest Kernel it has the dtb file for N2+.
Currently you manually need to adjust the boot.ini to switch from meson64_odroidn2.dtb to meson64_odroidn2_plus.dtb.

Code: Select all

fatload mmc ${devno}:1 ${dtb_loadaddr} meson64_odroidn2_plus.dtb
But I'm looking into it if there's a way to do this automatically without having to create a new image.
i'm now on kernel 4.9.236+ and have swapped the information in the .ini but still do not see the increased clockspeed

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

can you check the output of

Code: Select all

cat /proc/cpuinfo
it should be

Code: Select all

Hardware	: Hardkernel ODROID-N2Plus
I found the problem is the boot.ini as well.
There is a section:

Code: Select all

# max cpu frequency for big core, A73 in MHz unit
# setenv max_freq_a73 "2004"  # 2.004 GHz
# setenv max_freq_a73 "1992"  # 1.992 GHz
setenv max_freq_a73 "1908"  # 1.908 GHz
# setenv max_freq_a73 "1800"  # 1.8 GHz, default value
# setenv max_freq_a73 "1704"  # 1.704 GHz

# max cpu frequency for little core, A53 in MHz unit
# setenv max_freq_a53 "1992"  # 1.992 GHz
setenv max_freq_a53 "1896"  # 1.896 GHz, default value
# setenv max_freq_a53 "1704"  # 1.704 GHz
That needs to be adjusted.
I will update this and the uboot with a new package soon that should take care of this :)
For now you can simply outcomment the setenv max_freq_ lines and it will take the default clock for the N2+ which is higher than what these values are.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

Slaminger
Posts: 292
Joined: Tue Jul 16, 2019 12:30 am
languages_spoken: English, French
ODROIDs: XU4, N2, N2+, C2, C4, OGA, OGA-BE, H2+, OGS, OGST
Location: Canada
Has thanked: 25 times
Been thanked: 78 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by Slaminger »

meveric wrote:
Tue Oct 20, 2020 6:37 am
can you check the output of

Code: Select all

cat /proc/cpuinfo
it should be

Code: Select all

Hardware	: Hardkernel ODROID-N2Plus
I found the problem is the boot.ini as well.
There is a section:

Code: Select all

# max cpu frequency for big core, A73 in MHz unit
# setenv max_freq_a73 "2004"  # 2.004 GHz
# setenv max_freq_a73 "1992"  # 1.992 GHz
setenv max_freq_a73 "1908"  # 1.908 GHz
# setenv max_freq_a73 "1800"  # 1.8 GHz, default value
# setenv max_freq_a73 "1704"  # 1.704 GHz

# max cpu frequency for little core, A53 in MHz unit
# setenv max_freq_a53 "1992"  # 1.992 GHz
setenv max_freq_a53 "1896"  # 1.896 GHz, default value
# setenv max_freq_a53 "1704"  # 1.704 GHz
That needs to be adjusted.
I will update this and the uboot with a new package soon that should take care of this :)
For now you can simply outcomment the setenv max_freq_ lines and it will take the default clock for the N2+ which is higher than what these values are.
ok, i will give that a try. i think the n2+ max clock speed is 2.4GHZ, uncommenting the above did work, but that isn't the max clock speed, im writing the ubuntu image to a sd card to pull the info from the .ini there
Last edited by Slaminger on Tue Oct 20, 2020 7:17 am, edited 1 time in total.

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

2.4 GHz is overclocked, the default is 2.2GHz
But yes you could technically adjust the value to 2400 if you wanted.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

Slaminger
Posts: 292
Joined: Tue Jul 16, 2019 12:30 am
languages_spoken: English, French
ODROIDs: XU4, N2, N2+, C2, C4, OGA, OGA-BE, H2+, OGS, OGST
Location: Canada
Has thanked: 25 times
Been thanked: 78 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by Slaminger »

meveric wrote:
Tue Oct 20, 2020 7:13 am
2.4 GHz is overclocked, the default is 2.2GHz
But yes you could technically adjust the value to 2400 if you wanted.
if test "${variant}" = "n2_plus"; then
setenv max_freq_a73 "2208"
setenv max_freq_a53 "1908"


is what it says in the ubuntu ini

but when i switch max to 2208 it no longer boots

Slaminger
Posts: 292
Joined: Tue Jul 16, 2019 12:30 am
languages_spoken: English, French
ODROIDs: XU4, N2, N2+, C2, C4, OGA, OGA-BE, H2+, OGS, OGST
Location: Canada
Has thanked: 25 times
Been thanked: 78 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by Slaminger »

meveric wrote:
Tue Oct 20, 2020 7:13 am
2.4 GHz is overclocked, the default is 2.2GHz
But yes you could technically adjust the value to 2400 if you wanted.
but lscpu and cpufreq are showing me the a53 and not a73

the hardware shows the ODROID-N2Plus

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

you don't need to set it to 2208 and 1908 as these are the defaults.
If you just outcomment the lines with setenv max_freq it will use these values automatically.

you can check the max clock speed with:
cortex-a53

Code: Select all

cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq
cortex-a73

Code: Select all

cat /sys/devices/system/cpu/cpu2/cpufreq/cpuinfo_max_freq
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

Slaminger
Posts: 292
Joined: Tue Jul 16, 2019 12:30 am
languages_spoken: English, French
ODROIDs: XU4, N2, N2+, C2, C4, OGA, OGA-BE, H2+, OGS, OGST
Location: Canada
Has thanked: 25 times
Been thanked: 78 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by Slaminger »

the issue now is updating the kernel causes lag in systems like flycast and yabasanshiro that didnt exist before, and it has this same issue in ubuntu too. and in batocera. any idea why? on ubuntu libEGL was throwing a dri2 error

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

sadly no, I haven't tested either on the N2 for long.
If the issue is common around all OSes then the Kernel provided by HardKernel is now causing this, and HardKernel may be able to take a closer look on what causes these lags.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

oldchap
Posts: 71
Joined: Mon Aug 07, 2017 3:27 pm
languages_spoken: english
Has thanked: 0
Been thanked: 2 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by oldchap »

Thanks for 1024x600 Straight OOTB
What can I do to have the screen roll by while the Buster is loading.

The internet gurus suggest I use Palemoon browser but cannot load it, it needs libc6 2.3.
Can I update it with a .deb package or do you have to update it. thanks

I have made a new user 'ridiculous' with a ridiculous password to use WHEN NOT on the internet.
After I log in to 'ridiculous' I want to use Caja, Gparted, Geany without having to type sudo all the time, just click on caja on the desktop. Just click in it and have it run as root user as this user never goes on the internet.
I've ferreting around in visudo and am able to run caga as root but have to type 'sudo caja' every time.
What is the magic in visudo that makes caja run as root by clicking caja on the desktop. Thanks lots

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

oldchap wrote:
Thu Oct 29, 2020 8:20 am
The internet gurus suggest I use Palemoon browser but cannot load it, it needs libc6 2.3.
Can I update it with a .deb package or do you have to update it. thanks
libc6 2.3 would be a DOWNgrade and not an upgrade Debian Buster is currently at 2.28 so I don't think that's your current problem.
Version 2.3 is from around 2006.
Also exchanging libc6 can be dangerous in some cases, as it's the main library all C/C++ based applications run on, and if there was a major change, you could potentially damage your system beyond repair, although very unlikely.
oldchap wrote:
Thu Oct 29, 2020 8:20 am
I have made a new user 'ridiculous' with a ridiculous password to use WHEN NOT on the internet.
After I log in to 'ridiculous' I want to use Caja, Gparted, Geany without having to type sudo all the time, just click on caja on the desktop. Just click in it and have it run as root user as this user never goes on the internet.
I've ferreting around in visudo and am able to run caga as root but have to type 'sudo caja' every time.
What is the magic in visudo that makes caja run as root by clicking caja on the desktop. Thanks lots
running caja as root is really not suggested.. has nothing to do with internet or not. any program you run as root is a security risk, either due to exposed bugs or security issues, or simply due to the fact that you can have human error that causes this.
A "user" does not prevent you from using the internet.
The moment you have a network cable connected the system can use internet.

Anyway... I don't think visudo can help here.
You should read up on policykit, how to do this.
In the past you could simply create a .desktop file and tell it to run with gksu to run the application with root privileges.
But that was removed in recent OS versions. Therefore you should read up on policykit where you can define which user or group can run what application with which privileges
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

oldchap
Posts: 71
Joined: Mon Aug 07, 2017 3:27 pm
languages_spoken: english
Has thanked: 0
Been thanked: 2 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by oldchap »

libc6 2.3 thats my stuff up, got my 2 and 3 arm about face, make it libc6 3.2 or above for Palemoon. Guess I shall have to wait for the next version for 3.2 and Palemoon.

"A "user" does not prevent you from using the internet."

I see what you mean, when I log into user ridiculous I can see Palemoon available on the desktop, that was not supposed to happen. Ridiculous has been given the chop, I'll just use normal user with the firewall always on for Palemoon.

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

oldchap wrote:
Mon Nov 02, 2020 12:02 am
libc6 2.3 thats my stuff up, got my 2 and 3 arm about face, make it libc6 3.2 or above for Palemoon. Guess I shall have to wait for the next version for 3.2 and Palemoon.
There is no such thing as libc6 version 3.2 the highest version currently available is 2.32.
It's more likely that it requires 2.3, as palemoon is based on FireFox which has very low requirements.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

odro-volti
Posts: 89
Joined: Fri Apr 12, 2019 4:35 pm
languages_spoken: english
ODROIDs: Odroid XU4
Has thanked: 12 times
Been thanked: 2 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by odro-volti »

What is the status of the image for N2plus? :-)
kind regards

volti

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

N2 and N2plus are the same board there is no different image just a different dtb file which is already available.
Install this image, update it to the latest version via apt and you already have N2plus support. Nothing else needed.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

oldchap
Posts: 71
Joined: Mon Aug 07, 2017 3:27 pm
languages_spoken: english
Has thanked: 0
Been thanked: 2 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by oldchap »

Is it possible to have the screen roll by on startup instead of a black screen.
Seems I shall just have to wait for a upgrade to 2.32 before I can use Palemoon.
"It's more likely that it requires 2.3, as palemoon is based on FireFox"
Nope
"Version 2.3 is from around 2006."
"Debian Buster is currently at 2.28 so I don't think that's your current problem."
Palemoon needs at least 2.30, it's the zero on the end that borked me. In money $2.3 is the same as $2.30 but not in libc6.

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

Debian Buster will never get a different libc6 version.
The libc6 version stays constant over the entire lifetime of the OS.

Palemoon can be downloaded as ready to use packages from: https://software.opensuse.org/download. ... e=palemoon
It goes down to Debian 8 which is libc6 2.17 so your assumption it requires 2.30 or higher is incorrect.

You can actually download form there directly for Debian 10 (Buster) which will use libc6 2.28.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

mikec
Posts: 11
Joined: Sun Nov 29, 2020 3:49 pm
languages_spoken: english
ODROIDs: odroid-n2
Has thanked: 1 time
Been thanked: 0
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by mikec »

Hi,

I installed and tried running glmark2-es2-fbdev on a freshly flashed and dist-upgraded odroid-n2 system, but it didn't work. The kernel package installed by apt dist-upgrade was 'linux-image-4.9.236-arm64'. Running glmark2-es2-fbdev gave the following error:
glmark2-es2-fbdev: error while loading shared libraries: libEGL.so: cannot open shared object file: No such file or directory
Is a dependency missing?

Also, what is the difference between 'linux-image-4.9.236+' and 'linux-image-4.9.236-arm64', and which one should be used? What does the '+' mean?

Thanks in advance :)

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

mikec wrote:
Sun Nov 29, 2020 4:14 pm
Hi,

I installed and tried running glmark2-es2-fbdev on a freshly flashed and dist-upgraded odroid-n2 system, but it didn't work. The kernel package installed by apt dist-upgrade was 'linux-image-4.9.236-arm64'. Running glmark2-es2-fbdev gave the following error:
glmark2-es2-fbdev: error while loading shared libraries: libEGL.so: cannot open shared object file: No such file or directory
Is a dependency missing?
glmark2-es2-fbdev is just the benchmark. You still need to install the GPU drivers to actually run the benchmark.
It should work if you install the package malig52-fbdev-opencl-odroid
mikec wrote:
Sun Nov 29, 2020 4:14 pm
Also, what is the difference between 'linux-image-4.9.236+' and 'linux-image-4.9.236-arm64', and which one should be used? What does the '+' mean?

Thanks in advance :)
I use several tools provided by the OS itself to create Kernel packages. Without any adaptation it automatically creates packages with the version number of the Kernel and the + behind it.
Recently I found out how to correctly name the Kernel which also includes the "flavor" which is arm64. Therefore from now on packages will be names with the version number and flavor -arm64 instead of the +.
Both do work the same but the one with -arm64 is the latest Kernel :)
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

mikec
Posts: 11
Joined: Sun Nov 29, 2020 3:49 pm
languages_spoken: english
ODROIDs: odroid-n2
Has thanked: 1 time
Been thanked: 0
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by mikec »

Thanks! I was missing that package.

Also, is there a way to use the hardware video decoding for playing video files? I compiled the bionic branch of c2play from crashoverride's github, but when I try to play a video, even as root, I get:
...
AmlCodec open failed.
terminate called after throwing an instance of 'Exception'
Aborted
What could be the cause of this error?

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

try installing aml-libs-odroid package which is the package for the hardware decoder, but I'm not sure if it works.
It's been quite a while since I tried that on Debian.

Kodi (kodi-fbdev-odroid) should work with some form of hardware decoding, but I can't say how good it will work.
You can use the setup-odroid command to install it.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

mikec
Posts: 11
Joined: Sun Nov 29, 2020 3:49 pm
languages_spoken: english
ODROIDs: odroid-n2
Has thanked: 1 time
Been thanked: 0
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by mikec »

I think the issue might be that /dev/amstream_vbuf is missing. c2play/src/Media/AmlCodec.cpp throws the error I quoted in my previous message if there is a problem with opening CODEC_VIDEO_ES_DEVICE.

AmlCodec.h has,
const char* CODEC_VIDEO_ES_DEVICE = "/dev/amstream_vbuf";
const char* CODEC_VIDEO_ES_HEVC_DEVICE = "/dev/amstream_hevc";
const char* CODEC_CNTL_DEVICE = "/dev/amvideo";
The first two are missing from my installation.

Please see viewtopic.php?p=166828#p166828

/boot/config-4.9.236-arm64 has,
Amlogic VPU Driver Support
#
CONFIG_AMLOGIC_VPU=y
# CONFIG_AMLOGIC_VPU_DYNAMIC_ADJ is not set
CONFIG_AMLOGIC_VIDEOBUF_RESOURCE=y
I'm not sure if meson64_odroidn2.dtb has what is required.

mikec
Posts: 11
Joined: Sun Nov 29, 2020 3:49 pm
languages_spoken: english
ODROIDs: odroid-n2
Has thanked: 1 time
Been thanked: 0
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by mikec »

It looks like the c2play code might be stale, and will no longer work with current and future kernels, but I'm not sure.

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

That thread you mentioned is very old from 2016 it's for the C2 not the N2.
The code for c2play never really worked out of the box for me and I always had to adjust a tiny bit here and there.

As I said you probably have more luck with Kodi instead.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

User avatar
MichaIng
Posts: 62
Joined: Wed Apr 10, 2019 4:44 am
languages_spoken: english german
Has thanked: 14 times
Been thanked: 19 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by MichaIng »

Hi Meveric, forwarding the hint about a required image update for Odroid N2+: viewtopic.php?p=323758#p323758
The current kernel package from your repository contains the device tree overlay already, so apart of "apt full-upgrade", only the boot.ini needs to be adjusted to load the correct dtb based on variant.

Suggestion for boot.ini: https://github.com/MichaIng/DietPi/blob/dev/boot_n2.ini

Best regards!

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

MichaIng wrote:
Wed Mar 10, 2021 8:57 pm
Hi Meveric, forwarding the hint about a required image update for Odroid N2+: viewtopic.php?p=323758#p323758
The current kernel package from your repository contains the device tree overlay already, so apart of "apt full-upgrade", only the boot.ini needs to be adjusted to load the correct dtb based on variant.

Suggestion for boot.ini: https://github.com/MichaIng/DietPi/blob/dev/boot_n2.ini

Best regards!
Updating the image could be good, but I already have patched boot.ini, as it's part of my setup-odroid package which takes care of things like this.
I've been running the image on the N2Plus for months already by simply doing an apt upgrade :)
But you're correct. For overall out-of-the-box experience it would be better to update the base image instead doing an apt upgrade.

Also there are some things missing in your boot.ini.
It doesn't load device-tree-overlays which is already part of my boot.ini, also you should consider doing mounting rootfs as ro not as rw so that fsck can work in case of error.
The system will be mounted rw the moment fstab mounts the devices, so overall it's saver to mount rootfs as ro instead of rw
These users thanked the author meveric for the post:
MichaIng (Thu Mar 11, 2021 2:05 am)
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

User avatar
MichaIng
Posts: 62
Joined: Wed Apr 10, 2019 4:44 am
languages_spoken: english german
Has thanked: 14 times
Been thanked: 19 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by MichaIng »

Ah, great. Yes the device tree overlays just came to my mind as well. I've stolen that and the other feature switches :mrgreen:: https://github.com/MichaIng/DietPi/comm ... 55a8d7ccce

Found two typos in the setup-odroid postinst script, Odroid N2 dtoverlay section:
# hktft32 = \"hktft32\" // 3.5\" TFT from HardKernel
should have been the 3.5" TFT =>
# hktft35 = \"hktft35\" // 3.5\" TFT from HardKernel

and

if test \"x{overlays}\" != \"x\";
missing $ =>
if test \"x${overlays}\" != \"x\";
or the following simplified syntax:
if test \"\${overlays}\";
Since by default overlays are applied, nobody recognised it yet, I guess :).

And generally to test for strings in files:
if [ `grep -c "overscan" /boot/boot.ini` -lt 1 ]; then
=>
if ! grep -q "overscan" /boot/boot.ini; then
The simplified syntax which makes grep quietly return true when the pattern matches (and stops further processing) and false if not.

And another question: monitor_onoff=false does disable HDMI output? As your boot.ini sets this by default, is it overwritten by display_autodetect=true or do I misunderstand the setting?
These users thanked the author MichaIng for the post:
meveric (Thu Mar 11, 2021 10:44 pm)

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

Thanks for the info I will check the typos later and also thanks for the grep stuff :)
I'll probably stick with if test \"x${overlays}\" != \"x\"; if the variable doesn't exist at all the check may run into a syntax error and with the x the result will be at least "x" and the test has not a syntax error.

monitor_onoff is an odd flag, I was never entirely sure what it means.
If I remember correctly it will report to the system that the HDMI is always connected, even if it's not connected, which may be required for some HDMI->VGA adapters or something, I'm not sure.
display_autodetect=true is something entirely different though. That one is used to automatically determine the screen resolution of your attached monitor, so you don't have to set it manually to 1080p or something like that.
These users thanked the author meveric for the post:
MichaIng (Fri Mar 12, 2021 4:42 am)
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

User avatar
MichaIng
Posts: 62
Joined: Wed Apr 10, 2019 4:44 am
languages_spoken: english german
Has thanked: 14 times
Been thanked: 19 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by MichaIng »

The thing with test "${overlays}"/[ "${overlays}" is not an issue anymore since a long time (at least in shells), as long as the double quotes are present to always return an empty string (but a string) when the variable is empty or undeclared. But I mean it's purely visual code style, so fully okay to stick with what has always worked fine :).
EDIT: Above is wrong, at least the used U-Boot version does not support test "${overlays}" as "not empty" check.

Okay so display_autodetect "true" overrides hdmimode, thanks for clarification.

Shouldn't be disablehpd "true" disable HDMI hot-plug detection and force HDMI output regardless of attached device?
Probably monitor_onoff "true" is then the other way round to forcefully disable HDMI output :?. If that was true, the options name would be indeed confusing :D. That would make both settings incompatible and then for end-users a HDMI on/off/auto which makes sets the right combination of the above flags via if-then-else would be nice for convenience.
Last edited by MichaIng on Sat May 01, 2021 5:51 am, edited 2 times in total.

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

yeah I never fully understood why all these different options.. but you're right, I think it was to force to disable HDMI even if found.
Never tried it to be honest.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

Update:

Just a tiny update of the base image in the first post.
To fully support ODROID-N2Plus out of the box without having to update the image first :)
These users thanked the author meveric for the post (total 2):
odroid (Mon May 03, 2021 9:55 am) • m_ueberall (Mon May 03, 2021 6:36 pm)
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

drinfernoo
Posts: 2
Joined: Sat May 08, 2021 5:01 am
languages_spoken: english
ODROIDs: N2
Has thanked: 0
Been thanked: 0
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by drinfernoo »

Hey, I've just flashed this after coming from CoreELEC... but am having trouble getting my Coral USB to work. In particular, if I reboot the N2 while it is plugged in, it never boots back up.

dmesg reports:

Code: Select all

[  222.049511] usb 2-1.3: new SuperSpeed USB device number 3 using xhci-hcd
[  222.070167] usb 2-1.3: New USB device found, idVendor=1a6e, idProduct=089a
[  222.071567] usb 2-1.3: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[  222.086671] usb 2-1.3: Unsupported device
But that's pretty much all I've got... I have installed the runtime referred to here: https://coral.ai/software/#debian-packages, but still seems to be "unsupported".

Any ideas?

drinfernoo
Posts: 2
Joined: Sat May 08, 2021 5:01 am
languages_spoken: english
ODROIDs: N2
Has thanked: 0
Been thanked: 0
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by drinfernoo »

Something has gone awry here... And I appear to not be able to log into my root account anymore. The password isn't accepted. I'm not sure how that could've happened (cosmic rays?), but is there no "single-user" or "rescue" mode I can use to reset my password?

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

drinfernoo wrote:
Thu Jul 01, 2021 10:37 pm
Something has gone awry here... And I appear to not be able to log into my root account anymore. The password isn't accepted. I'm not sure how that could've happened (cosmic rays?), but is there no "single-user" or "rescue" mode I can use to reset my password?
you can not do so on this system directly but if you have an PC/VM which runs linux, you can mount the SD/eMMC and use chroot to go into the image, and with that set a new root password.
although it's very unlikely that the root password simply disappears :)
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

User avatar
mad_ady
Posts: 9685
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, C4, N1, N2, H2, Go, Go Advance
Location: Bucharest, Romania
Has thanked: 609 times
Been thanked: 721 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by mad_ady »

Chroot needs qemu, to run arm code. But you can either delete the root password hash from /etc/shadow and login without password (locally, not via ssh), or replace it with a known hash.

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

mad_ady wrote:
Fri Jul 02, 2021 4:56 am
Chroot needs qemu, to run arm code. But you can either delete the root password hash from /etc/shadow and login without password (locally, not via ssh), or replace it with a known hash.
my image has qemu included to allow chroot into the system, to do all kind of repairs and installs on an x86 system in case you need to fix something.
replacing the hash does work as well, but doing it wrong you can easily also damage the system as well, having a line break or something and suddenly the entire file becomes invalid and even system accounts will stop working.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

david_e
Posts: 3
Joined: Mon Jul 26, 2021 6:18 am
languages_spoken: english
Has thanked: 1 time
Been thanked: 0
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by david_e »

Hi Meveric, thanks for the image. I'm a developer which is focused on the low-level side of hardware (C/Assembly) but each day I learn something new and interesting about the Linux Kernel which I hope I can put into practice in designing and developing my own embedded Linux board. I am interested in knowing more about how you built the image based on the 4.9 LTS kernel. Would you mind sharing a little bit about how this process was done?

From my basic understanding, the sources for Debian are located in salsa.debian.org. Did you clone any specific repo and then just added the build instructions with a system like Yocto or Buildroot? Did you have to modify something in the kernel to support Debian, and if so is there a specific documentation part of Debian where the required changes are indicated?

You mentioned that the image on setup resizes the partition and configures SSH. Do you have the sources files forrhow you made this? I am interested in learning more about the development process for customizing Linux and projects like yours are interesting to learn more about this part of Linux.


Thanks in advanced

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

david_e wrote:
Mon Jul 26, 2021 10:45 pm
Hi Meveric, thanks for the image. I'm a developer which is focused on the low-level side of hardware (C/Assembly) but each day I learn something new and interesting about the Linux Kernel which I hope I can put into practice in designing and developing my own embedded Linux board.
Hi,

You probably be surprise on how "lazy" this is done ;)
There isn't much magic involved.
david_e wrote:
Mon Jul 26, 2021 10:45 pm
I am interested in knowing more about how you built the image based on the 4.9 LTS kernel. Would you mind sharing a little bit about how this process was done?
You don't need to re-invent the wheel.
Debian, Ubuntu and other OS offer easy way to create a new image and you don't need much to get it to work.
There is a tool called "debootstrap" in it's easiest form what it does is creates a new rootfs folder with all the tools needed for a new OS.
This is rather handy, as you only need to run one or two commands to create an entire new OS image folder.

Code: Select all

mkdir buster-rootfs
debootstrap buster ./buster-rootfs http://deb.debian.org/debian/
done, nothing else needed and you already have an OS that is capable of running if you have a working Kernel.
From here on you "only" need to supply a Kernel and configure your image to your liking and you're technically done.
For me that involves setting up password, locales, install some default applications and drivers for example firmware and WLAN tools, as well as vim as my editor of choice, mc and htop.
As I said configuration of the image.
This can be done in a chroot environment, where you just switch into the rootfs you created as your main root folder (chroot) and then install and configure as you like.

Code: Select all

cd buster-rootfs
mount --bind /proc ./proc
mount --bind /sys ./sys
mount --bind /dev ./dev
chroot .
You should do this of cause on an existing image on your ODROID of choice.
It can also be done on a normal desktop PC, but here you have to do a few steps more since arm64 is a "foreign" architecture and you have to tell the system to make a arm64 image instead of a amd64 image.
And then use qemu with chroot command.
This may sound complicated but is easy as well, ask if you need to know how.
david_e wrote:
Mon Jul 26, 2021 10:45 pm
From my basic understanding, the sources for Debian are located in salsa.debian.org. Did you clone any specific repo and then just added the build instructions with a system like Yocto or Buildroot?
None of this is necessary. Debian already has ready to use arm64 packages, why would you want to rebuild everything yourself? Use what already exist, and only add what you need.
david_e wrote:
Mon Jul 26, 2021 10:45 pm
Did you have to modify something in the kernel to support Debian, and if so is there a specific documentation part of Debian where the required changes are indicated?
There is no such thing as a "Debian Kernel". The Kernel is the Kernel it runs on Debian, Ubuntu, whatever.
I have scripts in place on my kernel-images, that the Kernel runs on both Debian and HardKernel's Ubuntu, as HardKernel uses different paths for installing the Kernel than it's normal for Debian / Ubuntu, I just added some scripts that support their paths, but you don't have to change anything on the Kernel.
The Kernel itself is provided by HardKernel: https://github.com/hardkernel/linux/ here you find the different Kernel for the different boards HardKernel has.
How to build a Kernel can be found in many different documentations. HardKernel provides one: https://wiki.odroid.com/odroid-n2/softw ... d-n2ubuntu
And you can find many general guides on how to build a Kernel.
I personally create .deb files for installation and updates of Kernels, but that's not a must have.
david_e wrote:
Mon Jul 26, 2021 10:45 pm
You mentioned that the image on setup resizes the partition and configures SSH. Do you have the sources files forrhow you made this?
They are on the image itself, check /root/scripts/ and you see the resizing script, it's no magic, just re-creating the partition table, and some other shell commands.

If you have any further questions, let me know :)
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

trwn2p
Posts: 75
Joined: Fri Oct 16, 2020 5:12 am
languages_spoken: english
ODROIDs: N2 Plus
Has thanked: 3 times
Been thanked: 13 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by trwn2p »

Not sure why you use buster when Deb 11 bullseye installs easy with tobetter netboot. Just see my posts in that thread.

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

trwn2p wrote:
Tue Jul 27, 2021 3:32 am
Not sure why you use buster when Deb 11 bullseye installs easy with tobetter netboot. Just see my posts in that thread.
Everyone is free to install what they want.
As far as I know only Kernel 4.9 supports all features of the SoC, the images from tobetter are still "slightly" limited.
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

david_e
Posts: 3
Joined: Mon Jul 26, 2021 6:18 am
languages_spoken: english
Has thanked: 1 time
Been thanked: 0
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by david_e »

meveric wrote:
Mon Jul 26, 2021 11:31 pm
You probably be surprise on how "lazy" this is done ;)
There isn't much magic involved.
That's quite good to hear!
meveric wrote:
Mon Jul 26, 2021 11:31 pm
There is a tool called "debootstrap" in it's easiest form what it does is creates a new rootfs folder with all the tools needed for a new OS.
This is rather handy, as you only need to run one or two commands to create an entire new OS image folder.
I will definitely have a look at it.
meveric wrote:
Mon Jul 26, 2021 11:31 pm
It can also be done on a normal desktop PC, but here you have to do a few steps more since arm64 is a "foreign" architecture and you have to tell the system to make a arm64 image instead of a amd64 image.
Do you mean within the debootstrap tool or when compiling the kernel with the ARCH symbol and setting the cross compiler toolchain?
meveric wrote:
Mon Jul 26, 2021 11:31 pm
And then use qemu with chroot command.
I saw this post you made here viewtopic.php?t=37284. Would that be enough?

Thanks for the useful info, once I have time I will play around with the tools and try to build my own image :)

User avatar
meveric
Posts: 11612
Joined: Mon Feb 25, 2013 2:41 pm
languages_spoken: german, english
ODROIDs: X2, U2, U3, XU-Lite, XU3, XU3-Lite, C1, XU4, C2, C1+, XU4Q, HC1, N1, Go, H2 (N4100), N2, H2 (J4105), GoA, C4, GoA v1.1, H2+, HC4, GoS
Has thanked: 71 times
Been thanked: 514 times
Contact:

Re: [OS] Debian Buster for ODROID N2

Post by meveric »

david_e wrote:
Tue Jul 27, 2021 7:13 pm
meveric wrote:
Mon Jul 26, 2021 11:31 pm
It can also be done on a normal desktop PC, but here you have to do a few steps more since arm64 is a "foreign" architecture and you have to tell the system to make a arm64 image instead of a amd64 image.
Do you mean within the debootstrap tool or when compiling the kernel with the ARCH symbol and setting the cross compiler toolchain?
I meant debootstrap.
It creates a rootfs by installing all packages necessary to have a minimal OS.
It works both on a native system (if you do it on an arm64 board it can install arm64 packages directly inside the rootfs folder)
Or can be done on a foreign system by telling it to create a debootstrap for a foreign architecture (for example on a x86_64 desktop PC):

Code: Select all

debootstrap --foreign --arch=arm64 buster ./buster-rootfs http://deb.debian.org/debian/
In that case it is a two step procedure, first it creates the rootfs, and simply downloads the required packages.
The second step involves qemu in order to run arm64 binaries on a x86_64 system and with that the packages are installed in the second stage.

Once again, this is only for creating a rootfs

Code: Select all

ll /
total 71
drwxr-xr-x  20 root root 4096 Mar 26 09:40 .
drwxr-xr-x  20 root root 4096 Mar 26 09:40 ..
drwxr-xr-x   2 root root 4096 Jul 23 01:45 bin
drwxr-xr-x   2 root root 4096 Jul  9  2019 boot
drwxr-xr-x  16 root root 3740 Apr 21 10:24 dev
drwxr-xr-x  98 root root 4096 Jul 24 11:41 etc
drwxr-xr-x   2 root root 4096 Jul  9  2019 home
drwxr-xr-x  12 root root 4096 Jul 27 09:35 lib
drwxr-xr-x   2 root root 4096 Aug  4  2020 media
drwxr-xr-x   2 root root 4096 Aug  4  2020 mnt
drwxr-xr-x   2 root root 4096 Aug  4  2020 opt
dr-xr-xr-x 152 root root    0 Jan  1  1970 proc
drwx------   8 root root 4096 Jul 27 11:53 root
drwxr-xr-x   5 root root 4096 Nov 20  2020 run
drwxr-xr-x   2 root root 4096 Jul 23 01:45 sbin
drwxr-xr-x   2 root root 4096 Aug  4  2020 srv
dr-xr-xr-x  13 root root    0 Feb  3 22:00 sys
drwxrwxrwt   7 root root 4096 Jul 27 11:57 tmp
drwxr-xr-x  15 root root 4096 Nov  2  2020 usr
drwxr-xr-x  11 root root 4096 Aug  4  2020 var
Which can than be put on an SD/eMMC so you have an OS that you can boot with all the tools you're used to from Linux.
david_e wrote:
Tue Jul 27, 2021 7:13 pm
meveric wrote:
Mon Jul 26, 2021 11:31 pm
And then use qemu with chroot command.
I saw this post you made here viewtopic.php?t=37284. Would that be enough?

Thanks for the useful info, once I have time I will play around with the tools and try to build my own image :)
Yes that is how you would run the second stage of the debootstrap process when you run it on a desktop pc (x86_64) instead of natively.
It also allows you to run commands inside the rootfs, to install extra packages for example and things like that.

Here is a "easy" way to get a "fully" bootable image:

1. get an already existing image (like my Debian images for example) and flash it on an SD/eMMC and mount it on your system (for example into /mnt/rootfs)
2. make a backup of /lib/modules/ (which is the Kernel modules that are in use)
3. delete all files of the rootfs (just delete them, do NOT re-format the partition, or the UUID will change)
4. create your own debootstrap image (for example for Debian Buster, or Debian Bullseye)
5. copy the content of the debootstrap-rootfs folder that you created on the now empty rootfs partition of the SD/eMMC (for example: cd buster-rootfs; rsync -avrP --numeric-ids . /mnt/rootfs)
6. copy back the files from /lib/modules

You now have a image that has the same Kernel image you flashed on the SD/eMMC, but with your own rootfs, what ever that is.
The image should be able to boot just fine. It will most likely require some adaptations later on, setting passwords, setting fstab and things like that. But from that point on, it's entirely your image, what ever you want to make out of it.
These users thanked the author meveric for the post (total 2):
odroid (Wed Jul 28, 2021 9:49 am) • david_e (Wed Aug 11, 2021 12:24 am)
Donate to support my work on the ODROID GameStation Turbo Image for U2/U3 XU3/XU4 X2 X C1 as well as many other releases.
Check out the Games and Emulators section to find some of my work or check the files in my repository to find the software i build for ODROIDs.
If you want to add my repository to your image read my HOWTO integrate my repo into your image.

Post Reply

Return to “Other OS”

Who is online

Users browsing this forum: No registered users and 1 guest