NetBurner 3.5.7
PDF Version
Configuration Variables

Configuration System Variables. More...

Topics

 Configuration Variable Flags
 

Classes

class  config_obj
 Base class used to create configuration objects. More...
 
class  config_value
 Base class used to create a configuration value. More...
 
class  config_uint
 Unsigned 32-bit Integer Configuration Variable. More...
 
class  config_int
 Signed 32-bit Integer Configuration Variable. More...
 
class  config_double
 Double Float Configuration Variable. More...
 
class  config_bool
 Boolean Configuration Variable. More...
 
class  config_string
 String Configuration Variable. More...
 
class  config_pass
 Password string Configuration Variable. More...
 
class  config_IPADDR4
 Configuration Variable for IPADDR4 (IPv4) object types. More...
 
class  config_IPADDR
 Configuration Variable for IPADDR (IPv6) object type. More...
 
class  config_MACADR
 Configuration Variable for MACADR object type. More...
 
class  config_chooser
 Chooser Configuration Variable - Select From a List of Items. More...
 
class  config_int_limit
 A config_int with minimum and/or maximum values Attempting to set a value lower than the minimum or greater than the maximum will fail with an error both programmatically and in the Config Web UI. More...
 
class  config_uint_limit
 A config_uint with minimum and/or maximum values Attempting to set a value lower than the minimum or greater than the maximum will fail with an error both programmatically and in the Config Web UI. More...
 
class  config_double_limit
 A config_double with minimum and/or maximum values Attempting to set a value lower than the minimum or greater than the maximum will fail with an error both programmatically and in the Config Web UI. More...
 
class  config_string_limit
 A config_string with minimum and/or maximum lengths Attempting to set a value shorter than the minimum or longer than the maximum will fail with an error both programmatically and in the Config Web UI. More...
 
class  config_pass_limit
 A config_pass with minimum and/or maximum lengths Attempting to set a value shorter than the minimum or longer than the maximum will fail with an error both programmatically and in the Config Web UI. More...
 

Functions

void SaveConfigToStorage ()
 Save configuration to flash storage.
 
void OverrideConfig ()
 Create this function to override config settings.
 

Variables

const char * AppName
 Application name displayed in web interface and console output.
 

Detailed Description

Configuration System Variables.

#include< config_obj.h>


Configuration variable objects are part of the NetBurner 3.x configuration system. The use of configuration objects facilitates a much easier method to create and store non-volatile information for both system configuration and for user application configuration and storage. They use a JSON interface so the information can be easily downloaded to save a configuration, or uploaded to configure the entire device at one time, such as in production bring-up. This includes system configuration such as IP addresses, and also any settings specific to your application.

The JSON value types include: integer, unsigned integer, float, boolean and string. There are also objects for IPv4 IP, IPv6 IP, MAC addresses, passwords, and selection lists options. In JSON everything is represented as a string, so there are object member functions to convert between values. These functions make use of the NBString class.

For customers using the 2.x tools, the User Parameter flash sector method is still available, but we do recommend converting to the new configuration system. In 3.x you have the ability to access the data through a web configuration page and also through JSON, but you can certainly choose not to use those features and treat the configuration system as internal storage, and any configuration can be done through your application just as with the 2.x tool set.

Note
All modifications to configuration objects are marked as pending. A call to SaveConfigToStorage is required to save changes to flash memory.

Function Documentation

◆ OverrideConfig()

void OverrideConfig ( )

#include <config_obj.h>

Create this function to override config settings.

This function exists as a weak reference. So you just need to create it and the force set any configvariabls you want to control. This will be called after config is loaded before any config is used by anything. It will also be called when anyone calls rever on the confg system.

Variable Documentation

◆ AppName

const char* AppName
extern

#include <config_obj.h>

Application name displayed in web interface and console output.

USB CDC Example for SOMRT1061

This example demonstrates how to use the USB CDC (Communications Device Class) on the NetBurner SOMRT1061 platform. The device will appear as a virtual COM port when connected to a host computer.

Features:

  • USB CDC serial communication
  • Echo received data back to host
  • Status reporting via network console
  • LED status indication

USB CDC Throughput Test for SOMRT1061

This example implements maximum throughput testing for USB CDC communication. It supports bidirectional throughput measurement with various test modes.

Test Modes:

  • TX test: Device sends continuous data to PC as fast as possible
  • RX test: Device receives data from PC and measures throughput
  • Loopback: Device echoes data back for round-trip testing