pycom / pycom-micropython-sigfox

A fork of MicroPython with the ESP32 port customized to run on Pycom's IoT multi-network modules.
MIT License
196 stars 167 forks source link

TypeError from attempt to produce Gateway ID from LoPy4 board #578

Open khybercat opened 2 years ago

khybercat commented 2 years ago

Hi,

I'm using a LoPy4

(sysname='LoPy4', nodename='LoPy4', release='1.20.3.b4', version='v1.11-95ab8f63 on 2021-09-10', machine='LoPy4 with ESP32', lorawan='1.0.2', sigfox='1.0.1', pybytes='1.6.1')

  1. I went to the Gateway ID section on the page https://docs.pycom.io/tutorials/networks/lora/lorawan-nano-gateway/ to produce this Gateway ID from the board by expanding the WiFi MAC address.
  2. I copied this code :
    from network import WLAN import ubinascii wl = WLAN() ubinascii.hexlify(wl.mac())[:6] + 'FFFE' + ubinascii.hexlify(wl.mac())[6:]

and pasted it into the IDE. I expected to get the Gateway ID, but I got this response:

Traceback (most recent call last): File "", line 1, in TypeError: object with buffer protocol required

Can you see if anything is not correctly configured, or is there a simple answer to this question?

Thanks