• Damien George's avatar
    extmod/network_ppp_lwip: Add network.PPP via lwIP. · bc952d37
    Damien George authored
    This commit adds a new `network.PPP` interface which works on any port that
    has bare-metal lwIP, eg rp2, stm32, mimxrt.
    
    It has been tested on stm32.  A board needs to enable
    `MICROPY_PY_NETWORK_PPP_LWIP` and then it can use it as follows:
    
        import network
    
        ppp = network.PPP(uart)
        ppp.connect()
    
        while not ppp.isconnected():
            pass
    
        # use `socket` module as usual, etc
    
        ppp.disconnect()
    
    Usually the application must first configure the cellular/etc UART link to
    get it connected and in to PPP mode first (eg ATD*99#), before handing over
    control to `network.PPP`.
    
    The PPP interface automatically configures the UART IRQ callback to call
    PPP.poll() on incoming data.
    Signed-off-by: default avatarDamien George <damien@micropython.org>
    bc952d37
extmod.cmake 14.4 KB