reading Pokeys pins

C Scripting questions and answers
gburk
Old Timer
Posts: 324
Joined: Sun Nov 25, 2018 3:57 pm

Re: reading Pokeys pins

Post by gburk »

hi art

Have a thought on what maybe part of the problem with having to run the LIB script first before it works...

I have the tool script with 16 buttons only testing on button one right now..

If I boot auggie and press tool button 1 the only thing in the script that runs are the freeaxis's I have a Engine.FreeRapit(null,4,4,null); and also a Engine.RapitTo(2,2,2,null); the free axix's dro's run up to 4 4 the X Y Z axis's show no movement... no dro's moving...

Now if I run the script in the edit run all axis's move... Not sure if this helps at all but just something I am seeing going on... and it looks like the script was compiled on boot up..

Thanks gary
User avatar
ArtF
Global Moderator
Global Moderator
Posts: 4648
Joined: Sun Sep 05, 2010 6:14 am
Contact:

Re: reading Pokeys pins

Post by ArtF »

Gary:

>>N220G00G43Z0.8000H2

  Spaces shouldnt matter. But the G43 could trip an error.  G43 is not yet implemented for use, its there and will take the H2 to mean 2mm offset to the Z height, not add the tool#2 height. As there is no tool table,
G43 wont work the way it will in Mach3 for example.

  Do the script ";" errors only happen in certain gcode programs? If so, post the Gcode
so I can test that to see why the error.  It does look as if that error is related to some script
that is failing.

>>g to run the LIB script first before it works...

  It sounds as if the script is fine, but for some reason your motion is inhibited after you
start up. Since the freeaxis are running, the script must be. SO we need to figure out
why the main axis are ignoring your calls, and not tripping an error.

Are your tool buttons in one library file folder of their own? Can you zip it up so
I can simply unzip that folder to add it to my own? If so perhaps I can test
it that way to find why that weird stoppage at first.
  Have you found doing anything else fixes it? Does , for example, loading and
running a Gcode program that doesnt use any of your scripts first, then allow
the scripts to run right away?

Art


gburk
Old Timer
Posts: 324
Joined: Sun Nov 25, 2018 3:57 pm

Re: reading Pokeys pins

Post by gburk »

Ok at I attached more than you asked for but what the heck

my panels and scripts also the gcode I have been having a problem with..
you are right not having a space between the line numbers didn't matter I have them spaced in the copy of the gcode.

yes they are in a library of there own..

I don't think any of the gcode use's any of my scripts except m6 and I have shut that lib off and was just using the you library calls...

I don't think I will be able to use any m6 call from my library endless  I can turn off your dialog that pops up on most of the m6 calls so if I use the dialog I created and it pops up so does yours and that makes things not react as I would like not sure but your dialog is sending the axis's other that were I would like to go with mine..

also when the auggie first boots should it display the message system reset scripting two times?.

also one thing I just realized is when I call the tool button script and the free axis starts running the e stop is off that doesn't seem right to be runing the free axis without turning on the estop this could be a disaster...

did a little more testing and the free axis only runs in simulator mode but not the x y z with the rapid moves with the button press - endless the script is run first
now in motion mode only the x y z run and not the free axis's with the same button press script and doesn't matter if you run script first still no free axis move..
still get buffer under run error


Thanks gary
Attachments
XballscrewmountFinal.zip
(1.84 KiB) Downloaded 322 times
Panels.zip
(272.79 KiB) Downloaded 305 times
Scripts.zip
(15.23 KiB) Downloaded 311 times
Last edited by gburk on Sun May 05, 2019 11:10 am, edited 1 time in total.
User avatar
ArtF
Global Moderator
Global Moderator
Posts: 4648
Joined: Sun Sep 05, 2010 6:14 am
Contact:

Re: reading Pokeys pins

Post by ArtF »

Hi Gary:

Thx, just got the files, Ill see whats up tomorrow. Just had my floors sanded so I was kicked out of home
for a few days till they dried.

>>also when the auggie first boots should it display the message system reset scripting two times?.

  Yes, its a bit of a trick. The first time its finding globals and such used by other files, it allows globals
to be seen by files that use them before they are declared.

>>still get buffer under run error

  Thats usually when you exceed 125Khz the Pokeys is maxed for.. but give me a couple days
and Ill know more about your scripts.

Art
User avatar
ArtF
Global Moderator
Global Moderator
Posts: 4648
Joined: Sun Sep 05, 2010 6:14 am
Contact:

Re: reading Pokeys pins

Post by ArtF »

Gary:

  I think I see many of your script  errors. Many lines of the Gcode header include lines
such as

{0.25 inch} in the comments. In Auggie , when it see's a {} in the code, it thinks your
adding a Cscript. Scripts can be mixed with Gcode in Auggie by adding any script call
or special function to the file inside {}'s.

However.. these are inside a comment, and I will see about turning off
script recognition inside a comment block. I hadnt had that error prior
to now so didnt see it.  The errors though wont affect the run, they just
trigger a lot of warnings while loading the file. Ill fix that little bug up first.

Art
User avatar
ArtF
Global Moderator
Global Moderator
Posts: 4648
Joined: Sun Sep 05, 2010 6:14 am
Contact:

Re: reading Pokeys pins

Post by ArtF »

Gary:

  Ive fixed the scripting errors on load, Scipt "{}"s will be ignore if inside a comment.

I need your screenset to test with your dialogs though. I have your panels, but in the Screens folder
should be the screen you have setup using those panels.Can you drop it here?

Thx
Art
gburk
Old Timer
Posts: 324
Joined: Sun Nov 25, 2018 3:57 pm

Re: reading Pokeys pins

Post by gburk »

Ok Art

Here's the screen

Hope this helps...

I see the {} in the gcode so it's not being ignored event though it's inside () I think that  I used victric to generate that gcode I looked at cambam and sheetcam it doesn't look like they put the {} anywhere in the gcode
I removed the {} from victric's post processor so shouldn't add to gcode now..

I know the scripts are a mess keep adding and changing so go easy on me :)

Thanks gary
Attachments
Myscreen.zip
(72.9 KiB) Downloaded 322 times
Last edited by gburk on Tue May 07, 2019 1:26 pm, edited 1 time in total.
User avatar
ArtF
Global Moderator
Global Moderator
Posts: 4648
Joined: Sun Sep 05, 2010 6:14 am
Contact:

Re: reading Pokeys pins

Post by ArtF »

Gary:

I haven't updated the program yet on the web, so only after next release will it ignore the {}'s.
Ill keep back any release till Im finished analysing your screen..

Thx
Art
User avatar
ArtF
Global Moderator
Global Moderator
Posts: 4648
Joined: Sun Sep 05, 2010 6:14 am
Contact:

Re: reading Pokeys pins

Post by ArtF »

Gary:

I just uploaded Auggie 3.6b , test it and see what it foxes and what it doesnt.

  You shouldn't get that dialog anymore, it will skip that call if the axis position was just changed
by a script call such as your scripts. The Dialogs will not have any more than 1 OK and cancel
button combination.  I dont seem to have a problem getting motion right off if I press for a Z-Touch
or such. Let me know whats going on and we'll go from there.

Thx
Art
gburk
Old Timer
Posts: 324
Joined: Sun Nov 25, 2018 3:57 pm

Re: reading Pokeys pins

Post by gburk »

Art

I Still seem to have to run the scripts first for the toolbuttons and probe to work or there's no motor movement, and also the dialog to continue still pops up on some m6 calls

and I am getting no free axis movement with the freerapid now at all...

I am going to move all the code to another computer and see if I get any better results...

thanks gary
User avatar
ArtF
Global Moderator
Global Moderator
Posts: 4648
Joined: Sun Sep 05, 2010 6:14 am
Contact:

Re: reading Pokeys pins

Post by ArtF »

Gary:

>>I Still seem to have to run the scripts first for the toolbuttons and probe to work or there's no motor movement, and also the dialog to continue still pops up on some m6 calls

  Can you give me a sequence here. For example, you start program, load a Gcode file, then what is the sequence where nothing happens?  What button do I need to press to simulate what your doing? Do I need to load a file to see this or doe yours not move if you simply press the Tool#1 button for example?

>>and I am getting no free axis movement with the freerapid now at all...

  I havent touched anything on the freeaxis. Other than dialog changes and scripting errors I havent
modified anything to do with freeaxis settings.

>>I am going to move all the code to another computer and see if I get any better results.. .

  I cant see that making much difference, the Freeaxis is probably some configuration thing.
Do you get any error when trying to turn on a free axis?

thx
Art
gburk
Old Timer
Posts: 324
Joined: Sun Nov 25, 2018 3:57 pm

Re: reading Pokeys pins

Post by gburk »

Art

You are right same results on different computer..

I boot auggie, and I do not load any g code files, I hit estop and then hit tool1 button I get all the print messages in the script but no movement.
then I try the z probe button same results.

now I load the lib for toolbuttons and run the script and now I get motor movement fine.. but no freerapid movement only x y z..

now I hit the z probe button again still no movement...
so I load the  probing script and run it, and now I get z axis movement..

make any more sense

also don't seem to be able to get free axis movement at all now in simulator or motion mode..

The auggie dialog to continue seems to only happen while running g code file on a T M6 line

Thanks gary


Thanks gary
User avatar
ArtF
Global Moderator
Global Moderator
Posts: 4648
Joined: Sun Sep 05, 2010 6:14 am
Contact:

Re: reading Pokeys pins

Post by ArtF »

Gary

  I found an issue in script init sequence. So now, using your scripts and panel,
I start up, press Tool #1, the freeaxis move as I assume youve told them to,
and the z axis probes.

  Ill put this online tomorrow and we'll see where you stand then. Nothing Ive done
affects the Free axis though, and before I fixed the init, the free axis only moved
when I pressed the button.  So Im unsure why your free axis have stopped.. check
their config..maybe you changed something in testing..

Art
User avatar
ArtF
Global Moderator
Global Moderator
Posts: 4648
Joined: Sun Sep 05, 2010 6:14 am
Contact:

Re: reading Pokeys pins

Post by ArtF »

Gary:

New version is online that should correct your scripts not starting up.
I tested by simply starting up, and pressing tool#1 button. All involved axis
seemed to do what they should including freeaxis.

  Let me know if this seems to fix most script items. Your dialogs should only
have proper OK and cancel buttons, and motion should be possible right
after startup.

Art
gburk
Old Timer
Posts: 324
Joined: Sun Nov 25, 2018 3:57 pm

Re: reading Pokeys pins

Post by gburk »

Ok Art

The startup works fine now boot auggie and hit estop press tool1 and x y z run fine. and z probe
But still no free axis's moving I checked the config and it looks good for all 4 of the free axis's don't see any changes..

I tried running Engine.FreeRapid(null,3,2,null); alone from the script window and run it, but there was no movement...

Thanks gary

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest