Node Red config file

cancel
Showing results for 
Search instead for 
Did you mean: 

Node Red config file

Jump to solution
309 Views
hns80
Contributor II

The Freemaster + Node Red tutorial is good, but leaves out a step.

After showing how to export the fmcfg file, the instructor does not show how to make Node Red aware of the file.

I tried closing node and relaunching with the fmcfg file as the only argument, but I could not connect to the node server.

How can the variable information be imported to the Node Red project?

 

0 Kudos
1 Solution
279 Views
iulian_stan
NXP Employee
NXP Employee

Please find attached the archive containing pmp (FreeMASTER project) and fmcfg (FreeMASTER Lite project) used in the demo. I also included the settings.js (Node-RED configuration) - this one would be automatically generated due to `"node_red": true`, if there is no settings file in any of the default locations.

View solution in original post

0 Kudos
3 Replies
283 Views
hns80
Contributor II

Can you provide the config file(s) you used in the Node Red tutorial?

0 Kudos
280 Views
iulian_stan
NXP Employee
NXP Employee

Please find attached the archive containing pmp (FreeMASTER project) and fmcfg (FreeMASTER Lite project) used in the demo. I also included the settings.js (Node-RED configuration) - this one would be automatically generated due to `"node_red": true`, if there is no settings file in any of the default locations.

View solution in original post

0 Kudos
295 Views
iulian_stan
NXP Employee
NXP Employee

Hi @hns80,

To enable the Node-RED feature you need to specify "node-red" property in the "fmcfg" configuration file (at the root level). It accepts 2 types of values:

  • boolean - if set to "true" it will search for a "settings.js" file in default locations usually "~/.node-red" (it uses similar discovery strategy as described in node-red repo). If no file is found in any of the default locations, FreeMASTER will create one and store it in "~/.node-red/settings.js"
  • string - path to your custom configuration file (relative path will be resolved with respect to the "fmcfg" file location)

 

Kind regards,
Iulian

0 Kudos