SPI drivers to UART for SC16IS752
Hello there,
Is there any support or anyone that could help to get this chip to work under the UpBoard SPI?
https://www.nxp.com/products/analog/signal-chain/bridges/dual-uart-with-ic-bus-spi-interface-64-bytes-of-transmit-and-receive-fifos-irda-sir-built-in-support:SC16IS752_SC16IS762
We use this successfully on the Pi: https://github.com/raspberrypi/linux/blob/rpi-4.19.y/drivers/tty/serial/sc16is7xx.c just hoping something similar is available for the UpBoard?
This is for a device we are making http://www.machinon.com
Any help would be great!
Ed
Comments
-
No one?
-
Hi Ed
Sorry for my late response.
I haven't tried myself to get that chip working with the UP board, but I think it should be possible.
The easiest approach may be to create a simple kernel module that registers the SPI device with the kernel, providing information for the device connection such as SPI bus, chip-select, max-frequency, and GPIO IRQ number if needed.
On the following link, there is a section titled "DECLARE SPI DEVICES" which has some relevant information:
https://www.kernel.org/doc/Documentation/spi/spi-summaryThis is an example of a kernel module that registers a new SPI device when the module is loaded:
https://github.com/MinnowBoard-Projects/minnow-maker/blob/master/low_speed_spidev/low-speed-spidev.c
Googling the use of the spi_register_board_info() or spi_new_device() kernel API functions should provide other examples.Another possible approach, which can work for some drivers, is to create an ACPI SSDT overlay table (analogous to a device-tree overlay) to register the device on the SPI bus – a minor tweak to the device driver may be required in some cases to support this.
I hope that helps.
Best regards,
-Dan -
Hi Dan,
Many thanks for the help.
I do not have knowledge or tools to modify the kernel, in fact I'm not even sure what the kernel is... I was just hoping it was a case of installing a driver.Any chance of a 1,2,3 steps for dummies? I'm more a electronics guy and what I'm trying to do is to have the UpBoard to talk to the machinon main board, see image.
Quick search on kernel linux and the SPI UART seems to be supported, I guess is more about telling the OS how to use it? If so, any idea?
I really have no clue on kernel stuff... -
Hi EdddieN,
Unfortunately that will require integration and validation work specific for that hardware and at the moment we are not planning to support it.
We can help you to get in touch with one of our software partner for software integration and validation if you need that device to be working with your project.