Makeblock-official / mDrawBot

mDrawbot is a four-in-one drawing robotic kit, you can assembly into 4 different configuration drawing robots, learn more from Makeblock official website
http://www.makeblock.com
GNU General Public License v3.0
201 stars 149 forks source link

remember position #9

Closed schmurfy closed 2 years ago

schmurfy commented 9 years ago

Each time you connect to the mScara arm the IDE consider the arm is in the Home position, this is really annoying, surely there must be a way when it connect to retrieve the current position from the controller (Arduino/Orion) so that we are not required to return to home every time.

Cration commented 9 years ago

Each time you connect to mDrawBot, it will restart. There's no position feedback sensors, just two stepper motors on it. So I think it's really improbable to do that. What if you manually move the position of the robot arm?

schmurfy commented 9 years ago

I was not thinking about any sensor but when your computer is connected to the controller you don't have to return it to home before every command right ? Why the controller could not keep that position in memory to send it back to the computer when connected ?

I am not talking about powering off, just disconnect and reconnect the USB cable and you have to move back the arm to the home position by hand (after removing the power since you can't move them otherwise), really annoying.

By going further I think the position could be stored in the eeprom but that's another story.

waldschip commented 9 years ago

the problem is that the eeprom have a life cycle, i think it would be better mount angular sensor to the joints

schmurfy commented 9 years ago

@Cration I misunderstood the part about the restart, you mean the controller restarts when you connect to the computer ? If so why ? I have not looked at the code too much for now but the controller code looks "dumb" (I don't mean easy but I mean it does not take any action by itself), it takes commands as inputs and acts accordingly, right ?

If that is the case I don't understand why it would need to reboot unless the power is removed or you want to reflash it.

Cration commented 9 years ago

@schmurfy Because they connect the DTR pin to the reset pin of MCU with a capacity on PCB. It is the same as Arduino UNO. I think that's for downloading the firmware with Arduino IDE.

schmurfy commented 9 years ago

ok, I missed that :p if I prevent the reset on connect will the IDE be able to get back the current position from the controller ?