2021-01-10, 10:08 AM
Have you considered reporting the problem as a Github issue to the authors of the modules you are using? They might be able to offer assistance, both in making things work without any code changes and in how to go about fixing the problem. If you report with pointers to where you think the problem is all the better, as it shows to the authors that you've put effort into trying to find the root cause. Often you can get help that way, if the module that you use is not abandoned.
Publishing your version as a new module is a no no in my books, if you do not first try to get the changes "upstream", meaning included in the original module and a new version published. Otherwise there will be two modules, with a slightly different set of bugs and features. If the original module gets a bug fix or a feature your version won't and vice versa.
If the upstream module is not accepting any or your change only then you should publish a new one.
Having said that I can suggest an alternative avenue of attack: skip Node-RED and get first the INA219 communication working. Maybe you are using https://github.com/brettmarl/node-ina219? Just take the example code and make it work for your use case. Then when you have it working by itself you can consider how to integrate it with the rest of the system. I would personally create a Signal K server plugin, but I have a certain bias, as I am one of the primary authors of SK server. Still, it is a very good option. If you use the embedded version of Node-RED you can create still create your dashboard in Node-RED, as SK data is available handily.
PS Use i2cdetect to check the active addresses on the bus
Publishing your version as a new module is a no no in my books, if you do not first try to get the changes "upstream", meaning included in the original module and a new version published. Otherwise there will be two modules, with a slightly different set of bugs and features. If the original module gets a bug fix or a feature your version won't and vice versa.
If the upstream module is not accepting any or your change only then you should publish a new one.
Having said that I can suggest an alternative avenue of attack: skip Node-RED and get first the INA219 communication working. Maybe you are using https://github.com/brettmarl/node-ina219? Just take the example code and make it work for your use case. Then when you have it working by itself you can consider how to integrate it with the rest of the system. I would personally create a Signal K server plugin, but I have a certain bias, as I am one of the primary authors of SK server. Still, it is a very good option. If you use the embedded version of Node-RED you can create still create your dashboard in Node-RED, as SK data is available handily.
PS Use i2cdetect to check the active addresses on the bus