11/23/2023 0 Comments Bit bang spi arduino![]() I've noticed on other threads people doing I/O bit-banging upwards to 150-MHz on the T4. ? Here is some of the old code, you'll notice it bit-bangs SPI, but there are no delays in there.ħ. Hence I could set the SIN bit first, wait for a short time, then set the SCLK clock, wait, remove the SCLK clock, repeat. From the description looks like it only matters how do these signals relate to each other. Move from shift register to display register (XLAT). Now the question mark: on looking at the old code for Soft SPI ops, I notice there are no delays in there, so I am wondering how the darn thing was throttled back far enough on the T4.x (running at 1.008 GHz, BTW) that it ran fine on the Lcd, which I believe is limited to 30-MHz SPI rate. Clock (SCLK), read a bit to display as currently represented by SIN. This tells the slave to read the data on the MOSI line. Therefore, interested in a Soft SPI library, re item 1 above.Ħ. For each of the 8 bits the SCK (clock) line is briefly brought high, and then low again. Now to the point: it occurs to me that Soft SPI is so fast on the T4.x that I can use multiple instantiations on different sets of pins, and not worry about issues with the Hard SPI ports. I thought it might be "much much slower".ĥ. Of interest, amazingly the Soft SPI test runs on average "only" 1.42X slower. So the results using ILI9341_t3 and the old Soft SPI code with the standard graphicstest program are shown below. So I grabbed the Adafruit_ILI9341 library circa 2016 from my old Teensyduino install on IDE v1.6.13, and at first it wouldn't compile, but I hacked on it a bit, and got it working.Ĥ. What I did do was try using Soft SPI with the ILI9341 displays and the T4.x, but that constructor no longer exists in the ILI9341_t3 library. I think other people do it, but I didn't spend a lot of time debugging. I tried using 2 instantiations of the ILI9341_t3 class to operate two standard Lcd modules from SPI0 (using different CS pins of course), but it wouldn't work for me. So, I d/l'ed Teensyduino v1.53 to Arduino IDE v.1.8.12 a couple of days ago.Ģ. Does someone have one? You'll know why I ask in a bit. First off, I've tried to find a Soft SPI library for Teensy 4.x, but found little.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |