Close

I2C working!!!! yeah

A project log for Smart Motor Driver for Robotics

This motor driver is able to control a motor using PID by I2C. Taking precise control of a motor have never been so easy.

danny-frDanny FR 07/25/2018 at 04:363 Comments

It has been a hard time for me, so I didn't have the mood to do anything for a few days. But that is over.

I proudly present you the first successful I2C slave communication with the motor driver (SAMI) and Arduino :) Spoiler alert: an arduino library will be available to easy use of SAMI.

The next step will be create a register map with all necessary data to take control over the controller.

However some new components are delayed so I can't move forward until they came on the mail.

See you in a few days, thanks for reading.

Discussions

Jarrett wrote 07/25/2018 at 17:58 point

Nice!

I notice that your PCB doesn't have pull-up resistors on the I2C line. I think Microchip recommends them, and can't really rely on internal pull-ups. Just something to keep in mind if you notice reliability issues!

I'm watching this project with interest, I might eventually pick up a few of these :)

  Are you sure? yes | no

Danny FR wrote 07/25/2018 at 18:53 point

Thanks

Yes, that is true. Pull-ups are required for I2C operation because SCL and SDA pins are now open-drain. I don't rely on internal weak pull-ups too, however they are useful for testing or applications in low noise environments. The reason I decide to not include an external strong pull-up resistor on board is because they can lead to some problems, connecting multiple I2C devices  (each one with strong pull-ups) on the same bus will easily source more current that the circuit can sink. Making communication fail, it's easier to add the external resistors when needed than remove them from the board.  When using internal pull-ups this doesn't happen, they can only provide  140 uA typically and can be disabled by software (I will add that function in the configuration, thanks for the tip). So they shouldn't make any problem, even in a highly populated bus. 

I really appreciate your feedback :)  

Cool!!! They will be available for sale when done ;)

  Are you sure? yes | no

Danny FR wrote 12/30/2018 at 02:27 point

Hey, this project is now available for purchase. If you use the coupon GETSAMI you can get 10% off until january 10. Check it here: https://www.tindie.com/products/15726/

  Are you sure? yes | no