Jump to content

Clover General discussion


ErmaC
30,171 posts in this topic

Recommended Posts

odd - i'm on 4852 

i put sound.wav from Clovy in the ThinkPad folder...

but says File not found using embedded sound -  which sounds really lowFI - more like a guitar strum than mac chime?

wonder why it doesn't find the sound.wav file?

 

update: added 2nd sound file and it sounds normal vs embedded 

ah it needed sound_night.wav too. for some reason clover thinks its nighttime ?!

 

5:234  0:001  === [ InitTheme ] =========================================

5:255  0:020  use night theme

5:258  0:002  Using theme 'ThinkPad' (EFI\CLOVER\themes\ThinkPad)

5:258  0:000  OS main and drive as badge

5:259  0:000  Warning! Character width 9 should be even!

5:259  0:000  file sound read: Not Found

5:260  0:000  got embedded sound

5:260  0:000    Channels: 2  Sample rate: 8000 Hz  Bits: 16

5:261  0:000  output to channel 1 with volume 80, len=25600

5:262  0:000   sound channels=2 bits=16 freq=8000

5:262  0:000  sound converted to 48kHz

6:511  1:248  Loading font from ThemeDir: Success

6:512  0:000  theme inited

6:512  0:000  Chosen theme ThinkPad

Edited by tluck
  • Like 3
Link to comment
Share on other sites

29 minutes ago, MakAsus said:
For me, version 4848 works fine with files from version 4851. Most of the changes were in the StartupSound.c file. Unfortunately, I am not a good programmer. I would fix the problem, but I do not know how!

I see...i haven't tried to use 4848 with files from 4851. I assumed the issue was with the AudioDxe driver itself , so I replaced that upon installation of 4848.

Also I'm not a programmer. So can't really help with that either.

 

Edited by arsradu
  • Like 1
Link to comment
Share on other sites

25 minutes ago, tluck said:

odd - i'm on 4852 

i put sound.wav from Clovy in the ThinkPad folder...

but says File not found using embedded sound -  which sounds really lowFI - more like a guitar strum than mac chime?

wonder why it doesn't find the sound.wav file?

 

5:234  0:001  === [ InitTheme ] =========================================

5:255  0:020  use night theme

5:258  0:002  Using theme 'ThinkPad' (EFI\CLOVER\themes\ThinkPad)

5:258  0:000  OS main and drive as badge

5:259  0:000  Warning! Character width 9 should be even!

5:259  0:000  file sound read: Not Found

5:260  0:000  got embedded sound

5:260  0:000    Channels: 2  Sample rate: 8000 Hz  Bits: 16

5:261  0:000  output to channel 1 with volume 80, len=25600

5:262  0:000   sound channels=2 bits=16 freq=8000

5:262  0:000  sound converted to 48kHz

6:511  1:248  Loading font from ThemeDir: Success

6:512  0:000  theme inited

6:512  0:000  Chosen theme ThinkPad

 

Not sure...but sound file should be 44100 Hz (44.1 KHz). At least these are the instructions provided here.

 

You can try the attached one, if you want.

sound.wav

 

EDIT: nevermind. Now I saw the 8 Khz embedded sound from commit 4852. My bad. :) You can still try the attached file, if you want.

Edited by arsradu
  • Like 1
Link to comment
Share on other sites

1 hour ago, tluck said:

made me LOL when i heard it work (after adding sound_night.wav) ! now i need to figure out timezone thing.

 

I installed 4852 as well, and I've got two issues:

 

1. the sound is really weird. Just like you said.

2. F7 while it doesn't freeze the UI anymore, it also doesn't seem to play back the sound... Not sure what's going on with that.

 

Did you manage to make it play the actual file you set up in the theme folder? Cause I don't think the embedded one has anything to do with that.

Edited by arsradu
  • Like 1
Link to comment
Share on other sites

4852: there is a logic issue in Clover/rEFIt_UEFI/Platform/Settings.c 

 

problems is it wont try to open sound.wav if !Daylight is false (i.e DayLight is true)

(DayLight is true when timezone corrected time is between 8:00 and 20:00)

 

the other logic issue was it would alway play embedded sound instead of sound.wav since it would never come back with failed status.

 

also NowHour needs to adjusted if < 0

i.e if NowHour < 0 ; then NowHour = NowHour +24

 

 

original:

    if (!DayLight) {

      Status = StartupSoundPlay(ThemeDir, L"sound_night.wav", OldChosenAudio);

    }

    if (EFI_ERROR(Status)) {

      Status = StartupSoundPlay(ThemeDir, L"sound.wav", OldChosenAudio);

    }

 

NEW

 

  if (!ThemeDict) {  // No theme could be loaded, use embedded

    DBG (" using embedded theme\n");

...

      Status = StartupSoundPlay(ThemeDir, L"embedded", OldChosenAudio);

  } else { // theme loaded successfully

...

    if (!DayLight) {

      Status = StartupSoundPlay(ThemeDir, L"sound_night.wav", OldChosenAudio);

      if (EFI_ERROR(Status)) { Status = StartupSoundPlay(ThemeDir, L"sound.wav", OldChosenAudio); }

    else {

      Status = StartupSoundPlay(ThemeDir, L"sound.wav", OldChosenAudio);

    }

 

  }

 

fixed using this logic:

if there is a real theme with 1 or 2 sound files (sound.wav and sound_night.wav)

 

check for nightime 

       and try to use sound_night.wav

if no sound_night.wav

    use sound.wav

 

 

i chose to use embedded sound ONLY when using embedded theme rather than fall back. but this is just an opinion.

 

--------------

$ diff /Extra/Clover_Install/CloverGrowerPro/edk2/Clover/rEFIt_UEFI/Platform/Settings.c /Temp/Settings.c 

2719c2719

<           } else if (AsciiStriCmp (Prop->string, "Daytime") == 0) {

---

>           } else if (AsciiStriCmp (Prop->string, "DayTime") == 0) {

4195a4196

>       Status = StartupSoundPlay(ThemeDir, L"embedded", OldChosenAudio);

4211,4212c4212,4213

<     }

<     if (EFI_ERROR(Status)) {

---

>       if (EFI_ERROR(Status)) { Status = StartupSoundPlay(ThemeDir, L"sound.wav", OldChosenAudio); }    

>     } else {

 

$ diff /Extra/Clover_Install/CloverGrowerPro/edk2/Clover/rEFIt_UEFI/Platform/StartupSound.c  /Temp/StartupSound.c 

71c71

<   if (SoundFile) {

---

>   if ( StriCmp(SoundFile, L"embedded") != 0 ) {

74c74,75

<       DBG("file sound read: %r\n", Status);

---

>       DBG("file sound read: %s %r\n", SoundFile, Status);

>       return Status;

76,77c77

<   }

<   if (EFI_ERROR(Status)) {

---

>   } else {

 

 

4852_fixes.zip

Edited by tluck
added sample fixes + update on NowHour bug
  • Like 3
Link to comment
Share on other sites

@arsradu

Accepted

 

@tluck

I accepted your code with some deviations.

1. About letter case Daytime or DayTime. config-sample uses lowcase but it doesn't matter Clover checks case-independent AsciiStriCmp().

2. About name embedded. I uses NULL as many other settings for embedded theme. Why not?

 

@all

There is still an issue with PlayAsync=YES. Clover hangs after play. Use NO until the issue will be resolved.

 

  • Like 3
Link to comment
Share on other sites

In version 4852 when I press F7 to any output, no longer hangs, but there is no sound, and most importantly, the sound does not appear at the start. If you configure the output and volume by BootChimeCfg.efi, then the sound appear at the start fine. :) I using the built-in version 4852 drivers now.

log fragment:

8:426  0:000  Using vector theme 'Clovy' (EFI\CLOVER\themes\Clovy)
8:443  0:016    Channels: 2  Sample rate: 44100 Hz  Bits: 16
8:443  0:000  output to channel 2 with volume 90, len=421120
8:443  0:000   sound channels=2 bits=16 freq=44100
11:239  2:795  theme inited

Here is a complete dump of the case when there is no sound:

nvramdump.txt

Edited by MakAsus
  • Like 1
Link to comment
Share on other sites

2 hours ago, MakAsus said:
In version 4852 when I press F7 to any output, no longer hangs, but there is no sound, and most importantly, the sound does not appear at the start. If you configure the output and volume by BootChimeCfg.efi, then the sound appear at the start fine.  I using the built-in version 4852 drivers now.

log fragment:


8:426  0:000  Using vector theme 'Clovy' (EFI\CLOVER\themes\Clovy)8:443  0:016    Channels: 2  Sample rate: 44100 Hz  Bits: 168:443  0:000  output to channel 2 with volume 90, len=4211208:443  0:000   sound channels=2 bits=16 freq=4410011:239  2:795  theme inited
 

Here is a complete dump of the case when there is no sound:

nvramdump.txt

 

Have you tried 4853?

 

F7 is still a little buggy. But you shouldn't need BootChimeCfg.efi anymore, aaand...as Steve Jobs loved to say: it just works. I mean, the UI might still need some tweaking. But it does pretty much what I wanted it to do by default.

 

Give this one a try (attached). See if it works for you.

Clover_v2.4k_r4853.zip

 

Update: although BootChimeCfg.efi is not necessary with this build in order to get the boot sound, and the bug with the guitar distorted kind of sound was fixed with this build, the configuration UI doesn't seem to work as of right now, so, the only way I could find to configure the volume, for example, is from Shell, using BootChimeCfg.efi.

 

So, you probably shouldn't remove it just yet.

 

In the UI, if you try to change the volume (from already set 60 to 70 for example), it will reset itself to 0000.

Also, not sure if this is intended, but, no matter which output device you select, when you enter this section, it will always default to the first one, although that is not the one used for sound.

And, as I mentioned in my previous messages, F7 doesn't play back the sound for testing.

 

 

Screenshot1.thumb.png.c062bae00bdae9332fba6fe0296f193f.png

Edited by arsradu
  • Like 2
Link to comment
Share on other sites

1 hour ago, arsradu said:

In the UI, if you try to change the volume (from already set 60 to 70 for example), it will reset itself to 0000.

Also, not sure if this is intended, but, no matter which output device you select, when you enter this section, it will always default to the first one, although that is not the one used for sound.

And, as I mentioned in my previous messages, F7 doesn't play back the sound for testing.

 

Same for me on my ASRock Z370 Prof. Gaming i7 running Clover 4853 rev.

Also rev. 4853 seems to hang before it enters CLOVER Menu. I have NO BootChimexxx in my EFI folder (no BootChime.efi, either NO BootChimeCFG). Just AudioDXE.efi in DriversX64 folder.

  • Like 1
Link to comment
Share on other sites

2 minutes ago, Mork vom Ork said:

 

Same for me on my ASRock Z370 Prof. Gaming i7 running Clover 4853 rev.

Also rev. 4853 seems to hang before it enters CLOVER Menu. I have NO BootChimexxx in my EFI folder (no BootChime.efi, either NO BootChimeCFG). Just AudioDXE.efi in DriversX64 folder.

 

Yep, there's also that. Though Clover might reserve some space...to make sure the sound is played? I don't know. I'm probably wrong.

 

Yeah, you don't need BootChimeCfg...technically. But, since the UI doesn't work yet, it might be a good idea to keep it around if you wanna tweak the volume, for example.

  • Like 1
Link to comment
Share on other sites

9 minutes ago, Download-Fritz said:

@Slice The sound files from the cesium theme make me want to put up a donation towards the health of whatever living thing made that noise, can you forward it?

 

I heard it before when he posted the changes for 4833 here. And I was like: wth is that? :)) Is that yawning...or what?

 

I guess they are just test files. :) And probably royalty free.

  • Like 1
Link to comment
Share on other sites

LoL.. You know what, I thought that my audio device was broken when hearing sound.wav from r4833 provided by @Slice till I realized it hah haa..my bad I didn't preview the file b4 placing to theme dir when install clover via ubuntu linux :D

  • Like 1
Link to comment
Share on other sites

2 hours ago, Download-Fritz said:

@Slice The sound files from the cesium theme make me want to put up a donation towards the health of whatever living thing made that noise, can you forward it?

She is Nikary. You may send donation to me.

  • Like 4
  • Haha 1
Link to comment
Share on other sites

Cool. The startup sound now plays on my laptop with 4855. Without using BootChimeCfg then clearing NVMRAM, I can set the volume and device output variable with Clover. The volume is saved but the device output isn't. So I still have to use BootChimeCfg in order to save all the parameters to NVRAM. 

 

You guys are mad geniuses. 

Edited by Tobiko
Had extra words
  • Like 1
Link to comment
Share on other sites

I have a diff, but it based on revision 4853.  I never blame Slice, since he was always faster than me.

This patches contain some fixes for audio volume, port and also device to work with/from GUI and BootChimeCfg.

Please do check -or- take some -or- improve as usual and sync it with latest revision.

 

*update attachment

 

diff.diff.zip

Edited by cecekpawon
  • Like 3
  • Thanks 1
Link to comment
Share on other sites

[mention=112217]Slice[/mention] audio does not work on the bootloader and there is no option to change the volume to the clover GUI

234198530_Schermata2019-01-21alle09_45_42.thumb.png.056cfe49b046b032d14be6e6473dd51d.png

You mean the volume of the startup sound?

 

Does it work from Shell? Can you test the sound from there?

 

Cause there is an option in Clover’s GUI for that. You can see it in one of my screenshots above. But last time I tried it, it didn’t work very well (reset itself to 0000 when trying to change the volume). So I used BootChimeCfg.efi, accessed from Shell to adjust the volume. It’s a workaround.

 

You have to make sure you’re using the latest build. 4851 had some issues. But 4853 worked perfectly fine for me (aside from the GUI issues I mentioned above).

  • Like 1
Link to comment
Share on other sites

12 minutes ago, Emanuele-1998 said:

@Slice audio does not work on the bootloader and there is no option to change the volume to the clover GUI

 

Can you give me preboot.log?

And wait for next Clover revision with some bugs corrected.

27 minutes ago, cecekpawon said:

Please take whatever it needs Slice _/|\_

Some notes.

1. I don't like ReallocatePool when we deal with 20*sizeof(HDA_OUTPUTS) bytes. May be 30 but not more.

2. F7 souldn't play sound file because it may absent. It's better to test hardware on a sound we sure to be playable.

3. About gSettings I am not decided finally. Keep only AudioVolume? What about other audio settings?

4. Currently we using gBootChimeVendorVariableGuid as Goldfish64 do. But it is not good for legacy Clover. May be remake to gAppleBootGuid? In this case we got saving audio parameters even with legacy Clover but we will loose original project compatibility.

 

PS. I need some ideas why PlayAsync is not working.

  • Like 2
Link to comment
Share on other sites

22 minutes ago, Slice said:

Can you give me preboot.log?

And wait for next Clover revision with some bugs corrected.

Some notes.

1. I don't like ReallocatePool when we deal with 20*sizeof(HDA_OUTPUTS) bytes. May be 30 but not more.

2. F7 souldn't play sound file because it may absent. It's better to test hardware on a sound we sure to be playable.

3. About gSettings I am not decided finally. Keep only AudioVolume? What about other audio settings?

4. Currently we using gBootChimeVendorVariableGuid as Goldfish64 do. But it is not good for legacy Clover. May be remake to gAppleBootGuid? In this case we got saving audio parameters even with legacy Clover but we will loose original project compatibility.

 

@Slice I switched to 4855 and it works but the audio output does not remain fixed and when restarting it disappears remaining unchecked, then I can not boot via the HDMI because they are still in the process of being true?

 

I send you an example video, also as you can see the start of the clover gui is very slow even in the latest stable version, and pressing U that would be the button to shut down causes a bug.

1CE18938-4024-4443-8747-FCF1FC2883A7.jpeg

Edited by Emanuele-1998
  • Like 1
Link to comment
Share on other sites

×
×
  • Create New...