| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
| |
This improves the USB performance of ChaosKey so that it doesn't NAK
during data transfers at all.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
This also allows us to stop shadowing USB rx buffers in system ram
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This shouldn't have much of an effect, but shows how double buffering
works.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
It's 8MHz, not 16MHz
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Tested on timer 2, all four channels.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Gcc 5.4.1 tracks alignment of data through assignments, so that a
uint32_t pointer which comes from byte-aligned uint8_t data:
extern uint8_t foo[];
uint32_t *q = (void *) foo;
Fetches and stores through this pointer are done bytewise. This is
slow (meh), but if q references a device register, things to bad very
quickly.
This patch works around this bug in the compiler by adding
__attribute__((aligned(4))) tags to some variables, or changing them
from uint8_t to uint32_t. Places doing this will now be caught as I've
added -Wcast-align to the compiler flags. That required adding (void
*) casts, after the relevant code was checked to make sure the
compiler could tell that the addresses were aligned.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
The STM32F0 usart can be operated much like the STM32L usart, but the
registers are all moved around.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This was used to try and not have two xtals on telemini, but failed
because the provided clock has too much noise.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
Missing a reserved address in the registers broke everything nicely,
but the priority values were also wrong - stm32f0 exposes 8 bits per
priority, like the stm32l, but it uses only the top two bits.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Allows the use of crystals instead of requiring USB.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This also changes the DMA interface a bit so we can select for
interrupts on only the interesting channels.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Sets up the stm32f0 CRC hardware, exposing inline functions to access
it. DMA access is possible, but usbtrng can't use that.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
These were left over from the stm32f0 initial implementation work; now
it's more useful to list only the bits which are valid.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
The ADC api is what USBtrng wants; a way to repeatedly read a single
ADC input as fast as possible.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Also moves the usual address for applications out of the way of the
flash loader.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
Basic clock configuration, OS support, LED and USB drivers.
Signed-off-by: Keith Packard <keithp@keithp.com>
|