31
Audio Playback, Database and Playlists / Re: Converting ID3 image tags from PNG to JPG
« Last post by saratoga on April 13, 2024, 09:12:31 PM »One thing that jumps out at me is the write_v24 bit:
If you try writing the default 2.3 tags do they parse?
-----
You could try decoding one of the files in the UI simulator to see if it throws an error. 1000x1000 is a bit big but should work fine.
There are some old windows sim builds if you want to try quickly without building from scratch: http://rasher.dk/rockbox/simulator/ They're really out of date but should be ok for testing ID3 parsing.
Quote
write_v24
If FALSE (default), writing of ID3v2.4 is prohibited (it is not fully supported; allow on your own risk).
If you try writing the default 2.3 tags do they parse?
-----
You could try decoding one of the files in the UI simulator to see if it throws an error. 1000x1000 is a bit big but should work fine.
There are some old windows sim builds if you want to try quickly without building from scratch: http://rasher.dk/rockbox/simulator/ They're really out of date but should be ok for testing ID3 parsing.
32
Other - Installation/Removal / Re: Surfans F20 "NAND open error"
« Last post by amachronic on April 13, 2024, 07:22:20 PM »Ok, so the LCD configuration is in firmware/target/mips/ingenic_x1000/erosqnative/lcd-erosqnative.c. Vertical/horizontal flip is controlled by this command:
The data byte is what controls the orientation. Bit 7 = vertical flip, bit 6 = horizontal flip. The "inverted" build is just a horizontal flip, so 0xd8 becomes 0x98. Bit 3 is RGB/BGR order, so changing that may help fix the colors.
Another thing you can try is adding the "display invert on" command (0x21), assuming the default is non-inverted; maybe also try 0x20 "display invert off" just in case it defaults to on for some reason.
To stop the display from going to sleep you can comment out / remove the code in lcd_tgt_sleep(), the backlight will still turn off but the controller will keep running normally.
I don't remember if dconrad ever figured out what the display controller was... not that it would help since you could have a different one, but most of them support a similar command set (called MIPI DCS) and you can check eg. the ILI9341 datasheet for info.
Code: [Select]
/* Set Address Mode */
LCD_INSTR_CMD, 0x36,
LCD_INSTR_DAT, 0xd8,
The data byte is what controls the orientation. Bit 7 = vertical flip, bit 6 = horizontal flip. The "inverted" build is just a horizontal flip, so 0xd8 becomes 0x98. Bit 3 is RGB/BGR order, so changing that may help fix the colors.
Another thing you can try is adding the "display invert on" command (0x21), assuming the default is non-inverted; maybe also try 0x20 "display invert off" just in case it defaults to on for some reason.
Code: [Select]
// vvv add this
LCD_INSTR_CMD, 0x21,
// ^^^
/* Exit Sleep */
LCD_INSTR_CMD, 0x11,
LCD_INSTR_UDELAY, 120000,
/* Display On */
LCD_INSTR_CMD, 0x29,
LCD_INSTR_UDELAY, 20000,
LCD_INSTR_END,
To stop the display from going to sleep you can comment out / remove the code in lcd_tgt_sleep(), the backlight will still turn off but the controller will keep running normally.
I don't remember if dconrad ever figured out what the display controller was... not that it would help since you could have a different one, but most of them support a similar command set (called MIPI DCS) and you can check eg. the ILI9341 datasheet for info.
33
Audio Playback, Database and Playlists / Re: Converting ID3 image tags from PNG to JPG
« Last post by wintermute23 on April 13, 2024, 06:16:08 PM »Yeah, as I say, RockBox can read the file generated. I've considered just dropping the JPG into the directory with the same filename as the podcast (that should work, right?), but whit it copies podcasts over to my iPod, it reports a pretty naïve count of files copied, and I'd need to rework that to something more complicated to make it work properly.
Not entirely out of the question, but getting the art properly embedded is definitely the more elegant solution.
Not entirely out of the question, but getting the art properly embedded is definitely the more elegant solution.
34
Audio Playback, Database and Playlists / Re: Converting ID3 image tags from PNG to JPG
« Last post by philden on April 13, 2024, 05:45:21 PM »Have you tried saving the jpeg as a separate file instead of being embedded?
35
Audio Playback, Database and Playlists / Re: Converting ID3 image tags from PNG to JPG
« Last post by wintermute23 on April 13, 2024, 02:58:03 PM »That's certainly worth trying. That 1000×1000 limit was added because the sample file I'm using had an embedded image that was 3600×3600, which seemed excessive. Quite a few of the music files I have have cover art in the 1000×1000 range, so it didn't occur to me it might be a problem.
And after a quick test, changing the image size to 190×190, it's still not working.
And after a quick test, changing the image size to 190×190, it's still not working.
36
Audio Playback, Database and Playlists / Re: Converting ID3 image tags from PNG to JPG
« Last post by philden on April 13, 2024, 02:45:00 PM »I'm not experienced with Perl, but does your code generate a 1000x1000 pixel jpeg? If so this is very big. I'd try making a much smaller file which will take less memory to display. I'd suggest a maximum of 300x300, or use the exact size that your favourite theme uses.
37
Audio Playback, Database and Playlists / Converting ID3 image tags from PNG to JPG
« Last post by wintermute23 on April 13, 2024, 01:38:17 PM »I have an issue which is similar to https://forums.rockbox.org/index.php/topic,54788.0.html.
I have a podcatcher I wrote myself in perl, which checks listed RSS feeds, looks for new items, downloads them and prepares an .m3u8 playlist for me. I have album art set for each feed in the appropriate directory, but quite often each episode has its own artwork embedded in PNG format, and I'd like to be able to convert it to JPG so that it shows up on RockBox.
Because this conversion happens when each file gets downloaded, batch processing isn't really a valid solution. I've got something that almost works, shown below. The JPG file it produces can be displayed by RockBox's Image Viewer plugin, and an ID3 inspector shows me that the finished MP3 file has a JPG embedded image. So every individual step seems to be working, but when I play the file, the album art isn't displayed.
Can anyone help me figure out what I might be missing? Thanks.
My image conversion code:
I have a podcatcher I wrote myself in perl, which checks listed RSS feeds, looks for new items, downloads them and prepares an .m3u8 playlist for me. I have album art set for each feed in the appropriate directory, but quite often each episode has its own artwork embedded in PNG format, and I'd like to be able to convert it to JPG so that it shows up on RockBox.
Because this conversion happens when each file gets downloaded, batch processing isn't really a valid solution. I've got something that almost works, shown below. The JPG file it produces can be displayed by RockBox's Image Viewer plugin, and an ID3 inspector shows me that the finished MP3 file has a JPG embedded image. So every individual step seems to be working, but when I play the file, the album art isn't displayed.
Can anyone help me figure out what I might be missing? Thanks.
My image conversion code:
Code: [Select]
#!/usr/bin/perl
use strict;
use Imager;
use MP3::Tag;
use Data::Dumper;
my $input = "~/Documents/test.mp3";
my $mp3 = MP3::Tag->new($input);
my @tags = $mp3->get_id3v2_frame_ids();
print Dumper(@tags);
if ($mp3->have_id3v2_frame_by_descr("APIC")) {
print "Picture exists\n";
# Read the image into a variable
my $png_img = $mp3->select_id3v2_frame_by_descr("APIC");
# Import the image into Imager for conversion
if (open(my $fh_png, "<:raw", \$png_img)){
print "Is PNG\n";
my $converter = Imager->new();
$converter->read(fh=>$fh_png);
$converter = $converter->scale(xpixels=>1000, ypixels=>1000, type=>'min');
my $jpg_img;
# Write to a stream that can be written into the ID# tag
open(my $fh_jpg, ">:raw", \$jpg_img) or die "Cannot open JPG stream";
$converter->write(fh=>$fh_jpg, type=>"jpeg", jpeg_progressive=>0) or die "Cannot write: ", $converter->errstr;
close($fh_jpg);
# Write to a file
open(my $fh, ">:raw", "~/Documents/test.jpg") or die "Cannot open JPG file";
$converter->write(fh=>$fh, type=>"jpeg", jpeg_progressive=>0) or die "Cannot write: ", $converter->errstr;
close($fh);
# Update the ID3 tag
$mp3->select_id3v2_frame_by_descr("APIC", $jpg_img) or die "Cannot update MP3";
$mp3->config(write_v24 => 1) or die "Cannot set config";
$mp3->update_tags() or die "Cannot update tags";
close($fh_png);
}
}
38
Rockbox General Discussion / Best Players?
« Last post by redblade8 on April 12, 2024, 06:05:20 PM »Hello, Im wondering whats the best players for fm, voice & running GBC emulation?
Thanks =)
- Red.
Thanks =)
- Red.
39
Other - Installation/Removal / Re: Installing rockbox on HiFiMAN HM-603 Slim - boot hangs
« Last post by Infine on April 12, 2024, 03:53:52 PM »I don't think I've run into that problem, but I assume F/W means firmware? Maybe something went wrong not with rockbox, but with the firmware or bootloader? Can you boot the original firmware? When does the loading get stuck?
Here's a 4mb build I assume I had: https://drive.google.com/file/d/1csd8Xj3j-UXd7dLRO8WWGvcomWLVS7FU/view?usp=sharing
I'm not 100% sure it's the one I used, but it's the most likely one.
I'll probably try getting my device back to work again to see how if and how it works sometime during the weekend, and maybe just give you an archive of the whole filesystem if it manages to run properly.
As for being unable to build it, maybe try building an older version? Like 3.13 or something. I assume VM method being obsolete might mean it can't build newer versions
EDIT: https://drive.google.com/file/d/18awDyV4Gc8duXEwtQtRVSkWnuI4gVbg8/view?usp=sharing
This is a bunch of stuff I used to reanimate my device.
It contains the .rockbox folder that goes to SD card (i used 32GB kingston, FAT32) with BASE.RKW from 007 firmware and a modified 007 image with bootloader installed that goes to internal storage.
I hope you didn't bork the loader (because it looks like it's your case - the rockbox bootloader starts with some white text on black background) and it can load from the card. Because idunno how to access internal storage without the OG firmware working. I heard there's a way to flash it with some rokchip SDK, but that's a question to mortalis.
EDIT2: in case you are truly bricked, here's some findings https://www.head-fi.org/threads/how-to-installing-and-uninstalling-rockbox-to-the-hifiman-hm-801-603-602-and-601.579759/. Particularly, post 11. Unfortunately all the links to the tools are dead, but at least it's some direction to dig towards. Only try it if you truly bricked it.
Here's a 4mb build I assume I had: https://drive.google.com/file/d/1csd8Xj3j-UXd7dLRO8WWGvcomWLVS7FU/view?usp=sharing
I'm not 100% sure it's the one I used, but it's the most likely one.
I'll probably try getting my device back to work again to see how if and how it works sometime during the weekend, and maybe just give you an archive of the whole filesystem if it manages to run properly.
As for being unable to build it, maybe try building an older version? Like 3.13 or something. I assume VM method being obsolete might mean it can't build newer versions
EDIT: https://drive.google.com/file/d/18awDyV4Gc8duXEwtQtRVSkWnuI4gVbg8/view?usp=sharing
This is a bunch of stuff I used to reanimate my device.
It contains the .rockbox folder that goes to SD card (i used 32GB kingston, FAT32) with BASE.RKW from 007 firmware and a modified 007 image with bootloader installed that goes to internal storage.
I hope you didn't bork the loader (because it looks like it's your case - the rockbox bootloader starts with some white text on black background) and it can load from the card. Because idunno how to access internal storage without the OG firmware working. I heard there's a way to flash it with some rokchip SDK, but that's a question to mortalis.
EDIT2: in case you are truly bricked, here's some findings https://www.head-fi.org/threads/how-to-installing-and-uninstalling-rockbox-to-the-hifiman-hm-801-603-602-and-601.579759/. Particularly, post 11. Unfortunately all the links to the tools are dead, but at least it's some direction to dig towards. Only try it if you truly bricked it.
40
Other - Installation/Removal / Re: Installing rockbox on HiFiMAN HM-603 Slim - boot hangs
« Last post by lisk on April 12, 2024, 09:11:50 AM »Greetings!
It was me who sent you email. Great thanks for your detailed answer! And excuse me for long response, I tried to create operable Rockbox build follow your advices and rockbox's instructions, but I failed.
As I understood from Github instruction, the build must be created at Linux, so the first my attempt was to use Ubuntu app from Microsoft store.
Using this instructions https://www.rockbox.org/wiki/Windows10CrossCompiler I installed dependencies and built the cross compiler (at the point with selecting the compiler I chose ARM because of line t_cpu="arm" in hifimanhm60x section in configure.sh), then built simulator (tried both versions of SDL - 2.30 which is the newest and 1.2 which is mentioned in instructions). I created some Rockbox builds with different memory (2, 4, 8 and default 16), editing configure.sh; platform always was Normal (N).
All this builds weren't working; attempts to load them on sd-card with further reboot lead to F/W data error ID: 2 (screenshot in attachments).
I thought that reason could be wrong dependencies installation (versions or something) or building process, so I found already prepared Ubuntu image here https://www.rockbox.org/wiki/DevelopmentGuide.html#Virtual_Machine_40Obsolete_41 (second link is still alive) and download it.
There I tried only configure and make scripts from https://github.com/Rockbox/rockbox, but they even weren't finished (another screenshot in attachments).
So at the moment I have no idea what should I try to create working Rockbox build
It was me who sent you email. Great thanks for your detailed answer! And excuse me for long response, I tried to create operable Rockbox build follow your advices and rockbox's instructions, but I failed.
As I understood from Github instruction, the build must be created at Linux, so the first my attempt was to use Ubuntu app from Microsoft store.
Using this instructions https://www.rockbox.org/wiki/Windows10CrossCompiler I installed dependencies and built the cross compiler (at the point with selecting the compiler I chose ARM because of line t_cpu="arm" in hifimanhm60x section in configure.sh), then built simulator (tried both versions of SDL - 2.30 which is the newest and 1.2 which is mentioned in instructions). I created some Rockbox builds with different memory (2, 4, 8 and default 16), editing configure.sh; platform always was Normal (N).
All this builds weren't working; attempts to load them on sd-card with further reboot lead to F/W data error ID: 2 (screenshot in attachments).
I thought that reason could be wrong dependencies installation (versions or something) or building process, so I found already prepared Ubuntu image here https://www.rockbox.org/wiki/DevelopmentGuide.html#Virtual_Machine_40Obsolete_41 (second link is still alive) and download it.
There I tried only configure and make scripts from https://github.com/Rockbox/rockbox, but they even weren't finished (another screenshot in attachments).
So at the moment I have no idea what should I try to create working Rockbox build