micropython puts the pointer-ness into the typedef; we can put the
const-ness there too.
this reduces the delta to micropython; for instance, emitinlinextensa
and emitinlinethumb now match upstream.
These are moved:
* Display -> busdisplay.BusDisplay
* FourWire -> fourwire.FourWire
* EPaperDisplay -> epaperdisplay.EPaperDisplay
* I2CDisplay -> i2cdisplaybus.I2CDisplayBus
`paralleldisplay` is now `paralleldisplaybus` (and registered as
`paralleldisplay` too).
Bus related helpers are split out of display_core into bus_core.
It is in still displayio since it is a dependency of both
busdisplay and epaperdisplay.
Fixes#7667
.. so they need a correct row count, which could be the "core.width"
of a 90/180 rotated display.
While I discovered this on the very unusual 320x960 display it could have
affected any framebuffer display that was taller than it was wide,
including sharp memory displays and rgbmatrix displays.
* can now send the I2C bus initialization code
* can now reset the display on an I/O expander pin
* parameters re-ordered to enable easy use with **board.TFT_IO_EXPANDER
with the i2c bus operating at 400kHz this achieves a 4.8kHz SPI clock
rate which could be worse.
It accepts the same style of init sequence as displayio.
tested by scoping the pins on the espressif lcd dev kit with a dummy init sequence:
```python
dotclockframebuffer.ioexpander_send_init_sequence(
bus=bus,
i2c_address=expander_addr,
gpio_address=1,
gpio_data_len=1,
gpio_data=0xff,
cs_bit=1,
mosi_bit=3,
clk_bit=2,
init_sequence=init_sequence)
```
We use it to open endpoints as they are used. Fetching the descriptor
as needed can cause issues with devices that we're expecting a control
packet while another transaction was ongoing. Specifically, a usb
thumb drive didn't expect a control transaction while doing a SCSI
transaction.
This PR also aborts transactions on timeout or ctrl-c interrupt. It
doesn't always recover though...