Registration template macro creation➧
Tip
If you are unfamiliar with the Macros system, a thorough guide and descriptions of all the fields and parameters can be found in the Macros section of this documentation.
Attention
There can be only one registration macro for one model, otherwise you will get an error.
Common tab➧
- Name:
Reg for C-Data FX16xx FW3
- Enabled:
Yes
- Device vendor: for the purpose of this demonstration we use the vendor
C-Data
- Device models:
C-Data FD1616 (FW3)
,C-Data FD1608 (FW3)
Example
Parameters tab➧
Select a C-Data device and the ONT you want to register from the drop-downs at the top of the page.
Add a new Parameter.
- Property:
line
- Property display name:
Line profile
- Required:
True
- Parameter type:
Dropdown list from variables
-
Value source:
data.pon_profiles.line
Sample profiles
Info
The profiles you may receive from your device may differ.
If that's the case, make the required changes to your macro.
-
Item name:
${item.name} (${item.id})
- Item filter:
item.id != 0
Add another Parameter.
- Property:
srv
- Property display name:
Service profile
- Required:
True
- Parameter type:
Dropdown list from variables
-
Value source:
data.pon_profiles.srv
Sample profiles
Info
The profiles you may receive from your device may differ.
If that's the case, make the required changes to your macro.
-
Item name:
${item.name} (${item.id})
- Item filter:
item.id != 0
Template tab➧
Select a C-Data device and the ONT you want to register from the drop-downs at the top of the page.
Template block:
Paste the following code:
interface gpon 0/0
ont add {{iface._port}} {{free.first}} sn-auth {{ont._serial_hex}} ont-lineprofile-id {{params.line.id}} ont-srvprofile-id {{params.srv.id}}
If the macro worked, you should see a similar output in the Live result field.