Community discussions

MikroTik App
 
brasswyrm
just joined
Topic Author
Posts: 6
Joined: Tue Aug 24, 2021 11:39 pm

routeros_api question

Wed Sep 01, 2021 2:25 am

Hello,

Does anyone have experience with the python library routeros_api (https://pypi.org/project/RouterOS-api/)? I have successfully connected to the master router in a wireless wire pair using this library, and I can do simple things like make the LED blink with api.get_binary_resource('/').call('blink'). I can also do this:

foo = api.get_resource(‘/interface/w60g’)
foo.get()

To print out all of the items in the interface/w60g level. Now I would like to set certain values in interface/w60g. For example, I would like to change tx-sector (the beamforming antenna direction). However, if I do something like foo.set(tx_sector=’5’) the command returns an empty array [], and if I do foo.get() again tx-sector is still what it was before. Am I doing something wrong?

Who is online

Users browsing this forum: No registered users and 19 guests