Description
So I am thrashing away trying to get MODBUS communication working...and it is not...yet :( I have one BIG script with all of the modbus_tk python library in it to compensate for the inability to import other python modules.
I also added some LED blinking to see if things are actually working. Initially they didn't blink so I commented out all the MODBUS related code (numerous classes, function definitions, etc.), re-uploaded the script and they started to blink again. Eventually through trial and error I figured out it was this piece of code which was causing things to break (specifically line 3):
1 _hooks = {}
2 def install_hook(name, fct):
3 _hooks[name].append(fct)
This got me thinking:
How is one supposed to know when there is a compilation error after uploading a script and what the error is?
P.S. Until importing is working and the python standard libraries are better represented it is looking more feasible to implement the MODBUS stuff in C and call it from python. I'll give that a bash over the next few days.