Rafaël Carré
84b7747069
as3525v1: detect correctly internal storage capacity
...
check if SD transfers fit with the card capacity
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26029 a1c6a512-1295-4272-9138-f99709370657
2010-05-14 21:41:29 +00:00
Rafaël Carré
e72d2daad8
as3525v2: check if SD transfers fit with the card capacity
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26028 a1c6a512-1295-4272-9138-f99709370657
2010-05-14 19:37:10 +00:00
Rafaël Carré
685209d907
as3525: add some comments in the microphone channel copy loop
...
Indent the asm constraints at the same level than instructions
Also add a trick to reduce the number of instructions outputted by gcc
in the commented C version of the loop
The difference between C and asm is now 1 instruction
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26027 a1c6a512-1295-4272-9138-f99709370657
2010-05-14 16:47:58 +00:00
Rafaël Carré
ac43fd367a
as3525v1: duplicate the right channel into the left channel when recording microphone
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26023 a1c6a512-1295-4272-9138-f99709370657
2010-05-14 12:59:54 +00:00
Rafaël Carré
39e4b84e64
as3525: change SDRAM settings only in models for which there is a bootloader
...
c200v2 & m200v4 have no binary bootloader released yet
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26009 a1c6a512-1295-4272-9138-f99709370657
2010-05-14 08:35:49 +00:00
Rafaël Carré
90963dcc0b
as3525: retain & release DMA engine when starting and stopping recording
...
This fixes the error introduced in r25989, where it would release the
DMA engine when uninitializing recording.
The real bug has been fixed instead (in pitch_detector)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26003 a1c6a512-1295-4272-9138-f99709370657
2010-05-13 21:32:10 +00:00
Tobias Diedrich
990179e1aa
Correct register defines. I had to look at the disassembly to spot this bug. orz
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25996 a1c6a512-1295-4272-9138-f99709370657
2010-05-13 14:07:59 +00:00
Rafaël Carré
cd8ed00dfe
as3525: use the correct uncached address for rec peak buffer
...
also avoid disabling completely the DMA engine in pitch_detector
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25989 a1c6a512-1295-4272-9138-f99709370657
2010-05-13 08:21:04 +00:00
Rafaël Carré
bc0434d63a
as3525: use a table for mclk dividers, get rid of a division
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25981 a1c6a512-1295-4272-9138-f99709370657
2010-05-13 05:58:52 +00:00
Rafaël Carré
d556f26820
as3525: use DMA for recording
...
Flyspray: FS#11257
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25980 a1c6a512-1295-4272-9138-f99709370657
2010-05-13 05:26:12 +00:00
Michael Sevakis
59063c6e49
Missed a yellow on Cowon D2. :)
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25972 a1c6a512-1295-4272-9138-f99709370657
2010-05-12 14:35:47 +00:00
Michael Sevakis
cc7457e788
Fix r25970 red and yellow *and* a bug uncovered for pp5002 where pcm_play_dma_start wasn't actually initializing the dma_play_data with the first buffer info (must've happened during pp502x DMA conversion).
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25971 a1c6a512-1295-4272-9138-f99709370657
2010-05-12 14:31:12 +00:00
Michael Sevakis
4d04132c76
PCM bottom layer simplification. pcm_rec_peak_addr variable no longer has to be handled there. Driver can just return current pointer for recording peaks. A new define, HAVE_PCM_REC_DMA_ADDRESS, specifies that physical addresses are being used for recording and translation is needed before starting a new block. The drivers need not worry about aligning start and size nor should care if either will be zero. All this will be checked in the logical layer first.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25970 a1c6a512-1295-4272-9138-f99709370657
2010-05-12 14:05:36 +00:00
Nils Wallménius
aa1e471f9a
Coldfire strlen, slight optimization pointed out by amiconn, eliminate some unconditionla branches by rearranging the code handling the head bytes
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25968 a1c6a512-1295-4272-9138-f99709370657
2010-05-12 12:32:34 +00:00
Nils Wallménius
418c9eeb14
Faster assembler strlen for coldfire using the load-a-whole-word-and-test-i-for-nullbytes-at-one trick, benched 28% faster than the old version
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25959 a1c6a512-1295-4272-9138-f99709370657
2010-05-11 22:23:43 +00:00
Michael Sevakis
8261051b37
Gigabeat F/X: Let us clear up confusion about just what the core frequency is. Fix frequency display in buffering screen.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25953 a1c6a512-1295-4272-9138-f99709370657
2010-05-11 14:09:26 +00:00
Marcin Bukat
68da06f3dc
HD200 - fix in asm optimised ATA reads&writes
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25948 a1c6a512-1295-4272-9138-f99709370657
2010-05-11 11:35:58 +00:00
Andree Buschmann
7d21e5ab32
No need to use alternating registers for dual register read/write sequence. Correct comment.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25939 a1c6a512-1295-4272-9138-f99709370657
2010-05-10 20:35:57 +00:00
Andree Buschmann
18b5488a4a
Minor speed up (+3%) of iPod Video screen updates.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25938 a1c6a512-1295-4272-9138-f99709370657
2010-05-10 19:12:03 +00:00
Jack Halpin
ed704825d2
sd-as3525v2: Set LP bits in MCI_CLKENA for cards after they have been initialized.
...
The OF does this and while we don't have the documentation to be sure I think it's highly likely this is a low power mode referred to in one of the product "briefs".
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25936 a1c6a512-1295-4272-9138-f99709370657
2010-05-10 17:35:00 +00:00
Jack Halpin
56457934c6
sd-as3525v2: Add delay after SD_SWITCH_FUNC to while switching to high speed timings and wait until after this switch to bring the card clock back up to full speed.
...
This seems to make switching the uSD card to high speed timing much more reliable.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25935 a1c6a512-1295-4272-9138-f99709370657
2010-05-10 17:34:54 +00:00
Tobias Diedrich
badf2c31f7
See 0x429c in OF (lcd_init), B6 is lcd reset line.
...
Hopefully setting this properly to output will cure the random lcd resets.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25933 a1c6a512-1295-4272-9138-f99709370657
2010-05-10 16:11:01 +00:00
Marcin Bukat
fc330110c9
HD200 - Disable asm optimised reads as it showed to be broken. Enable asm optimised writes. test_disk was failing because of broken read routine.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25931 a1c6a512-1295-4272-9138-f99709370657
2010-05-10 13:24:44 +00:00
Marcin Bukat
4fad74e6f6
HD200 - Remove checks if driver is initialized. lcd_init_device() is always called first.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25928 a1c6a512-1295-4272-9138-f99709370657
2010-05-10 12:36:58 +00:00
Marcin Bukat
45c2a6d314
HD200 - Reduce wait states when writing to lcd.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25927 a1c6a512-1295-4272-9138-f99709370657
2010-05-10 12:36:27 +00:00
Rafaël Carré
4970f98619
as3525v2: disable adjustable CPU frequency
...
When the rest of the code is confirmed to work properly without CPU
frequency changes, it will be possible to reliabily test set_cpu_frequency()
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25924 a1c6a512-1295-4272-9138-f99709370657
2010-05-10 03:49:17 +00:00
Rafaël Carré
a1b26db98f
Sansa Cliv2: calibrated discharge curve
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25901 a1c6a512-1295-4272-9138-f99709370657
2010-05-08 14:53:41 +00:00
Rafaël Carré
b269b7854f
as3525*: stop MPMCCLKOUT when all SDRAMs are idle
...
Get a bit more battery life (between 30 minutes and 2 hours)
as3525v2: only enabled in bootloader, we need a new binary release anwyway
as3525v1: enabled in rockbox.sansa as well, so we can continue using the
current bootloaders
Flyspray: FS#11246
Author: myself
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25900 a1c6a512-1295-4272-9138-f99709370657
2010-05-08 13:59:01 +00:00
Michael Sevakis
43d2c7ad19
Clean the DCache just before going to main because areas were written by init code that need to be coherent (.ncbss and .sdmacode).
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25896 a1c6a512-1295-4272-9138-f99709370657
2010-05-08 08:32:09 +00:00
Michael Sevakis
a420561bf8
Gigabeat S: Reclaim about 800K of memory that was laying unused. Get rid of DEVBSS_ATTR for this target and implement as NOCACHEBSS_ATTR. Plugin and codec buffers move so all that is now incompatible (do full update). No version increase for plugins/codecs because the loader will reject them.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25895 a1c6a512-1295-4272-9138-f99709370657
2010-05-08 07:45:34 +00:00
Rafaël Carré
3487b85d89
Fuzev1: calibrated discharge curve
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25874 a1c6a512-1295-4272-9138-f99709370657
2010-05-07 14:33:45 +00:00
Michael Sevakis
d7ef247412
i.MX31/Gigabeat S minor cleaning: Make HW access more obvious in places I forgot to do earlier. Reduce the number of structs that need to be filled-out for some drivers just to simplify a little. Change some types.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25870 a1c6a512-1295-4272-9138-f99709370657
2010-05-07 10:53:19 +00:00
Rafaël Carré
235fc05e3b
Fuzev2: calibrated discharge curve
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25869 a1c6a512-1295-4272-9138-f99709370657
2010-05-07 07:46:07 +00:00
Michael Sevakis
affea5fe9e
i.MX31: Make some style changes to some driver code so that hardware vs. variable access is more obvious to the eye. Change a few data types and qualifiers. No functional differences.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25865 a1c6a512-1295-4272-9138-f99709370657
2010-05-07 02:29:18 +00:00
Jeffrey Goode
13b8e3d66d
Remove last traces of sprintf.h
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25864 a1c6a512-1295-4272-9138-f99709370657
2010-05-07 02:13:47 +00:00
Thomas Martitz
d67bf4c858
Fix last sprintf warning.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25859 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 22:54:40 +00:00
Thomas Martitz
55e4fe73cc
Fix the remaining reds.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25858 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 22:33:57 +00:00
Frank Gevaerts
ab4a162763
Fix gigabeat S includes so it builds again
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25855 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 22:13:54 +00:00
Thomas Martitz
77dfff5a55
Fix some more snprintf related warnings.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25853 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 21:37:03 +00:00
Thomas Martitz
50a6ca39ad
Move c/h files implementing/defining standard library stuff into a new libc directory, also standard'ify some parts of the code base (almost entirely #include fixes).
...
This is to a) to cleanup firmware/common and firmware/include a bit, but also b) for Rockbox as an application which should use the host system's c library and headers, separating makes it easy to exclude our files from the build.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25850 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 21:04:40 +00:00
Maurus Cuelenaere
adb506df14
Ingenic Jz4740: Use lcd_putsf() instead of lcd_puts() in exception handler
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25849 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 19:28:12 +00:00
Jack Halpin
db8d07589f
ad-as3525v2: Ask for a reponse from SD_APP_CMD to help with timing issues when switching to 4 bit widebus.
...
Some SD cards were having problems switching to 4 Bit widebus and this solution appears to remedy that.
Thanks to Luca_S!
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25846 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 18:53:41 +00:00
Thomas Martitz
0a1d7c28b7
Make open() posix compliant api-wise. A few calls (those with O_CREAT) need the additional optional mode parameter so add it. Impact for the core is almost zero, as open() is a wrapper macro for the real open function which doesn't take the variable parameter.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25844 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 17:35:13 +00:00
Marcin Bukat
684c70bac5
HD200 - fix stupid bug in lcd_grey_data
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25842 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 14:33:19 +00:00
Michael Sevakis
0defb8483c
Gigabeat S bootloader: Fix archaic call placement in dptc_stop which hangs the bootloader before jumping to FW. Let the backlight LED ramp up after unplugging USB which just looks better.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25840 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 04:45:05 +00:00
Michael Sevakis
992b7e10b8
Gigabeat S: There's no compelling reason to start automatic scaling in the bootloader only stop it milliseconds later. Do init to default frequency and working point, however.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25839 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 04:17:34 +00:00
Michael Sevakis
021f9e9e56
Changed a macro to a raw in int constant. Didn't mean to do that. Put it back right.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25838 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 03:30:59 +00:00
Michael Sevakis
a36a498c57
i.MX31/Gigabeat S: This should fix stability problems. One problem was to start using the DVFS controller properly so that interrupts will be masked at the lowest and highest frequency indexes. Millions of useless interrupts were occurring at 132MHz because its index was 2, not 3, which masks it automatically when it can't go slower. Stopping the flood was enough to actually see the difference in general. IRQ must be disabled when fiddling with the CCM registers and only enabled when waiting for voltage ramp as having them enables also causes spurious DVFS ints. Implement interruptible ISR pro/epilogue more safely (always using IRQ stack even in SVC mode handling). Fix an improper inequality in DVFS code (which set regs for down when going up and v.v.). Misc. support changes. Have internal tables take less RAM.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25837 a1c6a512-1295-4272-9138-f99709370657
2010-05-06 03:23:51 +00:00
Jack Halpin
8fd3ec9727
sd-as3525v2.c: Set MCI interrupt mask immediately prior to enabling DMA for the transfer.
...
These INT's shouldn't be unmasked until the transfer is just about to happen.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25836 a1c6a512-1295-4272-9138-f99709370657
2010-05-05 20:04:16 +00:00
Michael Sevakis
630b4fc555
i.MX31/Gigabeat S: The nested IRQ code was just totally wrong and not actually working anyway (which is why it wasn't crashing). AVIC doesn't seem truthful about priority of current ISR either :\. Sometimes there were channel swaps during really active DVFS due to FIFO underflow from a needed long delay in the ISR (100us, and IIS TX only has 45us reserve) and DMARQ *must* be serviced low-latency. Get it doing as was intended.
...
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25822 a1c6a512-1295-4272-9138-f99709370657
2010-05-05 07:15:20 +00:00