therealahrion / ViPER4Android-FX-Legacy

ViPER4AndroidFX Legacy
86 stars 20 forks source link

Cracking samsung bootanimation sound #10

Closed VinhNgT closed 6 years ago

VinhNgT commented 6 years ago

Maybe set a delay before kill the audio server ?

Zackptg5 commented 6 years ago

The results will still be the same except that you might want see the so open/close. You could try it and see what happens but I doubt it would change anything (add a sleep command in service.sh script)

VinhNgT commented 6 years ago

I added sleep 5 and the sound no longer cracking, that why i asked you to add some delay into your module, I don't know if it will cause any problem though

Zackptg5 commented 6 years ago

Sorry for the delay. When did you set the sleep command in the script?

VinhNgT commented 6 years ago

After i noticed the cracking boot sound of course

Zackptg5 commented 6 years ago

I mean where in the service.sh script did you put it haha

VinhNgT commented 6 years ago

Right after the "#!/system/bin/sh"

Zackptg5 commented 6 years ago

Oh, that could cause issues. Can you move if after the sepolicy statements (right before the am start command) and see if that does the trick too?

Zackptg5 commented 6 years ago

Actually, better yet, before the am start command, put: ( sleep 5

Then at the end of the script, put: )&

VinhNgT commented 6 years ago

Yeah, seem like it work too

VinhNgT commented 6 years ago

Btw English is not my primary language so sorry for any inconvenience :)

Zackptg5 commented 6 years ago

Hmm, so I tested it on my op5t (which is one of the problem devices that needs the am start stuff). When I put the ( )& around that section (which means that other scripts can run while that section is still going), it doesn't work. The problem is that if we have the sleep statement not inside ( )&, then other service scripts will get delayed which could break other modules. So I can't think of a way to add this to the mod for that reason. This leaves you with 2 options: 1) Remove boot animation sound (system/media/audio/ui/PowerOn.ogg) 2) Delete the sleep 5, and the last 3 lines of the service.sh script (the am start line and lines after it). Since it worked for you with the ( )&, that means that you don't need that stuff anyways. (I think this would be the best option for you)

Zackptg5 commented 6 years ago

I added this to the troubleshooting section on the OP in case other users run into this

VinhNgT commented 6 years ago

Ok, thanks for the support, it's just so annoying that every time i boot the phone, i have to hear the crazy "TV-static-sound" for like 1 second

Zackptg5 commented 6 years ago

No problem. Hopefully v4a will get updated for oreo so we won't need these weird workarounds anymore