Code: Select all
import pyb
import math
while True:
adcint = pyb.ADC(pyb.Pin('X4')).read()
print("Analog reading of port X4 = %f V" % (adcint*3.3/4095))
pyb.delay(50)
Code: Select all
import pyb
import math
while True:
adcint = pyb.ADC(pyb.Pin('X4')).read()
print("Analog reading of port X4 = %f V" % (adcint*3.3/4095))
pyb.delay(50)
Thanks. My suggestion was to compare different MicroPython boards with respect capability to load modules.pythoncoder wrote:@rcolistete This occurs when the compiler runs out of RAM: when you import a .py module the compiler running on the board converts the text file to bytecode, which is then run by the Python VM.