Newbie How to get Encoder readings and change analog output using Mesa 5i20 + 7i33?


Results 1 to 11 of 11

Thread: How to get Encoder readings and change analog output using Mesa 5i20 + 7i33?

  1. #1
    Registered
    Join Date
    Sep 2010
    Location
    singapore
    Posts
    9
    Downloads
    0
    Uploads
    0

    Default How to get Encoder readings and change analog output using Mesa 5i20 + 7i33?

    Hi, I am new to Ubuntu/Linux. Currently, I am trying to test out my own controller on a Brushed DC Motor. So I borrowed a Mesa 5i20 and a 7i33 Quad Servo Driver card from a friend and attached it to my PC and a DC motor at port 0 of the 7i33.

    However, I do not know how can I acquire the encoder readings nor write output analog in Ubuntu. Any guidance would be appreciated. Thanks!

    ~BQ

    Similar Threads:


  2. #2
    Member samco's Avatar
    Join Date
    Jul 2003
    Posts
    1754
    Downloads
    2
    Uploads
    0

    Default

    take a look a the hm2-servo servo config within the emc2 sampe configs.

    It is a 3 axis config using encoder feedback and PID

    sam



  3. #3
    Registered
    Join Date
    Sep 2010
    Location
    singapore
    Posts
    9
    Downloads
    0
    Uploads
    0

    Default

    Thanks sam. So theoretically i can modify hm2-servo servo config and change their PID controller to my own?



  4. #4
    Member samco's Avatar
    Join Date
    Jul 2003
    Posts
    1754
    Downloads
    2
    Uploads
    0

    Default

    theoretically... What do you mean - change their pid controller to your own?

    sam



  5. #5
    Registered
    Join Date
    Sep 2010
    Location
    singapore
    Posts
    9
    Downloads
    0
    Uploads
    0

    Default

    As in remove their PID controller and implement my fuzzy controller.



  6. #6
    Registered
    Join Date
    Apr 2005
    Location
    finland
    Posts
    263
    Downloads
    0
    Uploads
    0

    Default

    with the old-school hostmot-4 fpga firmware I was using this kind of pyVCP test panel to try everything out without PID loops and without EMC2:
    http://www.anderswallin.net/2007/09/...-4-test-panel/

    it may or may not be easily adaptable to the hostmot2 FPGA firmware/driver which is now probably the right choice with the latest EMC2.

    Anders



  7. #7
    Registered
    Join Date
    Sep 2010
    Location
    singapore
    Posts
    9
    Downloads
    0
    Uploads
    0

    Default

    Thank you Andy. This seem useful . I was wondering where can i add in my C code inside this environment?



  8. #8
    Registered
    Join Date
    Apr 2005
    Location
    finland
    Posts
    263
    Downloads
    0
    Uploads
    0

    Default

    Quote Originally Posted by Shen Bingquan View Post
    Thank you Andy. This seem useful . I was wondering where can i add in my C code inside this environment?
    comp is a tool for writing your own realtime components in a C-like language. you could then replace the standard pid-component with your own component.

    see: http://www.linuxcnc.org/docs/2.4/html/hal_comp.html



  9. #9
    Member samco's Avatar
    Join Date
    Jul 2003
    Posts
    1754
    Downloads
    2
    Uploads
    0

    Default

    Sounds neat - if you could also add in auto-tuning.....

    sam


    Quote Originally Posted by Shen Bingquan View Post
    Thank you Andy. This seem useful . I was wondering where can i add in my C code inside this environment?




  10. #10
    Registered
    Join Date
    Sep 2010
    Location
    singapore
    Posts
    9
    Downloads
    0
    Uploads
    0

    Default

    Hi Andy,

    Got one question regarding the pyVCP test panel you linked me earlier. It worked properly, but there are still some problems after some editing.

    Being reading up on the codes and I have shorten the XML and HAL files by deleting parts of other motors (etc, "linkpp iotest.enc1 m5i20.0.enc-02-position") .

    But the HALmeter still shows those respective PINs and Parameters for other motors 01 02 03. Where are all these parameters define in? And how can I change them? And how can I add other parameters?

    I am thinking 'loadrt hal_m5i20 loadFpga=1 dacRate=16666' define all those, but where can find this file and edit it?

    Moreover, i cant seem to just add another thread by "addf m5i20.0.digital-in-read tt" into the HAL file.

    ~BQ



  11. #11
    Member
    Join Date
    Nov 2005
    Location
    Canada
    Posts
    496
    Downloads
    0
    Uploads
    0

    Default

    If you just want to do open loop testing you can use pncconf.
    Though it sounds like you wish to test your component....



Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


About CNCzone.com

    We are the largest and most active discussion forum for manufacturing industry. The site is 100% free to join and use, so join today!

Follow us on


Our Brands

How to get Encoder readings and change analog output using Mesa 5i20 + 7i33?

How to get Encoder readings and change analog output using Mesa 5i20 + 7i33?