Pymakr will not connect - inconsistent following firmware 0.9.3.b2



  • HI @kwix,

    For FTP you don't need the FTDI drivers. Make sure you follow these exact instructions. Notice the passive mode and don't forget to configure the 'one data connection at a time'.

    If that works, place the REPL script in the boot file and try to connect via pymakr or commandline. Very probably windows either already has the ftdi drivers or will try to install them automatically when first connecting the expansion board to your pc.



  • Hi @Ralph and @MainSheet I am using the same versions and OS as @MainSheet and getting the same issues. I'm not sure how to access the boot.py to edit this. I've tried via FileZilla (host: 192.168.4.1 user: micro pwd: python) it using the Site Manager while connected and not connected to the lopy-wlan but it just times out. I have ping-ed it and it's fine. Did you have to install the FTDI drivers and if so, is there a user-friendly instructions on which one to install and how to install it? I'm looking into www.ftdichip.com but there's three of them and I've got limited knowledge and don't want to blindly change my computer driver and registry settings. Help please!



  • thanks @Ralph, yes that did help things.



  • @Ralph Thank you very much - your answer was spot on :) All working again!



  • @AgriKinetics @MainSheet One thing you should try is adding this line to your boot file, above your wifi code

    if machine.reset_cause() != machine.SOFT_RESET: 
    

    What happens is that Pymakr sends a soft reset after connecting to the device, making boot.py run and re-initiate the wifi connection, which in turn breaks the connection. This line prevents that. Check the docs for more info



  • I have a similar situation:

    Windows 10
    Pymakr 1.0.0.b6
    usb COM11 (device manager shows 115200,8,n,1)
    Pymakr>settings>Preferances>Pycom Device
    Device:COM11
    User:micro
    Password:python

    LoPy 0.9.3.b2

    here is my boot.py

    # boot.py -- run on boot-up
    import os
    from machine import UART
    uart = UART(0, 115200)
    os.dupterm(uart)
    
    #Setup the WiFi Network
    from network import WLAN
    # configure the WLAN subsystem in station mode (the default is AP)
    wlan = WLAN(mode=WLAN.STA)
    # go for fixed IP settings (IP, Subnet, Gateway, DNS)
    wlan.ifconfig(config=('192.168.0.118', '255.255.255.0', '192.168.0.1', '192.168.0.1'))
    wlan.scan()     # scan for available networks
    wlan.connect(ssid='goofy', auth=(WLAN.WPA2, 'mypass'))
    while not wlan.isconnected():
        pass
    print(wlan.ifconfig())
    

    Putty (Serial mode connection) on COM11 gets a >>> prompt and works consistently
    Putty (Telent to 192.168.0.118) gets a >>>

    Filezilla gets

    Status:	Logged in
    Status:	Retrieving directory listing of "/flash"...
    Command:	CWD /flash
    Response:	250 
    Command:	TYPE I
    Response:	200 
    Command:	PASV
    Response:	227 (192,168,0,118,7,232)
    Command:	LIST
    Error:	Connection closed by server
    Error:	Failed to retrieve directory listing
    

    Pymakr 1.0.0.b6

    gets a popup window

    Warning:
    QStackedWidget::setCurrentWidget: widget 0x4ba19c8 not contained in stack
    

    Pymakr configured to COM11, Pycom Console shows

    Connecting to a Pycom device...
    Error while communicating with the Pycom device! (click to attempt to reconnect)
    Connecting to a Pycom device...
    Error while communicating with the Pycom device! (click to attempt to reconnect)
    Connecting to a Pycom device...
    Error while communicating with the Pycom device! (click to attempt to reconnect)
    

    Pinged 192.168.0.118 - pinged ok
    changed the Pycom device config to 192.168.0.118
    Pycom Console shows

    Connecting to a Pycom device...
    Error while communicating with the Pycom device! (click to attempt to reconnect)
    Connecting to a Pycom device...
    Error while communicating with the Pycom device! (click to attempt to reconnect)
    Connecting to a Pycom device...
    Error while communicating with the Pycom device! (click to attempt to reconnect)
    

    Tried this whole thing over again using Ubuntu, similar results.

    My thought is that Server() is still not working correctly in 0.9.3.b2...

    Steve


Log in to reply
 

Pycom on Twitter