diff --git a/README.md b/README.md index 43f51b3..d47321f 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,9 @@ fw for a ch32v203 node w/ w5500 ethernet - SPI DMA only works with [prescalers](https://git.hye.su/mira/ch32-node/src/branch/master/src/spi_dma.c#L140) 8 and 64? - Also, for some reason it needs a ~50ms delay before configuring w5500 when compiled **with** `-O0`, not needed with `-Os`... -TODO: LA?... +idk... +![systick_dma](notes/2024-10-14-182212_1566x610_scrot.png) + ## ~~previous (DNS Processing)~~ solved by [patching](https://git.hye.su/mira/ch32-node/commit/259d63197e06c1a92b979490d4cd8f0fdb98f8d0#diff-6ba50689ba55dac7cfe3e9b011e594098c931e21) the korean bloatlib (`dns_makequery` in DNS.c) diff --git a/notes/2024-10-14-182212_1566x610_scrot.png b/notes/2024-10-14-182212_1566x610_scrot.png new file mode 100644 index 0000000..6e7aa68 Binary files /dev/null and b/notes/2024-10-14-182212_1566x610_scrot.png differ diff --git a/src/main.c b/src/main.c index 31c50f5..2e33688 100644 --- a/src/main.c +++ b/src/main.c @@ -53,7 +53,7 @@ int main(void) { // TODO: enabling any kind of SysTick IRQ literally causes the socket to hang forever // with 1ms interval the hang is on DHCP_ACK, on check_DHCP_leasedIP -> sendto() ARP req // with 1s it happens somewhere on DNS req - init_systick(); + // init_systick(); tim2_init(); // systick irq enable here would complete the DHCP configuration and hang on DNS.. diff --git a/src/spi_dma.c b/src/spi_dma.c index a5435d9..c9290d4 100644 --- a/src/spi_dma.c +++ b/src/spi_dma.c @@ -137,7 +137,7 @@ void init_spidma(void) { SPI_DataSize_8b | // 8-bit data frame format SPI_CPOL_Low | // Clock polarity SPI_CPHA_1Edge | // Clock phase - SPI_BaudRatePrescaler_8 | // Baud rate prescaler + SPI_BaudRatePrescaler_64 | // Baud rate prescaler SPI_NSS_Soft; // Software NSS management // Enable TX and RX DMA