Open 3electrons opened 3 years ago
All of this is correct. 99% of customers will never need to change this setting from the default CANFD_BRS_ENABLED_ISO
as
But we can have a getter/setter for this if you have some use for it.
My concern was, what If somebody use the code against some older interpidcs hardware that actually does not support ISO or BRS for example.
What I checked is that whatever you set to FDMode (0xf0 for example) it is:
Hence the only reasonable concern left is:
I have only CanValue4 Industrial and standard CanValue4 on my desk.
So not really sure if all type of devices might use the same settings for FDMode in CANFD_SETTINGS. Possible values are:
Question is if CANFD_ENABLED can be used in some older or different devices? Hence possibly having nice method for setting FDMode might be good idea.
Maybe something like:
bool IDeviceSettings::setCANFDMode( bool enabled, bool iso = true)
void IDeviceSettings::getCANFDMode( bool & enabled, bool & iso)
As currently the only way I found to switch CANFD mode is by:
dev->settings->getMutableCANFDSettingsFor(myNetwork)->FDMode = myMode;
setting one of { NO_CANFD, CANFD_BRS_ENABLED, CANFD_BRS_ENABLED_ISO}Adding use case to interactive example might be an good idea too.