-
I'm working with an LCD that you can only transmit to:
false false 1 motorola-spi When transmitting a byte can I just do: Or do I need to drop the incoming buyte? |
Beta Was this translation helpful? Give feedback.
Replies: 7 comments 9 replies
-
Also I write 25600 bytes to >SPI and it takes almost 0.5s ... lcd_buf_size . 25600 ok \ Write a set of bytes to the SPI port It appears to take 458ms? : lcd.display ( -- ) 1 lcd_cs pin! test_fill 458064 |
Beta Was this translation helpful? Give feedback.
-
Software SPI (bitbash) version in Zeptoforth test_fill 411605 |
Beta Was this translation helpful? Give feedback.
-
BTW, have you used |
Beta Was this translation helpful? Give feedback.
-
Just deleted my post, thinking I got something wrong in my math, but at second thought it looks right so I'm reposting this: I wrote the following code:
and got the following result:
i.e. when using |
Beta Was this translation helpful? Give feedback.
-
I wonder if there's an issue with the clock scalers in use, i.e. why your bitbashed version wasn't much faster than the version using |
Beta Was this translation helpful? Give feedback.
-
Okay, I did some calculations and got the following:
i.e. it is really trying to do 7812500 baud, yet the software cannot keep up with the full speed and is instead limited to 1024000 baud. I could potentially rewrite this code to use DMA or PIO or like. |
Beta Was this translation helpful? Give feedback.
-
I managed to optimize
Specifically, it takes 43.977 ms to now send the data. |
Beta Was this translation helpful? Give feedback.
I managed to optimize
buffer>spi
andspi>buffer
quite a bit, speeding upbuffer>spi
by approximately a factor of 4.5:Specifically, it takes 43.977 ms to now send the data.