Search found 6 matches

by walli_90
Tue Feb 19, 2019 7:57 am
Forum: The MicroPython pyboard
Topic: AttributeError: 'module' object has no attribute 'Pin'
Replies: 10
Views: 333

Re: AttributeError: 'module' object has no attribute 'Pin'

I'd like to know, how much RAM I have left, so what I do is: (...) Thanks. That is really helpful. So it is likely that the error came from the module imports in main.py? But why does it work now? Since I rewrote the functions everything behaves like expected and I have not touched the imports in m...
by walli_90
Fri Feb 15, 2019 8:31 am
Forum: The MicroPython pyboard
Topic: AttributeError: 'module' object has no attribute 'Pin'
Replies: 10
Views: 333

Re: AttributeError: 'module' object has no attribute 'Pin'

I rewrote the whole program starting from last week's master. Now everything works and I have no idea where the error was. :|

Only out of curiosity... May it be, that the pyboard fails to load modules, if there is an excessive folder sturcture on the flash?
by walli_90
Wed Feb 13, 2019 7:05 am
Forum: The MicroPython pyboard
Topic: AttributeError: 'module' object has no attribute 'Pin'
Replies: 10
Views: 333

Re: AttributeError: 'module' object has no attribute 'Pin'

just for our peace of mind: comment out the Oled Driver line and try. Remove all other unneeded imports and parts from the code, piece by piece, and try That is basically what I tried on monday for almost three hours. Commented out all unnecessary imports Removed the new functions one after the oth...
by walli_90
Tue Feb 12, 2019 10:34 am
Forum: The MicroPython pyboard
Topic: AttributeError: 'module' object has no attribute 'Pin'
Replies: 10
Views: 333

Re: AttributeError: 'module' object has no attribute 'Pin'

motor_driver.py ############ import pyb import utime from math import pi from oled1306 import show_lcd # Pins right motor rm_cw = pyb.Pin('Y2', pyb.Pin.OUT_PP) # Clockwise rotation rm_ccw = pyb.Pin('Y3', pyb.Pin.OUT_PP) # Counterclockwise rotation rm_pwm = pyb.Pin("Y1") # PWM signal # Pins left moto...
by walli_90
Tue Feb 12, 2019 7:14 am
Forum: The MicroPython pyboard
Topic: AttributeError: 'module' object has no attribute 'Pin'
Replies: 10
Views: 333

Re: AttributeError: 'module' object has no attribute 'Pin'

This one:

rm_cw = pyb.Pin('Y2', pyb.Pin.OUT_PP) # Clockwise rotation
by walli_90
Mon Feb 11, 2019 12:53 pm
Forum: The MicroPython pyboard
Topic: AttributeError: 'module' object has no attribute 'Pin'
Replies: 10
Views: 333

AttributeError: 'module' object has no attribute 'Pin'

Hi, I am using a pyboard as controller for two DC motors in a (not yet) autonomous robot. I wrote a module (motor_driver) containing the functions for basic movement and imported it in main.py. So I can access the console and run the functions manually. But when I call a function of motor_driver in ...