Ha Thach
a41ab41b8b
Merge pull request #2047 from jbtheou/master
...
cdc: fix line_coding aligment
2023-04-28 11:25:53 +07:00
hathach
190acc1fb0
add aligned(4) for cdc_line_coding_t
2023-04-28 11:12:03 +07:00
Jean-Baptiste Theou
8f47976639
cdc: fix line_coding aligment
...
While calling tud_cdc_n_get_line_coding, the structure is copied into
the destination.
Dump of assembler code for function tud_cdc_n_get_line_coding:
0x000193f4 <+0>: mov.w r2, #2112 @ 0x840
0x000193f8 <+4>: ldr r3, [pc, #20 ] @ (0x19410
<tud_cdc_n_get_line_coding+28>)
0x000193fa <+6>: mla r0, r2, r0, r3
=> 0x000193fe <+10>: ldr.w r3, [r0, #6 ]
0x00019402 <+14>: str r3, [r1, #0 ]
On some platform (tested on LPC55S28), the address needs to be 4-bytes
aligned. Without this, the address is
(gdb) p &_cdcd_itf.line_coding
$3 = (cdc_line_coding_t *) 0x40100006 <_cdcd_itf+6>
which leads to a HardFault. With this fix
(gdb) p &_cdcd_itf.line_coding
$5 = (cdc_line_coding_t *) 0x40100008 <_cdcd_itf+8>
and the function can be called properly
Signed-off-by: Jean-Baptiste Theou <jb@thing.com>
2023-04-27 15:48:15 -10:00
Ha Thach
e3b3229d61
Merge pull request #2046 from hathach/add-usb2uart-host-driver
...
Add usb2uart serial host driver
2023-04-28 00:06:08 +07:00
hathach
732686cc10
add tuh_cdc_set_baudrate()
2023-04-27 23:22:10 +07:00
hathach
ee58278ed2
add code to calculate divisor from baudrate for ftdi
2023-04-27 23:08:25 +07:00
hathach
8214f0f497
clean up
2023-04-27 17:40:08 +07:00
hathach
c10f52b237
forgot to add cp210x header
2023-04-27 17:39:02 +07:00
hathach
438387be8c
more refactor
2023-04-27 17:32:56 +07:00
hathach
86f6fd17ed
cp210x seems to work well
2023-04-27 17:09:21 +07:00
hathach
a32ef1cde1
more host serial refactor
2023-04-27 16:32:42 +07:00
hathach
9698a088db
refactor acm function
2023-04-27 15:29:44 +07:00
hathach
85d9925d24
refactor ftdi driver
2023-04-27 15:20:04 +07:00
hathach
293a6222f8
rename ftdi_host to ftdi_sio
2023-04-27 11:08:42 +07:00
hathach
cf95b44001
enable CDC FTDI
2023-04-26 22:36:17 +07:00
hathach
45169d833d
hacky, but ftdi work with hard code baudrate = 9600
2023-04-26 22:36:17 +07:00
hathach
1a229f3ce2
fix pio vbus typo
2023-04-26 22:36:17 +07:00
Ha Thach
4c7fd1648e
Merge pull request #2043 from hathach/fix-nxp-build
...
fix build with nxp since mcux-sdk from 2.13.0 remove CMSIS folder
2023-04-26 22:33:28 +07:00
hathach
ad39833ea4
fix build with nxp since mcux-sdk from 2.13.0 remove CMSIS folder
2023-04-26 22:10:13 +07:00
Ha Thach
908e23d109
Merge pull request #2040 from hathach/update-imxrt-deps
...
bump up imxrt mcux-sdk to 2.13.1
2023-04-24 16:59:05 +07:00
hathach
841a62170e
bump up imxrt mcux-sdk to 2.13.1 commit f357a1150f6cf6c6b844f53f2d426bfb3e649850
2023-04-24 16:54:26 +07:00
Ha Thach
964e7ebf21
Merge pull request #2013 from tannewt/imx_1042
...
Handle iMX RT 1042 usb naming
2023-04-24 16:53:24 +07:00
Ha Thach
8ede566c41
Merge pull request #2039 from hathach/add-cmake-build
...
Add cmake build
2023-04-24 16:43:40 +07:00
hathach
a4d5d51549
add wip note
2023-04-24 16:24:06 +07:00
hathach
5254202b20
minor update
2023-04-24 11:54:58 +07:00
hathach
9858d45815
build all freertos, not able to build net lwip due to lack of sio_open()
2023-04-21 22:07:58 +07:00
hathach
11e1aff389
update freeRTOS kernel to latest for library cmake
...
add per family freeRTOSConfig.h also make changes to build with
freertos_kernel cmake
- hard coded configPRIO_BITS based on family
- change configSUPPORT_STATIC_ALLOCATION to 0,
configSUPPORT_DYNAMIC_ALLOCATION to 1
- enable configRECORD_STACK_HIGH_ADDRESS for tracing
- enable INCLUDE_xTaskGetCurrentTaskHandle which is required to compile
stream_buffer (although we don't use it).
2023-04-21 20:55:44 +07:00
hathach
6daa135201
update most examples cmake to build with imxrt
2023-04-21 18:23:40 +07:00
hathach
0afe1b3684
example run well with cmake for imxrt
2023-04-21 18:10:28 +07:00
Ha Thach
0871238cac
Merge pull request #2024 from jfedor2/sie_ctrl_fix
...
[rp2040] Make writes to SIE_CTRL aware of concurrent access
2023-04-21 12:17:57 +07:00
Jacek Fedorynski
9bf97e3e52
[rp2040] Make writes to SIE_CTRL aware of concurrent access
...
This commit makes it so that when setting the START_TRANS bit in the
SIE_CTRL register, along with some other bits, we first set all the
other bits, then wait some cycles, and then set the START_TRANS bit.
Doing so protects against a situation where the USB controller is
reading the register at the same time and gets an incorrect value.
This mirrors the procedure already applied to buffer control
registers.
2023-04-20 20:23:31 +02:00
hathach
2ac289685a
clean up
2023-04-20 16:55:48 +07:00
hathach
b42d3e431c
board test running with cmake
2023-04-20 16:43:00 +07:00
hathach
fab48e5bcc
adding cmake build for imxrt1010
2023-04-20 14:09:38 +07:00
Ha Thach
9771c76f25
Merge pull request #2033 from ReimuNotMoe/master
...
Fix compatibility with the latest Microchip XC16 compiler
2023-04-19 12:53:23 +07:00
Reimu NotMoe
c0674142a8
Merge branch 'hathach:master' into master
2023-04-18 23:20:25 +08:00
Reimu NotMoe
9002dc7067
Use __GNUC__ macro to determine if __has_attribute is supported
2023-04-18 17:27:42 +08:00
Ha Thach
c3a60ed355
Merge pull request #1920 from mikee47/fix/midi-definition
...
MIDI_CIN_NOTE_ON definition transposed with MIDI_CIN_NOTE_OFF
2023-04-18 10:43:52 +07:00
Mengsk
412b557a08
Cleanup unnecessary code for 16bit access.
2023-04-17 15:34:20 +02:00
Reimu NotMoe
fa8f3731c1
Implement TU_BSWAP{16,32} correctly for Microchip XC16
2023-04-17 21:02:12 +08:00
Reimu NotMoe
d97b6d57de
Fix compatibility with the latest Microchip XC16 compiler
2023-04-17 20:20:22 +08:00
slc-tl
8c780a9564
Update porting.rst
...
Adds more in depth documentation of how tud_task does not need to be polled in implementations that use an RTOS / scheduler.
2023-04-14 17:07:33 -06:00
HiFiPhile
818bda18c2
Fix FIFO transfer and buffer alignment.
2023-04-14 23:37:07 +02:00
HiFiPhile
2f2c8ce9ec
Fix GCC build.
2023-04-14 21:00:55 +02:00
HiFiPhile
723e21ad6a
Merge pull request #2025 from dauc/master
...
Fix spelling configuraiton->configuration
2023-04-14 18:48:03 +02:00
HiFiPhile
71d2ccd78f
Fix CI
2023-04-14 17:29:32 +02:00
HiFiPhile
413b0a7da5
Use PLL clock.
2023-04-14 17:12:47 +02:00
HiFiPhile
0ea23904c4
Add stm32g0b1nucleo BSP.
2023-04-14 16:07:04 +02:00
HiFiPhile
152a22f3ee
Update lib & template.
2023-04-14 16:05:56 +02:00
Devin Auclair
16ed10a6e4
Fix spelling configuraiton->configuration
2023-04-14 12:48:59 +00:00