- To design a workflow to generate One Time Passwords using Javascript function nodes and display it in the Dashboard with visualisations.
- We will use the inject node to trigger the working function to generate the OTP. We will set a time based trigger event so that a new OTP is generated for every few minutes.
- We will use a function node where the Javascript function will be written which will be responsible to generate the OTP number within the specified range.
- We will use the debug node to display the OTP in the debug window. Every time a new OTP is generated, this node displays it in the debug window.
- We use the Chart node to visualise the range of values of the OTP’s generated.
- We also have an audio out node to have a voice output of the OTP which was generated by the function.
Nodes used are
- Text Input Node : For displaying and entering the Telephone number and also to provide the audio output by transferring to the audio out node.
- Audio Out Node : This is a part of the UI Dashboard, and is used for providing the audio output. Both the audio out nodes have a similar configuration, one speaks the telephone number while the other the OTP generated.
- Debug Node : This outputs the generated OTP in the debug window.
- Chart Node : Visualisation for the OTP’s generated until now. Tells us about the range of the values generated by the JS function.
- To design a workflow to retrieving the Environmental Conditions of a Location and using Weather API’s and it using and display it in the Dashboard with visualisations.
- We will use the Sense HAT Simulation node to get the weather data (environmental events) from their servers.
- We will use a function node where the Javascript function will be written which will be responsible to get the pressure, temperature and the humidity values from the Sense HAT node.
- We will use the Debug nodes to display the environmental values in the debug window.
- We use the Gauge nodes to visualise the range of values of all the environmental values obtained.
- The function nodes responsible for the JavaScript Function to retrieve the values from the API and then to display them in the debug window and also in the UI dashboard.
- Output nodes is a collection of 2 nodes used for each of the function nodes specified before, the nodes are a debug node, which displays the corresponding detail of the environmental condition in the debug window, and then the Gauge nodes which display the same data on the form of a gauge in the dashboard component of the node-red UI.