Commit graph

39317 commits

Author SHA1 Message Date
Christian Soffke
cd699e5448 configure: darwin: update GCC, use SDL threads
The simulator on macOS has been broken since macOS 26.4
was introduced. On macOS 26.4, 26.5, and the 27 beta,
thread setup fails in make_context (firmware/asm/thread-
unix.c), because sigaltstack returns an "Operation not
permitted" error. Fall back to SDL threads until this
can be fixed.

Also update GCC to keep it in sync with the latest
Homebrew formula
(https://formulae.brew.sh/formula/gcc).

Change-Id: Ib08ac81ede00c577f28a85c7886f716e7504bbe9
2026-06-19 21:40:11 +02:00
William Wilgus
7a32c8b5e3 [Bugfix] lua splash_scroller line formatting
I accidentally added an extra character wittthe last patch by changing
< to <= in the process of testing this I realized spaces were sometimes
being included at the beginning of the line and also that sometime
sentences were being cut short even though they fit on the screen

Change-Id: Iee0ed64e18defad2acb3c107d334ea2a49bd5b6f
2026-06-18 22:21:16 -04:00
Solomon Peachy
c0027abd0e misc: Update gitignore to cover a bunch of utils/* binaries
Change-Id: If78f82aa09f7b4008f44d9c3101438968b9bd69d
2026-06-17 13:56:29 -04:00
Solomon Peachy
5a838851ed utils: More warning fixes
Change-Id: Ie7af33ab0e3ac43f93a4cf2df50ddac10243b9f7
2026-06-17 13:56:29 -04:00
William Wilgus
ca2edad012 [Bugfix] FS#13926 -lua Crash when displaying error splash
fix lua strpbrk function skipping the first accept chr

lua splash_scroller fix NULL pointer in brk due to lastbreak
not being reset on a new line

Change-Id: Ica0c9ee5f9194f5be54ab90ad16309adead1c207
2026-06-17 13:55:43 -04:00
mojyack
7154fcd9a8 usb: iap: workaround cur/set freq mismatch
Change-Id: I75a36c9dfd33e7f9192101220633137e5ad98411
2026-06-17 11:01:34 -04:00
Solomon Peachy
0fc352da0f utils: Fix a small pile of warnings
Change-Id: Idf95fc0a6ce94ebb2282bc3b017bc7ba8aeb42fc
2026-06-17 10:39:57 -04:00
Solomon Peachy
3403e3cfb9 imxtools: Fix several build warnings
Change-Id: Idebf0445d3e861ff27e152730c5bed64c2e4489b
2026-06-17 10:39:57 -04:00
Solomon Peachy
db0d7649e0 ipodpatcher: Fix build warning and 'make clean'
Change-Id: I9e546b0e4e0bcc30efccfca334281398e358ae8d
2026-06-17 10:39:57 -04:00
William Wilgus
d737cbb931 Sansa As3525 OS stacks debug menu change scroll buttons
the other items that scroll use the menu button and reset on STD_OK

OS stacks use STD_OK to scroll and any other button to reset

Change-Id: I1fa1caa322fe761c6f92d2d08cc418e78843863b
2026-06-17 10:26:22 -04:00
Le Khanh Binh
d00a53a1f0 iap: Fix dead remote at boot & ghost clicks on held buttons
Fix FS#13832
If the remote is already plugged in when Rockbox boots, it stays dead
until you replug it. These remotes only send their identify packet
once at power-up, so we never see it and then throw away all button
events because lingo 0x02 was never negotiated. The OF doesn't care,
so accept ContextButtonStatus from unidentified devices too. Stray
bytes received before iap_setup() also made iap_getc() return false,
which the serial driver takes as "sync found" and locks autobaud onto
the wrong bitrate.

The ghost clicks come from the repeatbtn handshake. A held button
resends its down event every 30-100ms and each one re-armed
iap_repeatbtn, which stalls handling of the following packet. So
during a long press packets pile up, the event queue overflows, and
the leftovers replay as keypresses after you let go. Skipping fires
on button release which is why next/prev showed it the worst. Now
repeatbtn is only re-armed when the button state actually changes,
and iap_handlepkt() drains whatever complete packets are in the RX
buffer rather than relying on one queued event per packet.

While at it, fix two more things found along the way: the button
state is now written in one go (the temporary BUTTON_NONE could be
picked up by the button tick mid-update), and iap_rxlen is
decremented when a frame is received so the overflow check actually
does something.

Tested on ipodmini2g with an A1018 remote.

Change-Id: Ie18512e47d642fe6957fc010eaf79b6d2af4c070
2026-06-16 21:36:02 +07:00
William Wilgus
c3ad489738 [BugFix] Sandisk ClipZip Display Type 0 has no partial X updates
Type 0 displays had to update the whole x line due to anything other
than a full line causing corruption and tearing

I figured out that flipping x and x_end
(LCD_W - x and LCD_W - x_end)
makes it work properly

Lowered the refresh rate to 95 Hz
Removed Fade in on screen enable

Change-Id: I0b8f76ad01ce7e48bd0a56aa321c30c30f91ce8d
2026-06-16 00:38:43 -04:00
William Wilgus
32b8af9840 [BugFix] ClipZip Type1 Display init gamma correction
Now that we have a datasheet for the type 1 display controller
it turns out the gamma correction was not being applied
the screen looks much better with it actually applied

also lowers display refresh from 120 HZ to 90 Hz and applied a mentioned
sleep mode (0x14) to save some power

Adds comments for the LCD commands ala type 0

Change-Id: I2d72df4d24b8bf9f3627bdb96ec9ce43ddd8b10a
2026-06-15 00:12:26 -04:00
Adam N. Burke
383e227671 Sansa Clip Zip: Implement LCD flip (180 degree rotation)
Enable HAVE_LCD_FLIP for the Clip Zip and implement lcd_set_flip()
in the LCD driver, making the Display -> Flip Display setting work.
This lets the player be used upside down, e.g. clipped to clothing
with the control buttons pointing up and screen on the bottom.

Defining HAVE_LCD_FLIP also activates the existing button remap in
button_flip() (firmware/drivers/button.c) for this target: while the
display is flipped, LEFT/RIGHT, UP/DOWN and the volume keys are all
swapped to match the new orientation, so the whole device is usable
upside down, not just readable.

The flip is done in hardware by reversing the controller's GRAM write
direction and mirroring the write window in lcd_setup_rect, so partial
updates keep working and there is no per-frame cost. Both panel
variants are handled: the type 0 WiseChip/SEPS114A via MEMORY_WRITE/READ
(1Dh, 0x02), and the type 1 Visionox/LD7134 via the Graphic RAM Writing
Direction register (05h, 0x03). The direction register is written in
lcd_enable(), so it is set while the panel is powered and is re-applied
after display standby; lcd_set_flip() cycles the panel off and on so a
change to the setting takes effect immediately.

For the simulator, which has no real LCD controller, lcd_set_flip() is
implemented in the SDL LCD driver (lcd-bitmap.c) as a software mirror of
the framebuffer, so the flip is visible in theme previews; the generic
uisimulator stub is guarded out when HAVE_LCD_FLIP is defined.

Tested on real type 1 / LD7134 hardware in both orientations: display
content, button remapping and album art are all correct, and test_fps
shows partial updates run at full speed when flipped (1/4 frame 325 fps,
matching the non-flipped rate). The type 0 / SEPS114A path uses the same
approach; the 0x02 direction value was confirmed to flip a type 0 panel
by William Wilgus during review.

Change-Id: I99ef13949102b344826e72d1d90c71e2271448a6
2026-06-14 23:16:17 -04:00
William Wilgus
58ce77fbe2 [BugFix] tagtree voiced Letter menus with talkmenu off
Change-Id: I671f795061a63bcf5db3c94728e98dd7506329a7
2026-06-14 16:50:54 -04:00
William Wilgus
f07e977d7c Sansa ClipZip add Display type to debug update comment on LCD controller
display display type 0 / 1 in debug menu

update the comment on type 1 lcd I believe it to be a LDT LD7134 controller
the commands match up down to the gamma correction tables

Change-Id: Ic5d1d8db994a022a61db4a83a9f476cfafbcf51b
2026-06-13 12:56:55 -04:00
William Wilgus
4d773a3329 onplay wps context menu plugin item rework namebuf
only load the namebuf once unless user changes the plugin
also displays the plugin name when user selects the whole context menu

Change-Id: I32b53729a3dcc2bf2c42393876407df7f3d38d8c
2026-06-11 09:52:09 -04:00
Solomon Peachy
f1bdf1e3c2 fix yellow from 59a42fbf61
Change-Id: Id696c20639cdcc987c228c9faec5a1ff8744797d
2026-06-10 11:28:04 -04:00
Solomon Peachy
59a42fbf61 pcm: Pull pcm_is_ready back out of the sink structure
It is referenced by multiple threads, and as such needs to be both
volatile and SHAREDBSS to keep everyone happy.

...should address hangs on startup observed on nano2g and mini2g when
voiced menus are enabled

Regression introduced in dfa33c2 and made far worse by 759ef27

Change-Id: I202ec6c0d5825ff3a319b7d95d600b4ce06dd685
2026-06-10 09:21:21 -04:00
William Wilgus
0a1858b9d1 [BugFix] prevent infinite loop to return to wps from plugins
if there is nothing to resume then it will return to the plugin endlessly
hanging the device

Change-Id: I7d6a0c7ec5a9e049cf62f88542bedaa1081556ac
2026-06-10 01:26:51 -04:00
William Wilgus
fee00f1f3c [BugFix] pcm-s5l8700 ipod nano 2g audio init hang
pcm_dma_set_freq expects the frequency index not the actual frequency

bug introduced in Commit dfa33c2 pcm: introduce pcm_sink

Change-Id: Idc521cfe1da22b112a16f81611dac720837eeea9
2026-06-10 00:47:56 -04:00
Roman Artiukhin
c5c39a3fdb pcm_mixer: fix auto frequency switch stopping playback on some targets
Regression from cb04b816. Restores sound by re‑adding
pcm_play_stop, previously invoked in mixer_reset.

Known affected targets: x1600 hosted hiby port (Hiby R1, Hiby R3 Pro II)
Discussion: https://forums.rockbox.org/index.php/topic,55125.msg258435.html#msg258435

Change-Id: I5fadac0b47f609e38baad5c7151354ee8f7e9871
2026-06-09 12:51:53 +03:00
William Wilgus
513365713a [FixRed] sonybootloader has a glyphcache but no open_pathfmt
Change-Id: Iaf8522d4a72f78da26434b60757fe3421a3622f2
2026-06-09 02:01:29 -04:00
William Wilgus
a81d3fa10e [Bugfix] open_plugins.rock add 'add' item regardless & voice improvements
also fixes a bug where synclist viewport could be empty if the list isn't
initialized

voices path and parameters now

adds the item [Add] as the last item in the list

Change-Id: I1aad62baf3c19a67d04fa1fb3db8a7573e0a467f
2026-06-09 00:39:31 -04:00
William Wilgus
dfe965d81e font.c glyph_cache_load() reduce stack
open the glyph cache in a separate function so we can
get the MAX_PATH alloc off the stack quickly and
deal with the fd instead

Change-Id: I0e991a1286b29c781e3f03b6a49e100c70809920
2026-06-08 22:31:20 -04:00
William Wilgus
e5c7f0c41c open_plugins.rock add title to main menu, add scroll stop on close
Have a report of a hanging scrolling item, ensure the lists are stopped
on exit with gui_synclist_scroll_stop()

Change-Id: If670806f710118c79377bf8c5de6c1a5168e37fc
2026-06-08 12:03:05 -04:00
Aidan MacDonald
722e4f10ad Cleanup some unnecessary HAVE_HOTSWAP uses
Always define storage_removable() and storage_present() so
that ifdefs are unnecessary. They were already defined as
constant for the CONFIG_STORAGE_MULTI case, but not in the
case of a single storage type.

Change-Id: I13073b3a72b201b5b11167deb050e6f27139c61c
2026-06-08 10:32:49 -04:00
William Wilgus
9b0516e4e1 [BugFix] openplugins.rock 0 is a valid file descriptor
Change-Id: Id7d9c2c4b9d13433c8aa2260b20f5d74e4b3add8
2026-06-07 11:19:08 -04:00
Christian Soffke
1add6b0dd5 shortcuts: eliminate unnecessary nesting
Reduces GNU Complexity scores for:

* shortcut_menu_speak_item: 66 -> 10
* do_shortcut_menu: 39 -> 20
* readline_cb: 29 -> 16

Change-Id: Ic648a7eb1e51d4a116bc8af61f1ed1c617cee024
2026-06-06 19:18:17 -04:00
Christian Soffke
86decaab9e root_menu: Start Screen: don't try to resume finished playlist
Go to root menu when Start Screen has been set to "Resume Playback"
but playlist is finished

https://forums.rockbox.org/index.php?topic=55770

Change-Id: I6939fa313dd5fd6485628e22a2d860763492d5cf
2026-06-06 11:34:18 -04:00
Christian Soffke
292e8a17a2 keymap: erosq: fix keylock button handling
Only react to Power button release if previous
button code was Power button press, so that
screen doesn't lock when device may have just
been turned on

Change-Id: I1ba228103efedeeceaaa00c49b1b1da66b63bb75
2026-06-06 17:23:58 +02:00
Christian Soffke
f123dbc04a misc: shutdown: fix backdrop glitches
Clearing the display makes the backdrop come to the foreground.
which can look odd or glitchy, particularly for themes that do
custom drawing on the backdrop buffer (2c71aa9). It also causes
issues if the shutdown has to be canceled.

Instead, enable theme, then clear the UI vp.

Change-Id: Ia96d1e766a9b86ec133522f7cd259e8b88f64216
2026-06-05 20:20:06 -04:00
William Wilgus
2b96380641 [Feature] FS#13884 #2 allow merging imported native keymaps
allows you to import a file and merge native keymaps

pops a yes no prompt to erase existing

duplicates will be overwritten

Change-Id: I167c6fac65775754b2a9874185d14f65638db9d7
2026-06-05 12:08:53 -04:00
William Wilgus
7517674513 FS#13920 text_editor.c plugin do not terminate last line with \n
you can still add a \n by inserting a blank line

Change-Id: Ic3e69fce83ccc9c050857a03877545a7452ce8a2
2026-06-05 02:17:38 -04:00
Christian Soffke
74905f4796 skin_engine: settings_apply_skins: remove get_skin_filename
Has no effect anymore since commit d66592b

Change-Id: Ibefc834378518c7e73e9e9b2489b6c072499bbe8
2026-06-05 00:04:17 +02:00
Christian Soffke
0836ebbd45 shortcuts: fix 'File' shortcuts may fail when dir filter set
Only apply dir filter to 'Browse' shortcuts, so that,
when trying to run a file from Shortcuts that is hidden
due to current dir filter settings, you don't get a 'Failed
reading Unknown' message (LANG_READ_FAILED/LANG_UNKNOWN)
because the tree entry can't be found in ft_enter.

Change-Id: I4eaad2ec415c9bac352a409922848e4407dac993
2026-06-04 21:32:54 +02:00
William Wilgus
ad05e23b72 [Feature] FS#13884 allow merging imported text keymaps
allows you to import a file and merge text keymaps

pops a yes no prompt to erase existing

duplicates will be overwritten

Change-Id: I0f4425e765f0a2ff6b73b830bcaea1b3f31e83cb
2026-06-04 12:10:03 -04:00
William Wilgus
e80e1448f1 [bugfix] Remember position in plugin browser menu
make the struct static so we can keep using the same
browse context between invocations

Change-Id: Ia154a78935755e1decb6abe50291d49e4404fb95
2026-06-04 02:33:44 -04:00
Solomon Peachy
3152beee32 chore: Don't embed $Revision$ tags in auto-generated files
I was going to convert them to a git hash instead, but that would
break builds from tarballs.

Change-Id: I76213b8b65df2c6cfb73cba299a4975a22725f36
2026-06-03 08:31:05 -04:00
Christian Soffke
a39e4f2a06 skin_engine: get rid of skin_unload_all
The skin is not unloaded using skin_unload_all in
settings_apply_skins anymore since commit 0ca4b38.

usb_screen was last remaining user until commit a969e1f.

Change-Id: I65a41ed220165587a04e699a7f210c575c00a4eb
2026-06-02 19:49:13 +02:00
Vencislav Atanasov
4469b95ef2 Update the Bulgarian translation
Change-Id: I285c5d71054b8c245ad40bd7c7a6d76e9b45fd01
2026-06-02 01:07:00 +03:00
Solomon Peachy
addcc159c2 tools: Update mp3info perl module to final upstream version
1.20 -> 1.26

  https://github.com/dsully/perl-mp3-info/commits/master/Info.pm

Change-Id: I0d58f56265a463784f45673764b9fdc054887c2a
2026-06-01 16:08:00 -04:00
Solomon Peachy
d54b9e6f8d chore: Get rid of *all* vestigal CVS '$Id:$' tags
Change-Id: I35c13a9768c582e4851aa252dd3ea5c89f760c8c
2026-06-01 16:01:18 -04:00
William Wilgus
3b2555bd4d onplay wps context menus small cleanup
no functional changes just cleaning up some code / logic

Change-Id: Ic03918a70997cfb170a29175361e2df9a9d242d1
2026-06-01 10:47:07 -04:00
Roman Artiukhin
c052d11673 skin: touchscreen: fix rewind in long files
Fix a possible overflow in the elapsed time calculation.

Change-Id: I211777d8144f76889003239b9a49e4fc56184c8f
2026-06-01 04:26:06 -04:00
William Wilgus
a7754eee71 [Bugfix] FS#13912 - splash_scroller with cyrillic crashes
I think they mean corrupted not crashes as I couldn't repro that

splash_scroller stepped by individual chars and split multibyte
sequences leaving corrupted chars

now it uses the new font_measurestring() to get the max_w and chops
it at break chars instead

this required a bit of a logic change to the function but should be
as good with less complications

Change-Id: I692db8b4737f41aec08dbc122fb844028498326d
2026-05-31 19:05:51 -04:00
Solomon Peachy
1c84362f3e FS#13915 - Updated Italian Translation (Alessio Lenzi)
Change-Id: Icc52476aa680361ee912468d9e47d67ac8324bad
2026-05-31 13:03:49 -04:00
Christian Soffke
16900c7fee root_menu: fix skin glitch when rebuilding tagcache
Only clear the UI vp instead of the whole display

Change-Id: Iab39094184a6749df743af268a4d9923cb18a73a
2026-05-31 11:50:11 -04:00
Roman Artiukhin
892fbe8d8f action: touchscreen: fix stuck repeated state of last action
This fixes the repeat_mode being stuck on Repeat Shuffle on the Hiby R1 WPS, and quick settings values being stuck at the last values for touch actions.

Regression from 9e254aca. The repeated state is used by the quick screen to detect repeated actions (see b918ec5) so I also removed "historical baggage" note.

Change-Id: Ic2a97058bbd17d232954ffe37f31a480ee11fe54
2026-05-31 13:20:39 +03:00
Solomon Peachy
d72a93836c nwztools: Update database generator script to work with python3
Change-Id: I662de90b57a3836755b88ff51537eb1597f226f4
2026-05-29 23:36:45 -04:00