V=s is openwrt, V=1 is here.
try and avoid weird problems with missing files like,
make[1]: *** No rule to make target '../../../include/libopencm3/stm32/g4/pwr.h', needed by 'rcc_common_all.o'. Stop.
by turning down the paralellism a bit, it's a quad core arm, but it's
stil a little small machine.
This has failing tests, and doesn't implement (yet) the delay routines,
so it won't even compile without disabling that functionality in the
core gadget0 code. However, it passes most tests, and it demonstrates
that the changes made to the setup handling earlier haven't broken USB
on this platform.
The loopback functionality was never implemented, not for regular bulk
endpoints. By adding it, and adding pairs of endpoints, we can easily
catch buffer management problems. These tests currently fail on
st_usbfs devices.
This did require renumbering the endpoints, as dwc_otg_fs only offers
three endpoints in each direction, and they can't be arbitrary numbers,
unlike on st_usbfs.
See https://github.com/libopencm3/libopencm3/pull/880 and related tickets.
D+ is PA12 not PA11. The reason this worked before, is because the line
before made PA12 output, and without setting the GPIO_ODR register
_before_ hand, this meant as soon as it was switched to output, it
received the reset value of GPIO_ODR for PA12, ie, 0. (Effectively
doing a "free" gpio_clear(GPIOA, GPIO12)
Because GPIO11 wasn't configured to be an output, the confusing
gpio_clear(GPIOA, GPIO11) was simply configuring the pullup/down value
of the input, which was still ignored, as it was (out of reset) in input
floating mode.
Reviewed-by: Karl Palsson <karlp@tweak.net.au>
Attempt to be more brutal by delaying more often, instead of always
promptly servicing the usb stack.
This is implemented via using timer6 to do a known number of
microseconds busy delay, and so only works on platforms that have
reached at least core timer functionality, and provide the
rcc_apb1_frequency variable.
NOTE! This will _fail_ on devices using the st_usbfs drivers at present,
but the code _should_ work, and the tests land to verify that the
library fix, fixes the problem. (see subsequent commit)