Calling function within other files and order of loading..
-
I have created different py files for different functions eg bluetooth.py wifi.py etc
When boot.py and main.py load...do the other files get loaded if not when do they get loaded? From boot.py i'm trying to load a function within bluetooth.py but i get error NameError: name '_bluetooth_scan' is not defined
-
thanks, i'm reading the python resource online
-
@misterlisty Modules are loaded with the "import name_of_module" statement. After that, functions and classes arfe added to the namespace and can be used. You can issue the import statement at the REPL prompt interactively, of in your main script and use it then.
This is the typical Python behaviour. I recommend getting lessons or reading a suitable book on Python.