• 0 Votes
    3 Posts
    376 Views
    robert-hhR
    @nervencid You can use any name for your scripts. Only boot.py and main.py are executed as part of the boot process. If you want to run your script then, you have to add a statement like: import myscript e.g. to main.py. You should be able to stop your script with Ctr-C from the console, unless you disable that in your code. To isolate the problems, try running your code with a simple terminal like Putty. Note: You can change the name of the file which is run instead of main.py with machine.main(). The only useful place for that command is in boot.py.
  • About ADC Calibration and usage

    FiPy adc adc accuracy calibration adc precision fipy
    10
    0 Votes
    10 Posts
    1k Views
    N
    @cocoa Thank you for your answer
  • 0 Votes
    3 Posts
    441 Views
    J
    @robert-hh Hi, we don't officially support nb-iot in Pybytes yet. But it's on our roadmap for this year.
  • 0 Votes
    6 Posts
    1k Views
    P
    @arneme Yup. Thats Correct.
  • 1 Votes
    6 Posts
    802 Views
    S
    I actually gave up on the FiPy for not getting this sorted out. The problem is not in the use of a GPIO to wake the board. The problem is in entering or exiting the deepsleep mode. Now reading some more in the forum I found one reference to sometinh that might be related to the issue that I experienced: @crumble said in Deep Sleep Not Waking Up: @jcaron said in Deep Sleep Not Waking Up: Also, remember that machine.deepsleep never returns. Depends :) If it behaves like the pytrack, it may never go to sleep and never increase the program counter. I assume a catched i2c issue in combination with the pytrack. If the OP has a USB volt meter, he can simply verify this. If it still draws a lot of power, it does not sleep and can therefore never wake up. The software watchdog is able to get it out of this state. On my system it is not easy to reproduce. It may need a few hundred deepsleeps before this error occurs.
  • object has no attribute 'pin_deepsleep_wakeup

    FiPy fipy pytrack deepsleep wakeup
    2
    0 Votes
    2 Posts
    417 Views
    S
    Found a start of an answer here: https://forum.pycom.io/topic/3624/machine-pin_deepsleep_wakeup-function-is-not-working-in-lopy4-firmware-version-1-19-0-b2 Link to developemtn documentation on github: https://github.com/pycom/pycom-documentation/tree/development_release/firmwareapi/pycom/machine The method is renamed to pin_sleep_wakeup()
  • Can't flash Fipy LTE modem.

    Issues & Bugs fipy modem
    11
    0 Votes
    11 Posts
    1k Views
    M
    So I think I found my problem As I said in another post the problem wasn't in the software, but hardware. I don't use a expansion board, I use a ttl converter like this one https://www.ebay.com/itm/5V-3-3V-FTDI-FT232RL-USB-to-TTL-Serial-Converter-Adapter-Module-Arduino-Mini-Hot/182736917146 With this converter 3.3V is not enough to power on stably the board, so, I used it in 5V mode, but it seem that 5v for serial communication is ok for the python REPL, but have problem when flashing the modem or use the LTE modem. Finally, I changed my design by using another 5v power source, and use the ttl converter un 3v3 mode with common ground. And then it just works fine ;)
  • 0 Votes
    4 Posts
    686 Views
    M
    Hello @iwahdan, I put the LoRa Init after the LTE connection and it works now ! Thank you. Best Regards, Malo
  • Fipy issues with IF statements

    FiPy fipy coding
    7
    0 Votes
    7 Posts
    669 Views
    D
    @dnear1 said in Fipy issues with IF statements: ') Cleaned up and comments added import os import math from machine import UART uart = UART(1, 9600) # init with given baudrate uart.init(9600, bits=8, parity=None, stop=1) # init with given parameters #while True: # data = uart.readall() # if data is not None: # print(data) while 1: data = uart.readall()# get everything from the serial buffer if data is not None:#make sure it's not an empty buffer bytestream=data.split(b'BM')[1][0:31]# HPMA sends 32 byte packets that start with \x42\x4D ('BM') if len(bytestream)==30:#check that we actually got 30 bytes (excluding the data we split out) if bytestream[0:2]==b'\x00\x1c':#HPMA packet is always 28 data bytes(excluding start header and checksum) checksum=143#since split command removed the \x42\x4D, add them back to get correct checksum validated=0 for i in range(0,28): checksum+=bytestream[i]#cycle thru the data values and add them up validated=int(bytestream[28])*256+int(bytestream[29])#read checksum bytes from packet and make them a 2-byte integer if checksum==validated:# both values should match, else we have a corrupt packet pm25=int(bytestream[4])*256+int(bytestream[5])#these two bytes represent the particulate detected that's 2.5um large pm10=int(bytestream[6])*256+int(bytestream[7])#these two bytes represent the particulate detected that's 10um large print('pm2.5 = ',pm25) print('pm10 = ',pm10) else: print('checksum failed') else: print('invalid packet length') else: print('incomplete packet')
  • FiPy/Pytrack losing its firmware each day

    FiPy fipy pytrack
    3
    0 Votes
    3 Posts
    433 Views
    D
    Hey Thanks for the reply. 1 - executing dfu-util-static.exe -D pytrack.dfu solves my problem each time without doing anything else before hand 2 - I only checked this in Device Manager, but nothing at all changed in any window, I'll check through command line or any other method you recommend when I get back to work on Monday. 3 - This is actually an assumption based on the fact that executing dfu-util-static.exe -D pytrack.dfu fixes the problem. I'm not sure how I could check this, maybe I'll try a different FiPy on top of the Pytrack although I don't see how that would change anything, I'll try whatever you think can verify this. I'm planning on putting out 20 + units for static tests in the coming weeks so I'll get a better idea of whats happening but it seems to only effect this particular board so I haven't been too worried.
  • 0 Votes
    7 Posts
    830 Views
    R
    @robert-hh Thanks for your reply, you have true. I searched components during the starting. And I comment this lines codes : #wlan = WLAN() #wlan.deinit() #bt = Bluetooth() #bt.deinit() #serveur_ftp = Server() #serveur_ftp.deinit() I don't test with each line only, but now it's working. I have fix coordinate when the Fipy powered by Lipo.
  • Wi-Fi functions

    Firmware wifi wipy fipy esp32 enhancement
    7
    0 Votes
    7 Posts
    795 Views
    G
    @ingframin Did you manage to modify the firmware? I would like to have a Wi-Fi advertising per 100 milliseconds; default LoPy-4 seem to send an advertising only if requested by a station.
  • access TX/RX on fipy + pytrack :

    FiPy fipy connectors uart
    4
    0 Votes
    4 Posts
    634 Views
    robert-hhR
    @testos Yes, you need to connect to the external IO header below the fipy. And you have to specify these Pins, when you open the UART, most likely UART1. On a Fipy, two of the three UARTs are already used by the firmware UART0 and maybe UART2. You have to try.
  • 0 Votes
    25 Posts
    4k Views
    S
    @robert-hh OK, I set up some code to try this out, several timers at different periods and several threads including one to start LTE, send an SMS and then deinit. From what I can see, the timers do NOT get interupted by the LTE device. It seems the timer counts are retained and dumped to REPL as soon as possible (buffered apparently). There is some corruption/mixup of REPL lines but all the timer flags are there I will investigate a bit further and see if I can use this to my advantage. One thread/timer I will need will be at 11uS preferably, so as it is too fast to capture by eye, I'll have to write to a file to a file to evaluate any impact by the LTE device. Biggest constraint might be the actual time to write to disk. A FIFO data buffer is probably a good solution - some work to do there. The test code was pretty rough and ready so its needs a lot of refinement to be truly useful as a valid test.
  • Send Text File from Webserver to Lopy?

    LoPy lopy fipy wipy http https
    2
    0 Votes
    2 Posts
    358 Views
    C
    @wolli01 Depends on a lot of circumstances. Use WiFi and simply upload the file using FTP. LoRa will need more code and tiny files.
  • UART configuration

    Firmware fipy
    1
    0 Votes
    1 Posts
    396 Views
    No one has replied
  • nb-iot on t-mobile in NL

    Discussion fipy nb-iot connect issues connection connect
    12
    0 Votes
    12 Posts
    1k Views
    robert-hhR
    @eric-waai These settings should be fine then.
  • Copy Files to Flash

    LoPy wipy 3.0 lopy4 fipy copy file
    12
    0 Votes
    12 Posts
    1k Views
    W
    @robert-hh Top
  • GPy or FiPy using LTE in the US

    GPy lte gpy fipy usa
    2
    0 Votes
    2 Posts
    446 Views
    C
    Hi @kevin, From the Southern of Sweden - via Telia's NB-IOT Network - I get this: >>> send_at_cmd_pretty('AT+SQNHPLMN?') +SQNHPLMN: "23820","23820","23820" OK >>> and for you who would like to look it up: http://www.numberportabilitylookup.com/networks?s=
  • 0 Votes
    20 Posts
    2k Views
    L
    @robert-hh said in no can connect to vodafone spain NB-IOT with FIPY: The second number is the bit error rate (ber), whic is not know beforehand. So it means now the device detects is a proper signal. then. then, now I understand that it had a good signal, but the fipy was trying to attach herself all night, and she did not succeed. it's just waiting, or we should give it the command to attach repeatedly ... On the other hand, I'll check the commands you indicate