# RS-485 + iCE40 for better CAN-FD

This is an idea I have been toying with for a while and wanted to get an opinion. When I first heard about CAN-FD I thought it was going to be the answer to this problem. However most mid range microcontrollers do not have support for CAN-FD (LPC546 excluded). The STM32H7 does have support, but the cost of that microcontroller is far too high for most applications. There are some devices like the TCAN4550 and the Microchip version which are quite good, but not as flexible.

With an RS-485 transceiver and an iCE40 or other FPGA one can make a custom transceiver system. The idea would be to interface a microcontroller over SPI or UART to the FPGA. The FPGA would handle the actual protocol, which would be similar to CAN.

The advantages of such a system are:

• Flexible system speed and cost (up to 48 Mbit/s)
• Many settable addresses per device
• Option for a multi-cast system
• Not restricted to a particular architecture

My questions are:

• Is the cost really worth it or am I just trying to reinvent the wheel here?
• Can arbitration still occur at high speeds or are very accurate clocks needed?
• Is there already a project like this out there that I just missed?

It might make for a great open source protocol that I would certainly be willing to put some effort into developing.

• You miss the cost of FPGA and development. You would need to make thousands or tens of thousands of such device to earn the cost back. And the FPGA will easily cost 5$with enough gates to support CAN. – Jan Dorniak Aug 8 '18 at 18:40 • Also take a look at the STM32H750 - a recently launched "cheap" version of the H7 - going as low as 3.5 USD – Jan Dorniak Aug 8 '18 at 18:41 • @janDorniak You are right the cost to develop and test would be high. I guess if the whole system cost is going to be ~10$ for transceiver, fpga and support it might not be worth it. – Meozaa Aug 8 '18 at 18:50
• @JanDorniak I took a look at the H750. That looks like an excellent controller. At 10\$ for a 400Mhz MCU with CAN-FD I think there is no contest. It looks like they are also working support into the ST tool-chain for these devices. – Meozaa Aug 8 '18 at 18:56
• ask your distributor - the H750 has listed budget prices under 5 USD. There is a competitor - I.MX RT, which actually was earlier on the market and has that extra feature of in-bus encryption for QSPI. But way less RAM. – Jan Dorniak Aug 8 '18 at 19:37