Machsupport Forum

Mach Discussion => Brains Development => Topic started by: mundotronic on October 04, 2011, 04:01:54 PM

Title: "MPG1 Count" and "MPG TickCount" ... which is the function of each?
Post by: mundotronic on October 04, 2011, 04:01:54 PM
Hello All! :D

I am writing from Argentina and above all thanks for letting me participate in this wonderful forum.

I have developed my own Modbus controller board and it works very well, I call it the "MTBus1408" and has 14 inputs and 8 outputs.

One of the inputs is designed to connect a MPG (2-channel incremental encoder without index) and here comes my question ...

1- What is the function of "MPG Count" and "TickCount MPG"?
2- What values ​​can receive them?
3- 16-bit integers?

I made a simple brain with "MPG Count" only getting a 16-bit value from an Input Register and moving the selected axis work but intermittently and without meaning, sometimes increases and sometimes decreases position but turn the MPG in the same direction.

I leave a video demonstrating my Modbus controller board (Spanish).

http://www.youtube.com/v/LiZ4gDcGlFs

I hope somebody guidance on this so that the motion of each axis to be continuous.

Thank you and good Millings!

PD: Sorry, I'm speak a very poor english ::)
Title: Re: "MPG1 Count" and "MPG TickCount" ... which is the function of each?
Post by: poppabear on October 05, 2011, 07:34:34 PM
MPG Tick is for your hardware to send in the value of a timer, this timer reference allows mach 3 to see how far you have moved in counts an MPG so It can know your velocity.

MPG Count is for the actual counts that your encoders from your hardware send into mach.
Title: Re: "MPG1 Count" and "MPG TickCount" ... which is the function of each?
Post by: mundotronic on October 06, 2011, 05:12:22 PM
Hello poppabear, thanks for reply.

See if I understand ....

"MPG TickCount" receives the time in milliseconds between MPG ticks and "MPG Count" receives a positive or negative value depending on the direction of rotation.

This is so?.

Sorry to ask so many questions but I want to understand.

Thanks again.