This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
New hat for SignalK
#1
Hello sailors,

I just made (got) the first prototype of a new hat for RPi.
When I decide to develop it, the main goal was not to use too many GPIO pins to avoid conflicting with other hats as much as possible and also to be able to use it with older and newer RPi models. 

So, this hat is based on a USB 2.0 Hub, made with FE1.1S chip, the same chip used in some other USB HUB hats for RPi Zero. 
Internally connected at this hub is an FTDI 4232 chip which provide 4 serial ports with RS422 converters for 4x NMEA0183 in/out connections.
On another "output" port of the internal hub I placed a canable interface for handling NMEA2000 connection.
The remaining 2 USB ports are available for external use.
An Seatalk 1 input is also available through GPIO pin.

There are also 2 INA260 sensors on board, connected to the I2C GPIO pins, to measure as much as +36V at up to 15A Continuous on either the high or low side and an also an  RTC based on DS3231 chip with CR1220 battery socket and optional connector for external battery.

I am currently testing in on the bench, and I have good results connecting by NMEA2000 with some Si-Tex AIS Transponder, Garmin chartplotter and also some Arduino based NMEA2000 devices. 

The NMEA0183 looks good also but I still have some issues for setting unique serial id for each serial port. This will affect the set up of the serial ports in OP and SK because without unique serial numbers only "Remember port (position on the USB-hub)" can be used. And I am not very pleased about that. Smile

I hope I'll be able to make some real test, on the boat, soon enough.

For now I still have to resolve some issues regarding the height of the stacking headers. Some extra-tall stacking headers (male/female, both sides) are on the way. Few days more till have them.

Fair winds,
Seb

   
- SV Haimana
Reply
#2
" .... I still have some issues for setting unique serial id for each serial port."

Can the OpenPlotter Serial app see them both?

Are your serial ports based on the Prolific chipset?
Reply
#3
yes, there are 4 serials for nmea0183 and one for canbus
I'll add some pics and info, maybe today

Some pics...

Serial in OP3
   

If you can see, the adapter can be set only with "Remember port", not with "Remember device". 
This can be an issue if you will change the port but in a stable configuration, when the hat will be always connected at the same port of RPi, this is not a big deal.
The Chinese USB to RS485/422 adapters work in the same way, all of them have same serial.
Having unique serial for each port is a feature which I want to have it but is not mandatory for regular use.
The entire USBto4Serials converter have unique serial for each hat but is shared with its "child" ports.
So, 2 or more hats like this should be stacked without problems on the same RPi, if you need more NMEA0183 ports.

4 serials on internal USB port 3 and the canbus on internal USB port 4 of the hat.
port 1 and 2 are externally available.
   

CanBus in OP3
   

The Garmin chartplotter send simulated data over N2K
   

and Canbus traffic
   

And some other pics with SignalK connections:

   

   
- SV Haimana
Reply
#4
Right I see your problem. I can't for the moment suggest how you might overcome that but would be very interested to know how it goes. I am not sure if a change to the Serial app to add alias/dev or device/dev to the criteria for selection would fix it as the other attributes are identical.

Best of luck, sorry I can't help.
Reply
#5
thank you

each port already have it's own and unique serial-id in SignalK

   
- SV Haimana
Reply
#6
it seems is not a hardware configuration related problem.
searching on FTDI support forum, I found this:

Quote:The udev system on Linux will only pull the ATTRS{serial} attribute from the parent device and note the individual interfaces on the device. this is why the channel letters are not appended to the serial number when udev is used to obtain attributes for a device (this appears to be what serial.tools.list_ports.comports() is doing).

Please see the attached 'udev.png' for an example of the output for the following command issued when a FT4232H was enumerated on an Ubuntu system:

udevadm info --name=/dev/ttyUSB0 --attribute-walk

Please note the output is for the parent device.

It is possible via the D2XX driver to obtain and access devices via their serial number, please see simple.PNG for an example output from the 'simple' Sample included in the D2XX driver download for Linux. This lists the serial numbers of all connected devices and then opens the first one it can find, in this case channel A of the FT4232H.


Best Regards,
FTDI Community

and indeed, on W10 each port have it's own serial number 
I'll do some research later, this aspect does not affect the hat functionality

   
- SV Haimana
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)