summaryrefslogtreecommitdiffstats
path: root/firmware/target/hosted
AgeCommit message (Collapse)AuthorFilesLines
2020-10-31fix red introduced in the android pcm driver (rev fe2d52c)Solomon Peachy1-1/+1
Change-Id: I2fa160fd39842a5434cf11573b50061786e610ca
2020-10-31pcm: Get rid of pcm_play_pause() and associated APIsSolomon Peachy5-79/+9
Nothing in the core has used it for some time. It's exported to the plugin API but the last plugins to use it were switched to the mixer API back in 2011. This allows us to get rid of pcm_play_dma_pause() from all audio drivers Change-Id: Ic3fa02592316f84963e41d792d1cabb436d1ff6b
2020-10-26LCD core move buf ptr and address look up function viewport structWilliam Wilgus2-3/+3
I'm currently running up against the limitations of the lcd_draw functions I want these functions to be able to be used on any size buffer not just buffers with a stride matching the underlying device [DONE] allow the framebuffer to be decoupled from the device framebuffer [DONE need examples] allow for some simple blit like transformations [DONE] remove the device framebuffer from the plugin api [DONE}ditto remote framebuffer [DONE] remove _viewport_get_framebuffer you can call struct *vp = lcd_set_viewport(NULL) and vp->buffer->fb_ptr while remote lcds may compile (and work in the sim) its not been tested on targets [FIXED] backdrops need work to be screen agnostic [FIXED] screen statusbar is not being combined into the main viewport correctly yet [FIXED] screen elements are displayed incorrectly after switch to void* [FIXED] core didn't restore proper viewport on splash etc. [NEEDS TESTING] remote lcd garbled data [FIXED] osd lib garbled screen on bmp_part [FIXED] grey_set_vp needs to return old viewport like lcd_set_viewport [FIXED] Viewport update now handles viewports with differing buffers/strides by copying to the main buffer [FIXED] splash on top of WPS leaves old framebuffer data (doesn't redraw) [UPDATE] refined this a bit more to have clear_viewport set the clean bit and have skin_render do its own screen clear scrolling viewports no longer trigger wps refresh also fixed a bug where guisyncyesno was displaying and then disappearing [ADDED!] New LCD macros that allow you to create properly size frame buffers in you desired size without wasting bytes (LCD_ and LCD_REMOTE_) LCD_STRIDE(w, h) same as STRIDE_MAIN LCD_FBSTRIDE(w, h) returns target specific stride for a buffer W x H LCD_NBELEMS(w, h) returns the number of fb_data sized elemenst needed for a buffer W x H LCD_NATIVE_STRIDE(s) conversion between rockbox native vertical and lcd native stride (2bitH) test_viewports.c has an example of usage [FIXED!!] 2bit targets don't respect non-native strides [FIXED] Few define snags Change-Id: I0d04c3834e464eca84a5a715743a297a0cefd0af
2020-10-25pcm-alsa: fix red.Solomon Peachy1-1/+1
Change-Id: Id8d5442b0b3eb4ce3c20d1c9d24f07b5378cc22f
2020-10-25hosted: alsa: Fix two bugs when recordingSolomon Peachy1-4/+6
Change-Id: Ib97857874676ea4aa8f04d44e048de8465a4da4f
2020-10-23ALSA: Further rework:Solomon Peachy2-192/+370
* Get rid of non-async (ie tick task) mode due to inherent brokenness * Get rid of nonblock mode; we never write if buffers aren't sufficient * Move driver init into pcm_open() instead of pcm_init() * Much better underrun handling * Better error handling in some situations * Add in recording functionality * Use smaller audio buffers to avoid glitching * Don't start audio buffer with silence * Allow device name to be overridden by target Recording portions based on work done by Lorenzo Miori in g#633 Change-Id: I0197bdc1749c28109eb79def1e6a3e1d62d8cef3
2020-10-23Hosted targets Fix timer cycle calculation overflowWilliam Wilgus1-1/+1
at 1 GHZ the intermediate calculation for cycles overflows 32 bits this makes timer fail even with sensible values solution divide both sides by 100 Change-Id: I18a4054c2d06fb72531d5496bba562f71b03984f
2020-10-21hosted: Allow ALSA driver to switch output device at runtimeSolomon Peachy1-19/+28
* Allow output device name to be specified * Set hw/swparams prior to actual playback start, not at init * If told to open a new device, cleanly close down old one. Change-Id: Ib97310ec23588136c031466ee9c22312ab0f9f5a
2020-10-21Add UI Simulator for Eros Q / K seriesSolomon Peachy1-0/+7
Change-Id: I9ffc101bd904b3f0e2d6a86a43fb1ae3fda73a19
2020-10-18nwzstools: add NW-A820 nvp nodesAmaury Pouly1-1/+131
Change-Id: Iab79eb0c9b0bbf8fb7622f5630f385d56878507a
2020-10-18sonynwz: Properly support multidrive, with hotswap of the SD cardSolomon Peachy1-8/+66
Change-Id: I7eb8efb0986a395d5ffbcc06a54bb680e0b59e9d
2020-10-17hosted: Drop a bootloader version string in /etc, and report it in debug menuSolomon Peachy1-0/+21
Change-Id: I4d72d7800dbff56619898b6bc9d0f81a6c561598
2020-10-17hosted: Fix USB mounting code to work with HAVE_MULTIDRIVE enabledSolomon Peachy3-9/+50
Change-Id: I48944c28903db117d3d883a5e777cafe5d055600
2020-10-17hosted: Support hot-swappable internal and external storageSolomon Peachy2-8/+39
Change-Id: I321e9da4d5087dbd91194e6faa35cd4a685a0495
2020-10-17Define a USB storage type, and hook it up for hosted targetsSolomon Peachy2-2/+9
Change-Id: I56363c989139c7edf0b2c67b0aac9ef1adfacba2
2020-10-17hosted: ROLO: Fixes for PIVOT_ROOT targetsSolomon Peachy1-3/+20
Change-Id: I4888bd5db6f8a419d312c6b017f676ba6c749d89
2020-10-17hosted: Fix HAVE_MULTIDRIVE to work properly with PIVOT_ROOTSolomon Peachy1-4/+12
Change-Id: Ibc97de5c345e88c19ad8ba8c05fefebbada08790
2020-10-17samsung yp-r0/r1: use os-native opendir() in the low-level driver codeSolomon Peachy2-7/+7
Fixes blank LCD on both R0/R1 and the PMU on the R1 Change-Id: I356907676f7a0a009897fd4895bf78c1022b71d1
2020-10-17sonynwz: use os-native opendir() in the low-level input driver codeSolomon Peachy1-9/+11
instead of the rockbox opendir() wrapper. Change-Id: I06e8c2d7997c7cc3d507f06659d46cdfd6a02ce3
2020-10-16hosted: open input device as read-only.Solomon Peachy5-15/+14
Change-Id: I4dcd98f45f41fe06a0a75a2a0dd45c753c2cf365
2020-10-15m3k: Fixes for the M3K.Solomon Peachy1-0/+6
* Cannot turn off the LCD directly (have to rely on backlight) * Only insmod/rmmod the usb gadget modules if state changes Change-Id: I9ea90177d496cd035ada93e04a93a7c6f2e84706
2020-10-15hosted: Unify the USB code for the hiby-based players.Solomon Peachy3-239/+3
* Specify exported USB VID/PID in target config header * Don't fail if the sd filesystem has already been remounted (ie due to platform hotplug) Change-Id: Ifd2dae0c4f15086bf2bf89eb093018b3c4d2b75d
2020-10-14erosq: Add battery discharge curve and initial runtime estimation.Solomon Peachy1-2/+3
(playing mp3 with headphones inserted lasted just over 13 hours) Change-Id: Id610f911811eafd914db20000ae860c75e0d8a93
2020-10-13xduoox3ii: Update battery curve.Solomon Peachy1-2/+2
Change-Id: I2cc04d696631ba887fa8943d94360f902bf12e85
2020-10-12hosted: More PCM muting workSolomon Peachy1-7/+7
* Track mute state, only call hw if actual change is needed * Don't unmute in audiohw_postinit() * sample rate tracking fixes * erosq: Don't start up muted Change-Id: I004f787a4b7ea73c16b6ec9818ec29a12c89f46b
2020-10-12rolo: hosted: Make display output non-glitchySolomon Peachy1-2/+2
Change-Id: I63d6a28d67fa56d3541aaa121356c8ff2ce10bbe
2020-10-12Hosted PCM: Rework auto-muting code a bitSolomon Peachy1-17/+25
* If AUDIOHW_MUTE_ON_PAUSE, no meaningful change * Unconditionally unmute on playback start * xduoox3ii: Mute on sample rate change * rocker/xduoo: Stay muted after startup This avoids the nasty "pop" on startup, without doing the full mute-on-pause stuff that causes unacceptable dropouts on the X3ii. Change-Id: I2e3ee0bb8094e288f37a0acada86a80016ce5cac
2020-10-11Fix inverted test that made SDL_APP unhappySolomon Peachy1-5/+5
Change-Id: I18a51ddd0fa7fd0afda938c732fadce4cd87c262
2020-10-11Turn on ROLO for M3K tooSolomon Peachy1-1/+1
Change-Id: I7e1b2168a70605c5a138d83fd69e847fd02af4a4
2020-10-11hosted: sanitize handling of HOME_DIRSolomon Peachy2-18/+25
* HOME_DIR is now either "/" or special "<HOME>" * target-specific "home dir path" is defined solely by PIVOT_ROOT * PIVOT_ROOT path is now defined in toplevel config files * Make Samsung YP-R0/R1 and SONY_NWZ use PIVOT_ROOT too * Do not prepend PIVOT_ROOT path if the path already has it! * Do not play these games for __PCTOOL__ builds Change-Id: I3d51ad902a5f9cafe45ba15ba654f30f1ec6113a
2020-10-11New port: AIGO EROS Q / EROS KSolomon Peachy13-4/+630
The Q and K have a slightly different case, but the hardware under the shell is completely identical. These models are rebadged versions: * Hifiwalker H2 (== Q) * AGPTek H3 (== K) * Surfans F20 (== K) Other notes: * Significant improvements in the shared Hiby-platform launcher/loader * SD card can theoretically be hot-swapped now * Support external USB mass storage! * Some consolidation of Hiby-platform targets * Some consolidation of plugin keymaps Todo/known issues: * Keymaps need to be gone over properly * Convert to HAVE_SCROLLWHEEL? Change-Id: I5a8a4f22c38a5b69392ca7c0a8ad8c4e07d9523c
2020-10-11hosted: Add ROLO support for hosted targetsSolomon Peachy1-0/+102
Change-Id: I2d46a63ee8225a9d9d77dd80a06c418af78c260c
2020-10-11nwztools: fix MW-WM1/A30 KAS, fix KAS lengthAmaury Pouly2-3/+6
Split WM1A/WM1Z because they don't have the same KAS. On newer devices, the KAS is actually 64 bytes, not 60. The strange thing is that "get_dnk_nvp kas" returns 60 bytes whereas "get_dnk_prop kas" returns 64, not sure why. Change-Id: I944d3d838209ba58388439af0cdf5d7c74f1f7fc
2020-10-11hosted: Use O_CLOEXEC for all open() and "e" for fopen() callsSolomon Peachy14-31/+27
This way we'll automatically close the files upon exec() Change-Id: Ic0daca8fb56432830de4a2f4a86a77337121ecc7
2020-10-09m3k: Fix red bootloader buildSolomon Peachy1-4/+0
Change-Id: I3a6e9e6222e6219484c6903325c985bff8af39ef
2020-10-09New port: FiiO M3KSolomon Peachy15-6/+1003
Most credit goes to: Roman Skylarov Additional integration and refactoring by myself. *** COMPLETELY UNTESTED *** Change-Id: Ia64c36d92e0214c6b15f7a868df286f8113ea27b
2020-10-09xduoox3ii/x20: Define a sane BUTTON_LEFT/RIGHT aliasSolomon Peachy1-2/+2
Change-Id: If11dfa50aeb8cb8b80de730c494d81a9e87880c4
2020-10-08Don't compile audio codecs into native bootloader builds.Solomon Peachy3-6/+10
Change-Id: I0b2cc143572bf88423bdf7647cee0af567aee684
2020-10-05FS13241: Get rid of the hacky hold switch emulation on the X3ii & X20Solomon Peachy2-36/+0
It doesn't work properly and interferes with the power button in the keymap. Rework WPS keymap a bit to make single-tap power emulate lock. Change-Id: I9d9b9b4adcea3764e6e427f484e051c9bab9d13b
2020-10-03hosted: control buttonlights along with the display backlight.Solomon Peachy1-0/+6
Change-Id: I03385db46e94ca1bb6a4e35c89f630145c9d40e5
2020-10-03alsa: Refactor pcm_dma_apply_settings_nolock()Solomon Peachy1-14/+7
Change-Id: I32190e6987afca99b24197ca7ae2853053062d30
2020-10-03alsa: introduce AUDIOHW_MUTE_ON_PAUSE, and have rocker use it.Solomon Peachy1-7/+11
Change-Id: I1edbb8e71a9c73baaeecb01b66cbee6c3f7b5f8f
2020-10-03alsa: Explicitly mute the output when we stop playing, and unmute after ↵Solomon Peachy1-1/+14
playback starts Allows us to avoid hearing the codec powering on and off. Change-Id: Idaaff437932009952ed248be97eedf54cb4cf28e
2020-10-03alsa: Handle underruns when starting a new streamSolomon Peachy1-47/+69
Unsure why this is happening, but now we detect and recover errors at startup. Also clean up the mismash of printf(), DEBUGF(), etc in favor of panicf() for the really serious stuff and logf() for everything else. Change-Id: I9aaa620d55d556645c9a6d108541b987983b32a8
2020-10-02alsa: Use larger playback buffers for higher bitratesSolomon Peachy1-4/+16
(existing ones apply up to 48KHz, scale up linearly to 192KHz) Change-Id: Iac32d49b8073b63a5d40fd21f41437e6051cb8de
2020-10-02hosted: Don't use O_SYNC for the framebuffer handle.Solomon Peachy1-1/+1
Change-Id: Iff4b1947fe053313d677b894c78250760aaef967
2020-10-02hosted: Fix overzealous spamming of backlight and lcd enableSolomon Peachy2-10/+27
This caused random delays in LCD activity, and also caused key inputs to go nuts Change-Id: Ie483c86f7461455308f8c5f8999df313521c6b55
2020-10-01Fix warnings and errors introduced in b030bf5Solomon Peachy1-0/+1
Change-Id: I23966b6a79c0d2cbab2e01c649c1b991f460d8ad
2020-10-01xduoox3ii/x20: Proper lineout detection and volume mangling.Solomon Peachy3-21/+19
hotplugging hp and lineout works, without blowing out eardrums. Change-Id: I2df5c7a618bb2d1d77d416548d45dff9cfc619db
2020-10-01fix some of the red introduced in e43726dSolomon Peachy1-1/+1
Change-Id: Id1abb0dd11f8a8e79a80fc54e58a5a22706a03ad