you should write in C++, making heavy use of STL and templates
03jmkasunich 07HEAD * 10infrastructure/farm-scripts/run_farm: hide some extraneous output
hi guys, i've got the number of notches on the pulleys and number of steps for 1 rev. can someone tell me how to figure out the right scale?
is there a belt or gear reduction as well?
i think i may have to run back and get one more number, but here goes....
owhite: im currently working on a dxf2gcode python converter :D
the motor had 2000 steps for 1 rev, and the pully on the motor is a 16x the belt connects it to a 60x
rugludallur: what's the plan? would it work on the command line, or are you working on some type of GUI?
owhite: both, got a 3D viewer with gui and command line
the 60x is on a shaft with a 14.5 degree 16 tooth pinion gear that meshes into the rack.
Rugludallur: is this the pythonCAD project or something else?
granville: so the only thing we need now is the teeth per inch of the rack
owhite: something else, although I use the dxf module from the pythoncad project
owhite: not sure if I will do spline to polyline though, I think that might be better done by the cad appliation saving the dxf
measuring 2 inches, it looks like 8 teeth, so i'm figuring 4 tpi. the gears for the pulley as well as the rack gear are martin gears from mcmaster carr
measured as accurately as possible - for example, if you have a six inch dial caliper, count how many teeth fit in just under 6 inches, and measure the length of that many teeth as carefully as you can
oh, do you have the mcmaster carr part number?
i'm trying to find the receipt so i can get the part number.
Rugludallur: how far along is your project?
granville: that would be perfect
owhite: been working for 2-3 days now, got parsing done, 3D viewer complete, currently outputting gcode for everything except arcs
owhite: still need to do quite a bit of testing and optimization
Rugludallur: well I'd be interested in hearing about your progress.
I gotta run.
owhite: let me get ya a screenshot from 3d :D
I got the circuit working
but I think I am sending the pulses to fast to the steper
bu the phases are fireing in order
could be - unipolar drive is very limited in speed and acceleration
that is controlled by the ini file, you can turn the values down a lot and see what happens
can I edit that live?
if it starts working turn them up slowly...
no, gotta exit from emc
granville: I'm gonna guess that you have a 16 tooth, 12 pitch gear
the outside diameter is 1.5 inches
organization isn't my strong suite, i found a few receipts but not the right one.
1.5 inches sounds about right.
whats the most precise measuring tool you have?
calipers. i was using them measuring the 8 teeth in 2 inches.
Do I turn down MAX_VELOCITY ?
measure the gear OD and width and we can compare them to the mcmaster catalog values
its at 1.2...
is that rps?
thats inches per second
ok, give me 5 minutes, the shop is 1000 feet away.
Ziegler: you are just spinning a motor with no leadscrew or other linear drive on it right now?
ok, you probably want to change the INPUT_SCALE in the AXIS_0 section of the ini file
since you don't have a screw or anything, lets work in revolutions
do you know how many steps per rev your motor is?
one sec let me find the specs (I ripped it out of a cheap scanner this morning)
in that case it might be coarser, maybe 48 per rev or something
[00:19:19] <Ziegler> http://www.tranzistoare.ro/datasheets/90/502505_DS.pdf
This is basically it.. .ecept mine had 5 wires
360 /7.5 = 48 steps/rev
so, if you set OUTPUT_SCALE to 48, then the units will be motor revs (which is reasonable when you are just playing around)
later you'd put the screw turns per inch and such into the mix as well
with scale = 48, then the 1.2 max vel is 1.2 revs per second, or 72 rpm
which your motor might do OK
the original scale value was 4000, so 1.2 velocity = 6000 RPM - no wonder it wouldnt' spin
ok, the pinion gear looks like between 1.15 and 1.17, the rack is .75x.75
thats the outside diameter?
how many teeth did you say it had - 16?
ok my input scale was 4000 but me output scale was 1
ignore output scale
oops, I told you output scale, my mistake
ohh I want to change input scale
right 16 teeth
no estop want to turn on every time I change the x value
i'm guessing it's the 6325K13
granville: those specs don't seem to match up
thats what I thought from the OD and tooth count
but that has a 1/2" face width, you said the rack is 3/4" wide
the only rack that is 3/4 x 3/4 is the 12 pitch stuff, 6295K16
but a 12 pitch 16 tooth gear has an OD of 1.500
maybe that give clearance between the plate the rack is mounted on and the pinion gear.
so, we still don't know if its 12 pitch or 16 pitch
the OD and tooth count says 16 pitch
souns like 16 pitch right?
the 12 pitch would be 1.5 inches in diameter, right?
but 16 pitch has 5.093 teeth per inch, and you said it was about 4
12 pitch has 3.819 teeth per inch, much closer to 4
stuff isn't adding up, one of those two measurements must be wrong
i may have been counting valleys insted of peaks, would that make 5 closer?
I think the diameter/tooth method is more accurate
lets assume its 16 pitch, you can confirm it some other day
(for example, count the number of teeth in _ten_ inches
ok, lets go with that and see if we come up with the scale value i had last night.
the difference between 50.9 and 38.2 is hard to miss
so, we have a 16 pitch gear, with 16 teeth
that is convenient, it means the pitch diameter is exactly 1.000 inches
so the circumfirence is pi times 1.000 = 3.1415927 inches
step gen 9 works much better
thats how far it moves with one turn
Ziegler: I thought it would
5 didnt like to go in reverse
since thats half stepping, you'll want to change the scale to 96 (96 half-steps per rev)
that's one turn of pinion gear in the rack?
3.14blahblah inches per turn of the gear
now the belt
you have 60 teeth on the big pulley?
right, it's also a martin 60x so i'm sure on that one, it was written on the side.
you guys rock
and 16 teeth on the little pulley
right, and the little one is on the motor, the big on the shaft going to the pinion gear.
so 3.75 revs of the little one for each rev of the big one
I'm gonna back up a sec
we said 3.14... inches per rev, but we really want to know revs per inch
so 1/3.14.... = 0.31831 revs per inch
at the gear
how did you get the 3.75
0,31831 revs per inch at the gear times 60/16 teeth = 1.19366 revs per inch at the motor
nevermind, you have to put a decimal in python or it does integer math.
I'm using an actual calculator ;-)
1.19366 revs per inch at the motor times 2000 steps per rev = 2387.324 steps per inch
is that what you had?
i think so.
i've got -2378.3242000000014
.3242 is enough ;-)
I think you have a Pentium bug :)
I get 2378.32414638 (on my HP calculator)
this is a fairly large router, right?
24"x24"? 48"48"? or ?
right, 5 feet by 10 feet
next step is to stretch out a measuring tape on the table, full length or close to it
set the tool just above the tape, carefully jog it one edge of the tool exactly lines up with an inch mark (maybe 4" for example)
then with feedrate set quite slow to make sure you don't miss any steps, jog exactly 1 inch, see if the tape agrees
if so, jog 10 inches, see if it agrees
if so, jog 50 inches and check again
you can use MDI for those jogs
one thing about the time it takes to do the jogs - the time should be correct regardless of whether the distance is correct or not
john, last nite he had .125" error after 35" travel, so didnt see any error at 1" travel ( if that helps)
they will take a little longer than expected because of accel/decel time, but not much
hopefully there was an error in measurement of the time - it should be a little longer than expected, f anything
after correcting the scale last night, it was moving the right time for a f1 feed rate, exactly 60 seconds.
right - what he said
it should have been the right time anyway
tomp: 1/8" in 35 = 0.003" in 1"
not likely to see that
unless it took too long due to valocity limits
right, hard for him to see
thats the reason for very long jogs when checking scaling - much more sensitive
hopefully both X and Y have the same drivetrain??
I'd imagine a beefier sprocket on one axis
if not, gotta repeat the measurements and calcs for the other axis
x and y are the same. z is a leadscrew
i've got the scale set to 40000 on z and that seems to be right.
2000 steps/rev, 2x or 4x gearing, and 10 or 20 TPI screw?
no gearing on the z, the motor has a coupling onto a small leadscrew, not sure the size. but 20 tpi sounds right given the 40,000 scale value.
of course, I meant to say gearing + 5 or 10 TPI screw - oh well ;)
probalby 1/4-20 threaded rod
this could be a mechanical problem with the big pulleys, they are held in place with set screws and i did catch them slipping once, i ground a flat place on the shaft for them and thought that was fixed, maybe not.
once i get this one working, i'm thinging about building joe's 2006 project from cnczone, it looks like a fun project!
put the setscrew against a key in a keyway :-)
that would be a better idea, that's the way i have the one on the motor shaft but it already had keyway. i guess i should pull the shafts and mill a keyway into them to fix this for good.
just kidding, you should be able to snug it up enuf for this test
does espn use emc to control that camera they have on the tripod cables over football fields?
but some mark to indicate slippage is ez
there was some suspended hexapod ( cable hexapod) work done, but dunno 'bout espn
i saw the cable hexapod setup that's what made me wonder.
look at alex's tri-pod
one other thing, when i was doing rapid moves last night, the z axis move was interpolated with the x and y. i thought all g00 moves should move z axis first then x,y. is there a setting for this?
hmm, i think g00 moves all 3 at once but not interpolated ( 1 for x 2 for y, 10 for z etc ), not sequential
in g00 the short move gets done early
ok they were moving all at once, don't know about the speed. i know that on my bridgeport the z moves 1st then it make x/y. boss9 is still running so i haven't converted it to emc yet, but i wish it was emc, i hate downloading to that thing!
oh, the bport is doing a 'sfety' thing, it 'gets clear, then over bombsite...
right, shouldn't emc have the same safety?
you can program it in 2 lines as you wish, or talk to your friendly post-processor ;-)
i make macros for other systems that go to clearnace plane first, like you describe.
ok, can you tell me about limit switches, i have the switches, but haven't wired them to the parallel port yet. can i make emc go hit each switch back of n inches, and set 0?
and it wont be safe for the horizontal mill:-) my ,macros get info from a global 'tool axis', so can use tombstones
no - espn does not use EMC
at least, SkyCam doesn't - I know that for sure
i guess it's too cheap for them ;0
they're pretty cheap, actually ;)
look at Hektor, the spray can graphitti robot
simple, 1 polar angle and a radius... spray can suspended from cogged cables , painting pictures on a wall
got the videos?
comes in a briefcase, way cool
it's alex's tripod with 3rd leg being gravity
sorry, about limit swx...
yeah, i was watching one of those videos too, too cool!
yes... i'm looking for the limit swx back off & set ref pt info...
[01:12:04] <tomp> http://wiki.linuxcnc.org/cgi-bin/emcinfo.pl?Home_Switches_With_EMC
how do you start the homing seq once you have the limit switches connected?
it varies between the GUIs
but in general it'll be a button, keystroke or menu item
in tkemc, after removing estop & applying mc power, click a DRO (say X), then click 'home'
there is a home button but it zero's the axis, does it work different after you have limit switches configured?
yes, I think so
ok i'll save that for another day.
when you have no homing sequence/switches defined, it can't possibly find home, so it just assumes that you know what you're doing
ok that makes sense
tomp, what about max accel and maxvel, and maxaccel?
i've got max-accel at 20, stepgen-maxvel at 4.18 and stepgen-maxaccel at 21.0
[01:28:44] <cradek> http://linuxcnc.org/docs/EMC2_User_Manual.pdf
oops, too slow, that's the homing information
looks like that wiki page is old and doesn't describe all the features of emc2
i put negatives on all my scale values to make each axis go the right direction, i found this in the emc manual but not in the emc2 manual, is this still proper in emc2?
tomp i guess you are saying page 70 for velocity and acceleration, are there ways to calculate the right numbers for these?
trial and error - they depend on your motors, gearing, drives, etc
gradually increase speed until you start to lose steps, then back off by about 10-20%
then do the same for accel
what about an acceptable range for each?
faster is better (unless you get to a point where you think your machine is too fast)
since the feedrate specifies the speed, does this only control how fast it gets to full speed?
use G0 for that testing
G0 will run at max speed, not feedrate
accel controls how fast it gets to top speed
the ini file is the set of constraints under which your machine works properly. Once it's set, no gcode will cause the machine to try to exceed them
is it OK if I write/paste 10 lines into this conversation ?
so if you program F9999 and your ini has 1 inch/sec max velocity, you get F60 instead
try 5 at a time
pastebin it is
grabville: sorry was away.. the machine tells you what these parms can be, you only record the info ;-)
[01:44:34] <Rugludallur> http://pastebin.ca/259054
so 1.2 for max velocity is the same as a limit of f80?
If you are interested in dxf to gcode converter I would really like comments on that :D
1.2 inches per second * 60 seconds per minute = 72 inches per minute
ok, should have used a calculator!
Rugludallur: I'm having a hard time understanding this
cradek: ok, let me walk you through the logic
Rugludallur: I don't understand encapsulation or toolpath(object)
I think I need an overview - what's the input like and how does it represent the toolpath to be cut?
cradek: toolpath is any number of arcs/lines/polylines that have a common start/end
ok a closed path is a toolpath, what's an object?
cradek: a toolpath can be closed or not closed, but when a toolpath is 100% within the boundaries of another toolpath it is "encapsulated"
ok, it's not clear to me what that means in the 3d case
let's back up a sec - what's a 3d toolpath look like?
cradek: it's a way for me to determine on which side the tool offset should be applied, so in the cad program you define a solid or a curve network which forms a 3d object
ok so they're not toolpaths really, they're part outlines around which the toolpath goes
cradek: Anything that hat arcs/lines/polylines that can be "joined" to form a 3d object
cradek: yes, well they can be on both outside and inside
cradek: in the case of laser or plasma the toolpath is quite often on the inside
ok so you will make one pass of the tool inside or outside of each of the closed "loops"?
ok I see now - you're worrying so much about the order because you're cutting out parts
cradek: yes, and sometimes you cut out a part from a part from a part .....
sounds like this is really for a laser/plasma type machine only
cradek: the 2d is
ok I understand the goals now I think
oh wait, what's the 3d then?
3d is for milling/turning but I have not given that as much thought
as I don't have any practical experience with milling or cnc turning
let's talk about the 2d case then
why is it important to cut the smallest area first?
because that piece might fall out of the sheet once its cut
if you cut a big one loose, then try to cut the piece inside it.....
that's the encapsulation problem though isn't it?
yes and there is more, it's also to determine on which side the tool offsets should be applied
I'm thinking of ( o O ) where () is a big circle
why do you need to cut the o before the O?
dont need to
ok that's in #2a
you only need to cut the "parts within a part" before you cut the "part"
right, he's calling that encapsulation
theres some other funky stuff to do there as well, part avoidance for example
robin_sz: hmm, could you please explain ?
you should arrange the G0 moves between one part and the next so as not to pass over already cut parts, in case one has tipped up
they may not fall out cleanly?
well, ideally, you dont want them to fall out at all
robin_dz: Got ya, hmm it's not always possible to avoid that but it can be kept to a minimum
I'm worried about #14
if I program a O shape, how do you know if I want the hole or the O that dimension?
on the laser, we put microjoints in .. cut for say, 300mm, stop, go back 20mm, weld the joint over for 2mm, move forward 10mm start cutting again
you have to let the user specify it
an O is always done from the outside
My thought there is that if you want a hole cut in something you have to model what you want to cut the hole in
so if you want a hole in a plate you have to model the plate
the sheet is always the scrap
that makes sense
theres loads and loads of nesting software already that does this
this really is going to be very special purpose it sounds like
no, its very very common in the laser/plasma/oxy-fuel cutting industry
it all we do, all day every day :)
yes but for milling/turning is another ting
that's special purpose to me, the guy with a milling machine
oh with a mill?
cradek: if you see things you want different for milling pls let me know
the signmaking boys do this all day with routers
yeah this is special purpose software for cutting flat stuff
cradek: btw this is all within a layer
Rugludallur, you have tried sheetcam?
there are mills, lathes, and everything else ;-)
robin_dz: I have, don't like the output
robin_sz: I'm sure the idea here is to make free software to do this
(from a machinists view of the world)
jmkasunich: mills, lathes, and other stuff I don't have
Rugludallur, the output is completely configureable from the Lua macros
robin_sz: already have the parser and most of the gcode output, even have a 3d viewer for it -> http://imagebin.org/6655
parser for ?
Rugludallur: the hard part is going to be determing encapsulation, and then the harder part still will be the tool offsetting
or are you going to let emc do the offset?
cradek: that was the idea
ok then the hard part will be figuring out valid entry moves :-)
coo, so you nest this in your CAD package and this tool will generate gcode around it?
and if you're cutting concave corners you will have to add appropriate fillet arcs
robin_dz: it's all python so can be run as plugin or on it's own
to do the fillet arcs, your program has to know the approximate tool diameter
cradek: provide a tooltable in the same format as EMC uses ?
Rugludallur, how do you go about positioning the start point?
you want to start off the path for blowout don't you?
and deciding where on the profile is a very manual thing
robin_dz: yup, lead in and start with a pierce
ive not seen any software that gets it right more than 10% of the time
Since I already know what is inside of part and what is outside the rest is just a matter of finding the shortest possible combo of moves
I recommend you optimize the path last :-)
some parts you want the lead in on a corner ... some you know which is the edge that is going to get welded, or wont be seen, and you put the leadin there
the traveling salesman problem is well known because it's hard
if cutting outside, it seems like starting on a convex corner would be good -- but cutting inside, you may not have any
thats the normal way, generate each part as a subroutine, then link them up in some order, allow the user to reconfigure the order if they want
I meant worry about writing that feature last
cradek: the traveling salesman problem is only hard if you want the absolute best answer
(jepler and I have done some work on it that might help you)
its not to hard to get a very good answer
jmkasunich, im getting real busy now :)
jmkasunich: harder than you think I bet
jmkasunich, just taken on a 2nd factory to do the fabrication work, 3 more staff :)
depends on how good an answer you want
if you get within 5-10% of the absolute best path, thats not to bad
yes, and that's pretty darn hard
ok, I'll take your word for it (for now)
But it's not that many combinations for 2d work
in anyt real situation, the cut speed is at least 10x slower than the G0 speed, so the difference between a good and a poor optimization solution is actually not really important
sometimes the order the user drew the paths is pretty decent, and better than you can get with bad algorithms (like cut the nearest thing next)
just working from the left hand end of the sheet up to tthe right hand end is not a bad plan either
if the patterns are closed, there are only two orders - counterclockwise and clockwise
and you usually finish each part where you started it
no he's talking about minimizing the jog time between a bunch of closed paths
you said something about the order in which the user drew _the_ path, I thought you were talking about a single part
(it's exactly TSP because the closed paths are irrelevant and you're traveling between points)
oh I see
I meant "paths"
the user didn't draw way over here and then way over there, because he doesn't like to zoom around so much
the user might have used block copy to make 10 of a particular part, in a 2x5 array
(this is the ordering REALIZE gives you by chance)
and some users (like cradek) are carefull about where curves start and end (to be able to export directly to g-code)
true, and "over then down" isn't a bad solution
this is bringing back memories
at least 16-18 years ago I did some optimization for a NC punch press
Rugludallur: (and which direction the loops go)
which is also the TSP, there are no individual part paths, just locations for punch hits
you don't care about loop direction do you
routers and mills only go one way
so does plasma
plasma swirl causes left hand cut to be 90° while right hand is 87 or so
on decent torches that is
so you may have to juggle the closed paths around
? same in australia?
and you get ore dross on one edge than the other
if you draw a path tracing around the minimum spanning tree, you trace each edge twice and visit all points, so the TSP weight is less than twice the MST weight.
this is the algorithm jepler and I used
[02:24:09] <cradek> http://www.ics.uci.edu/~eppstein/161/960206.html
you know you have an answer with no worse than 2x the best distance
thanks: I will take a look tomorrow when Im rested
plasma is a really speciallised CNC ... a bit liek wire EDM and lathe, it has its own peculiar requirements
Rugludallur: your design looks good to me, but you have some hardish problems coming up :-)
Rugludallur: I think the 3d case is not at all well defined yet (like you said)
cradek: well, if I get a good version 1 up im happy
cradek: If you got any great ideas for the 3d stuff I would really like to hear them
it's an entirely different problem
cradek: from what I gathered you put each z movement in a new layer in your program
I don't see how you can do anything more complex than 2.5d by reading dxf
no, each layer is a tool
z depths are just depths
cradek: sorry, yes (my mistake)
REALIZE is very much just 2.5d
cradek: im still working with dxf 1.2 though, I have not taken a look at the newer formats
the entry plunges are particularly bad (on my machine) and I usually doctor the gcode
but to get a nasty line/arc/line/arc/arc/line thing out of cad into gcode, it's great
yup, I can imagine
what kind of radius can you get on a concave corner?
depends on amperage, which again depends on thickness
3mm material I can probably get down to .5mm radiant
sounds like it will be hard to decide what radius of fillet arcs are needed
cradek: each amperage setting gets a tool in the tool table
cradek: with standoff height and radius
cradek: and a seperate tool for the pierc/gauge which is only called when starting a cut
cradek: seperate radius and standoff height
oh you pierce and then change "tools"?
cradek: that was the idea, have not tried it though
changing tools causes motion to stop
I figured you would want to pierce and then cut to the edge then around, without stopping
isn't piercing done while stopped anyway?
cradek: well there is a pierce delay in any case but ..
so might not matter, will have to test it
have you looked at energy (tool)tables for emc? (i'm looking at sink edm)
what does that mean?
the energy changes so i/o chgs
tomp has been thinking the same I have, making a tool table with the amperage values
you have the loaded tool number in hal so you could do any number of things
and some interface/sync is needed
yes hal can do it
cradek: regarding the 3d stuff, I think before I start that I will go read all the new dxf specs and see what kind of 3d support is in
Just this once .. here's the log: http://www.linuxcnc.org/irc/irc.freenode.net:6667/emc/2006-11-27.txt
yeah I have never tried to use anything newer than 3dfaces
cradek: I know there is some solids stuff in there and secondary stuff but I don't know how extensive
3dfaces are those four pointed triangles :-)
cradek: isn't a 3d face just a polygon ?
just defining the piece you mill/turn from as a solid would enable an application to do some pretty nifty 3d toolpathing
For lathes that and a 2d cross section should be all you need in combo with the tool table
I've written some of that - it's not very good
for a lathe I can sure see it
milling is a whole lot harder, and once you start talking 5 axis ,, eeek
you can sure represent a simple lathe part in 2 dimensions
get's tricky when you got a milling turret though :P
cradek: have you thought about using two dxf's as a combo for a 3d object '
like 2 paths ( upper & lower) for wedm?
I think using flag dxfs for 3d is pretty much the wrong approach
cradek: that's one of the things I thought about for milling, exporting each view on it's own and joining
cradek: ok, any thoughts for a good inter-exchange format ?
of 3d geometry? there are lots I'm sure but I don't know which is "best"
cradek: ok, i'll save that for a later date :)
Im off to sleep (almost 3am), good nigh
me too , thanks all
thanks afain for all the help
jmkasunich is now known as jmk-away
Jymm is now known as Jymmmmmmmmmm
Jymmmmmmmmmm is now known as Jymmm
SWPadnos you alive?
Just this once .. here's the log: http://www.linuxcnc.org/irc/irc.freenode.net:6667/emc/2006-11-27.txt
that doesn't bode well
lunch time :D
already ate lunch
I need caffeine.
im drawings stuff today
chasing people, around :)
:P im off for lunch, see you in a bit
Just this once .. here's the log: http://www.linuxcnc.org/irc/irc.freenode.net:6667/emc/2006-11-27.txt
looks like I missed all the action
can you tell me who wrote the hal module...was this a fsmlabs work?
which hal module?
or the entire HAL framework?
hal...harvare abstrac layer
oh, the entire framework, and not an induvidual module?
i thought this is a module
you might be better off asking one of the devs, iirc jmk did work on that, though they probably all know where it came from
in HAL there are seperate modules that do certain tasks
(counter, quadrature input and so on)
i was wondering, why this hal support only 6 steper motors
why not more
you could probably add support for more without too much trouble, at least that's what I seem to remember them saying.
in most applications you don't need more than six motors
HAL was written by the EMC2 team but mostly by John Kasunich
looks like my guess^W memory was correct :D
if there is not much trubble, why they did not make support for more of them...i would like to make a cnc machine that automaticljy changes the tools and workpieces.
and i am running out of free axes
there is support for 8 motors in all of HAL - you should not use axes for a tool changer
the tool changer can be done in HAL and classicladder
have a look at the demo-mazak configuration in CVS for a nontrivial tool changer setup
ok, thank you
adding more than 8 joints to HAL would be easy if you need them (say, more than 8 stepgens or PIDs) but adding more than 6 to the interpreter and motion controller would be very hard
support for more than 8 'freqgen' or 'stepgen' can be done by recompiling. The "step_type" array has to be declared with a fixed size, and 8 was the size that was chosen.
if you need to increase this limit, there is information on building emc2 from source on our wiki
right, thanks jepler
is there an option for commanding the emc from "outsde"...for instance if i have a camera and i want to set the position of tool
for instance, my idea is to place a smd components to a pcb. There would be a camera, that would drive the emc so that it would grab a smd component.
You don't need to use emc's g-code interpreter to create the position commands. You can write your own HAL component which will give position commands instead.
but it is hard to do both -- use emc's g-code interpreter sometimes, and use some other HAL component at other times.
if MDI is good enough, you can send MDI commands with the mdi program
oh yes, that's true
what is MDI?
it is a mode where g-code is sent to the interpreter one line at a time, instead of being read from a file
I think it stands for something like "manual data interface"
manual data input.
or something like that
How is the fpga working?
(excited about that also)
pretty good! I *think* that everything works -- everything but index pulse has been minimally tested.
the features of the firmware are described here: http://emergent.unpy.net/01164408418
holy sh*t. Nice work. That was fast.
well thank you
I'm a bit surprised myself, being so new at FPGAs.
oh -- and I think that "45 microseconds" figure (time to read and write registers) is wrong -- I divided the cycle counts by the wrong CPU speed. It's more like 100uS
wow - those specs are pretty cool. the thing is so cheap I think I may be one of your beta testers. The 100% df issue is not an issue with me ;)
skunkworks: is "up/down" the pwmgen style you use with your servo board?
I can see where I will probably need higher resolusion encoders.
btw I bought one of the "flashy" modules as well -- I hope to write a linux app that works with the captured data in the next few days.
why will you need higher resolution encoders?
the only negative thing I have to say is that the fpga4fun guy seems to reveal as little information as possible -- though he did give me the extra information I asked for about the communication between pluto-p and the PC when using his flashy firmware, so maybe I shouldn't complain.
This is just my thought - As I push the servo away from is commanded possition - The harder I push - the harder it pushes back. The thing is - it takes a few encoder edges to do this - the one servo I can push a few thousands.
because my resolution is around .0002
and it's not your "deadband" setting?
bbl, time to drink coffee with my co-worker
jepler: is the fpga some type of contoller module on the cheap?
Lerneaen_Hydra: the pluto-p costs something like 60USD
why use that instead of one of the pre-existing solutions?
how expensive are the other ones :/
the next card is over 200 dollars (mesa)
that bad eh
:) yes I am a cheap bastard
hmm, 20khz, why not use a parport?
I have been. and it works pretty well so far. but you have to lower the encoder resolution to a point that the computer will be able to read it at the speeds I need.
plus it requires a pretty decent computer. The fpga would not.
20khz isn't fast, that's 50µS base period
for reading encoders you want twice that for headroom.
25µS still isn't a lot
no it isn't. Like I say.. It works but if I could get a fpga that works with the 28 i/o I would go for it.
what I'm trying to say is, why get the fpga for $60 when a free computer can do the same speeds for free?
err, one free too much
because at some point I would like to use encoders with a 1000 line or more. this will not work thru the parallel port.
(for the speeds I need)
oh, how fast can you run the fpga?
4 quadrature channels, sample rate 40MHz to a 12-bit counter
[13:59:57] <skunkworks> http://emergent.unpy.net/01164408418
oh, that's a bit better
I was under the impression that 20khz was the max or something
though seeing as how it's an fpga that's not very likely
? don't know - jepler would have to answer that. :)
so essentially its for reading fast encoders
what about driving steppers?
I think that is in the plan.
you'd be limited by the parport speed, right?
no - you would have the fpga do the pulse train and figuring out where to go
unless you send something like "untill the next base_period output x cycles" over the parport
Yes it is. :)
aren't these guys great?
jepler: what is "glitch free"?
I think I am going to have to order one of these things :)
$60, not that bad
cradek: did you have a good thanks giving?
what can you use instead of optocouplers at that speed?
cradek: suppose the old PWM value is 100, the current PWM counter is 200. The PWM output will be off. Now I set the PWM value to 300. The output turns on immediately.
the long weekend was better than the holiday itself, but in general, yes
I took all of last week off. ;)
cradek: if it was glitch-free, the output would remain off until the counter reset, and then turn on for a full 300 cycles
jepler: I get it
jepler: is that important?
honestly - my servo drive is opto - isolated and encoders are by default isolated. I would not be affraid to just hook it up.
cradek: not sure; The AVR datasheet makes a point of being "glitch free"
see page 35 of http://www.atmel.com/dyn/resources/prod_documents/doc0839.pdf
kwajstabo: wouldnt you want to separate the machine and the workpiece changer to get things easier to overlook?
I suspect it doesn't matter much when driving servo motors
is the duration of the glitch always between the old and new values?
seems like it is
jepler: going to hook it up to your etch-o-sketch?
or cradeks' lathe? :)
I think my lathe will be his test subject
good test of the index pulse
I don't think the etch-a-sketch can be tuned very well - it's not a very good test platform
cradek: what happenes with coordinated motion on your lathe when the spindle isn't turned on. Does the axis move each direction when the spindle is spun cw and ccw?
no, emc can't currently back up, it depends on the spindle not moving backward
when we want to do rigid tapping that will need some thought
as soon as someone brings me a bridgeport with vfd spindle I'll work on rigid tapping
cradek: you need a servo dont you?
cradek: will rigid tapping work with just a normal motor and a vfd?
ideally, but not necessarily
in theory it just has to be able to stop and reverse when you want
I wouldn't try to use a bottoming tap of course
hm, it should work with my spindle then.. if you do get it working :)
the spindle would have to accellerate slower than what the axis could move.
yeah it's not written at all yet
huydralic spindle :)
yeah the axis has to keep up in accel and vel both - and that depends on your spindle rpm and tap pitch
hm, should make for nice rigid tapping laters..
i can stop in about 0.2 secs.
tapping is normally done at lower rpms <100rpm - at least in my experience.
it would be great to have a machine set up for tapping at fest
when/where is fest?
at the threading speeds used (only about 400 RPM?), I think the nist-lathe could accelerate with the spindle
Lerneaen_Hydra: galesburg, IL, USA sometime in the late spring
ouch this page is a bit ugly http://www.cnc-workshop.com/
June 11-17, 2007
hm, some of theese years im going to fest/workshop..
I am very glad I went last year -- it was great to meet people like jmk, swp, skunkworks, fenn, ray, matt s., and everyone else I forgot
jon elson, steve stallings
it was fun, and we got a lot done too
euro-fest would be cool, though a bit less populated
it's kind of a bit far to go from sweden..
cnc-workshop isn't just emc people -- but "fest" is what the emc part seems to be called
It was funny - when I first got there - I walked around the office area - where the classes where held. I thought that I was missing something. (where where the emc gurus?) I finally found them stuck in the corner of another building.
that's why everyone else should come here instead :D
I probably wouldn't make it but I think an european emc fest / cnc workshop would be a fine idea
we've got a fair number of european users
I keep badgering alex to come :)
I think Alex said that he may make it this year
he just couldn't swing everything (work, girlfriend, visa) last year
not many euro-devs though :(
poor alex has to support all europe :p
SWPadnos_ is now known as SWPadnos
I noticed (but didn't fully read) a discussion about the AVR PWM and its glitch-free features
Lerneaen_Hydra: I don't remember if I answered this -- the PWM clock is also 40MHz, so it counts from 0 to 2048 about every 50 microseconds / 20kHz. So over each 50 microsecond time period, the PWM can have one of 2048 different duty cycles.
oh, so 20khz inside each base period
I don't think you need to go all the way with that - they use ip/down counters for several modes, but I think you can get by with just a holding register that gets clocked into the compare register at the end of every PWM cycle
SWPadnos: do you think "glitch free" is important for running a servo motor, though?
I don't have a lot of gates left, 3 more 12-bit registers would be a big expense
I'm not sure. I think it's more of an RF noise thing, actually
actually, I suspect it's fine for smaller motors, but high power motors may have issues - consider the Mazak while dragging windows around - a couple of ms seemed to make a difference there
this is much less time than a ms, though
yep - so it shouldn't be a big deal
(until you find a motor/machine where it is ;) )
jepler: how many gates does the pluto have?
was it 500-ish?
Lerneaen_Hydra: 576 "logic elements"; they call it "10,000 typical gates"
there's one flip-flop per LE
so you get many and/or/xor/invert into a LE?
did you look at the datasheet at all? http://www.altera.com/literature/ds/acex.pdf
what's the package for that chip - if they sell a kit/bare board, it may be possible to get a higher gate count part in the same form factor
err, I missed that
look at page 21 for a picture of what one LE is
SWPadnos: no, only the ep1k10 is available in the 100-lead package
with the 144-lead package you have more choices -- 3x and 5x as many LEs
yep. very few FPGA choices in hand-solderable packages
relative to the number of BGA choices, at least
BGA is t3h shit :p
yeah - if only I had an X-ray inspection machine at home
* SWPadnos checks eBay
* jepler isn't sure if SWPadnos is serious about buying an x-ray inspection machine or not
hm, Im not going this year, but the next one..
it wouldn't surprise me if he were
SWPadnos: do you need one for bgs?
holy crap - you can get an airport X-ray machine for $599 *or less)
yeah - you can't see the pads under the chip, which is all of them
why do you need to see them?
now I know -- swp *is* buying an x-ray machine
err - to test whether the chip was correctly soldered ...
SWPadnos: why not have somone make a board with a socket for you?
no - they're $10k (but there is one on eBay, which is funny)
you can't reliably socket a BGA
yes you can..
* anonimasu has seen thoose test sockets ;)
but they might set you off more then a xray machine
it would be less expensive to buy an X-ray machine, if a production run has more than 10 units ;)
SWPadnos: tell that to intel -.-
not at all problem ridden
FCPGA isn't quite BGA, though I'd have to look up the differences ;)
[15:35:19] <SWPadnos> http://cgi.ebay.com/ws/eBayISAPI.dll?ViewItem&item=130028556337
[15:35:23] <Lerneaen_Hydra> http://en.wikipedia.org/wiki/Socket_t
<- almost bga
cheap, at any price
flip chip ball array
at least the CPU looks like a bga
[15:36:15] <anonimasu> http://www.necel.com/pkg/en/pk02_03.html
it's the bonding that's different
actually, Flip Chip Pin Grid Array, I think
I wonder where to get those sockets at a reasonable price (they're also not available for "standard" BGA, AFAIK)
I know you can get test sockets - for $1k a piece or so
oh good - they have 0.5mm pitch sockets O_O
first hit on google I think
but they only go up to 400 pins :(
the 0.5mm pitch line tops out at 20x20
I haven't looked at the others
that's 1.5, but that seems large
ah - ok, 1.27mm pitch goes up to 1064 pins
which strangely enough still isn't enough for the larger FPGAs
[15:41:34] <anonimasu> http://www.advintcorp.com/
I wonder how much those cost ...
cool stuff. I sit corrected - you can socket a BGA (but I still son't want to :) )
well, if cpu makers do it..
SWPadnos: besides if you are prototyping :)
oh sure - for prototypes that can work (though the sockets are huge compared to the chips)
actually, there are SMT proto assembly houses that also do X-ray inspection - you can probably get 5 boards built and inspected for the cost of one socket
well, doing it yourself isnt too nice even if you do have xray..
I agree. I prefer to not solder anything beyond 0603, though I've done 0402 by hand (multi-element resostors at 020 pitch)
03jepler 07HEAD * 10emc2/lib/python/nf.py: fix for problem reported by flo-h: can't find axis share directory when installed to /usr/local but python installed to /usr
SWPadnos: yeah, and the headache
I can't find eagle library files for any of those TQFP FPGAs :(
you probably can't route anything larget than 100-144 pins in the free version of eagle anyway
you need more layers for the fanout
I was going to try doing one of those 144-pin ones in 2 layers .. I agree, it's likely to suck
what's the max board size in the free Eagle?
80x100mm, 2 layers
VCCint, VCCio, gnd, and signals -- it'll suck in 2 layers
and you probably want a DB25 connector on there as well
yeah, I want pluto-p with more gates and more I/Os brought to the .1" headers
heh - headers - the other space hog ;)
you have 4 axes of encoder and PWM/step+dir right now (or similar), right?
right, plus 6 other inputs and 4 other outputs
which you'd like to increase?
do you want to provide ground/common connections for each I/O? (easier for wiring, not for board routing)
worse for board area too
I'm not sure
hm -- the encoder counter size had better be bigger than the encoder counts per rev when using index pulse
otherwise the index pulse will always fall on the same encoder count modulo the counter size
This is a list of Commercial Exhibitors for the Second Annual CNC-Workshop
Advanced Lap Sitting - Boris, the Shop Cat
* jepler chuckles
I forgot about boris -- I should have listed him among the "people" I met at fest
yep - Boris was always on the water heater when I'd go to get water to make coffee :)
I think the only limit on the free version of eagle is board size
you can do 12-layer boards?
oh - and 2 layers ;)
ok, I think we've been there ;)
[16:30:41] <cradek> http://neme-s.org/CNC_Workshop/P6240116.JPG
boris watching one of the presentations
he looks more interested than the humans
thank god he like attention. one of our cats would freak out and die with all those people.
too bad there are no photos from last year linked from the workshop web page
if he didn't like the attention I'm sure he could find somewhere to hide
I should see if dad took some.
jepler: you never found your memory stick did you?
here are some of fenn's photoshttp://fenn.freeshell.org/retrofest/
skunkworks: no, I never did
oh -- I guess most of those are from the '05 fest
hmmm - fenn wasn't at fest '05 (at NIST)
05 was in IA, 04 was NIST
... I think
ah - that was the CNC workshop in 05, which wasn't coincident with Fest - it was just the beginning of the Mazak retrofit
that's part of why we did it at CNC workshop this year - because people couldn't travel for 2 weeks
in the summer
plus family vacations ;)
Lerneaen_Hydra: after you're done with the electric cycle, make one of these: http://blog.modernmechanix.com/2006/11/27/belt-drive-replaces-wheels-on-novel-motorcycle/
steering looks like a pita
effeciency probably sucks too :p
there's a newer version of that that actually can steer
they use a link belt of some sort, that can flex from side to side
jepler: you have to solder your header on the pluto board correct?
skunkworks: the board comes as shown in this image: .w.g.t.highlighting.f.lf.c2.fr7.b invoke
[17:06:56] <jepler> http://www.fpga4fun.com/images/Board_Pluto-P.jpg
what the hell was that other thing? :)
ok. How are you planning to connect the outside world to it?
a male header for the longer connector is included but not soldered on
SWPadnos: a trade secret, probably
you can't write trade secrets in tcl - it's impossible
looks like postscript
the shrouded header is for JTAG apparently
sorry, unplugging laptop :P
at least it's not brainfuck or whitespace or something
sure looks nasty though
it's very easy to understand -- .w.g.t.highlighting.f.lf.c2.fr7.b is the name of a widget, and "invoke" is the action to be taken
but if I tell you what .w.g.t.highlighting.f.lf.c2.fr7.b is, I have to kill you
the f.lf.c2.fr7.b looks nasty though
jepler: a widget?
no -a doohickey
colors and parameters maybe
I think I'd like to invent a language where the GUI elements are called doohickeys
jepler: is there an online manual for the pluto board? I don't see one. Sounds like you only get it when you buy it?
skunkworks: yes, he sends you a URL when you complete the purchase
you get the stuff mentioned in the section "What files are provided with Pluto-P?"
how's linux flashing capability?
Lerneaen_Hydra: fast and easy -- but the devel software is windows-only (I'm running it in vmware)
it's too bad that Altera has no free Linux tools
you can get a Linux version if you pay for it
is the linux version cheaper than a w2k or wxp license?
(I haven't even looked at the prices)
I don't think so
* cradek makes a face
it may be mor, in fact - it's ratgeted at designers who use other unices - like Soalris
more / targeted
well, that doesn't deserve a correction ;)
SWPadnos: you need a new keyboard or less coffee habit
more coffee habit
ouch! their IP core for hypertransport is very expensive
$23495 at DigiKey, plus $5995/year (I think) for renewal
jeeze - you have to be making the real money to make that back.
very real money
What can you do with your Dragon?
Any well-trained Dragon can throw flames and smoke. That's easy; just plug the USB to the main power (110 to 240V, depending on where you are). While that will void the warranty, you should get some smoke... and maybe some flames.
</description of one of the fpga4fun boards>
Just this once .. here's the log: http://www.linuxcnc.org/irc/irc.freenode.net:6667/emc/2006-11-27.txt
Lerneaen_Hydra_ is now known as Lerneaen_Hydra