serial-port-json-server icon indicating copy to clipboard operation
serial-port-json-server copied to clipboard

"Failed to get planning buffer" when sending Gcode to TinyG with small steps

Open bartona opened this issue 4 years ago • 4 comments

I'm running into a problem where when I send Gcode to a TinyG V9 (Othermill) using ChiliPepper and SPJS, and there are small steps in the Gcode (specifically that of a small arc around the teardrop of a through hold pad), my TinyG just crashes with a "failed to get planning buffer error". When I send the same gcode using another software (CNC.js for example), I don't get the same issue.

Also, is there and documentation on how the tinyg bufferflow options work, and how serial data moves through SPJS at a high level? I was trying to dig into the code to see if I could find a resolution, but it was becoming difficult to follow.

bartona avatar Jun 10 '20 20:06 bartona

What computer are you running spjs on? It's written in Go, which is like C, and compiled, so it's screaming fast. Are you sure you're buffering enough Gcode to it ahead of time? Meaning, how big is the buffer in the serial port widget in lower right corner? I'd say keep it up in the 10's of 1000's. Maybe you're starving it there.

On Wed, Jun 10, 2020 at 1:06 PM Aaron Barton [email protected] wrote:

I'm running into a problem where when I send Gcode to a TinyG V9 (Othermill) using ChiliPepper and SPJS, and there are small steps in the Gcode (specifically that of a small arc around the teardrop of a through hold pad), my TinyG just crashes with a "failed to get planning buffer error". When I send the same gcode using another software (CNC.js for example), I don't get the same issue.

Also, is there and documentation on how the tinyg bufferflow options work, and how serial data moves through SPJS at a high level? I was trying to dig into the code to see if I could find a resolution, but it was becoming difficult to follow.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/johnlauer/serial-port-json-server/issues/77, or unsubscribe https://github.com/notifications/unsubscribe-auth/AB4J23NVS7T6HLOVMBQ6OSTRV7RV5ANCNFSM4N2WUHQQ .

chilipeppr avatar Jun 10 '20 22:06 chilipeppr

btw, this repo is the old one. you should be on chilipeppr/serial-port-json-server

On Wed, Jun 10, 2020 at 3:54 PM John Lauer [email protected] wrote:

What computer are you running spjs on? It's written in Go, which is like C, and compiled, so it's screaming fast. Are you sure you're buffering enough Gcode to it ahead of time? Meaning, how big is the buffer in the serial port widget in lower right corner? I'd say keep it up in the 10's of 1000's. Maybe you're starving it there.

On Wed, Jun 10, 2020 at 1:06 PM Aaron Barton [email protected] wrote:

I'm running into a problem where when I send Gcode to a TinyG V9 (Othermill) using ChiliPepper and SPJS, and there are small steps in the Gcode (specifically that of a small arc around the teardrop of a through hold pad), my TinyG just crashes with a "failed to get planning buffer error". When I send the same gcode using another software (CNC.js for example), I don't get the same issue.

Also, is there and documentation on how the tinyg bufferflow options work, and how serial data moves through SPJS at a high level? I was trying to dig into the code to see if I could find a resolution, but it was becoming difficult to follow.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/johnlauer/serial-port-json-server/issues/77, or unsubscribe https://github.com/notifications/unsubscribe-auth/AB4J23NVS7T6HLOVMBQ6OSTRV7RV5ANCNFSM4N2WUHQQ .

chilipeppr avatar Jun 10 '20 23:06 chilipeppr

Ok, I will repost the issue there.

On Wed, Jun 10, 2020 at 7:08 PM John Lauer [email protected] wrote:

btw, this repo is the old one. you should be on chilipeppr/serial-port-json-server

On Wed, Jun 10, 2020 at 3:54 PM John Lauer [email protected] wrote:

What computer are you running spjs on? It's written in Go, which is like C, and compiled, so it's screaming fast. Are you sure you're buffering enough Gcode to it ahead of time? Meaning, how big is the buffer in the serial port widget in lower right corner? I'd say keep it up in the 10's of 1000's. Maybe you're starving it there.

On Wed, Jun 10, 2020 at 1:06 PM Aaron Barton [email protected] wrote:

I'm running into a problem where when I send Gcode to a TinyG V9 (Othermill) using ChiliPepper and SPJS, and there are small steps in the Gcode (specifically that of a small arc around the teardrop of a through hold pad), my TinyG just crashes with a "failed to get planning buffer error". When I send the same gcode using another software (CNC.js for example), I don't get the same issue.

Also, is there and documentation on how the tinyg bufferflow options work, and how serial data moves through SPJS at a high level? I was trying to dig into the code to see if I could find a resolution, but it was becoming difficult to follow.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/johnlauer/serial-port-json-server/issues/77, or unsubscribe < https://github.com/notifications/unsubscribe-auth/AB4J23NVS7T6HLOVMBQ6OSTRV7RV5ANCNFSM4N2WUHQQ

.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/johnlauer/serial-port-json-server/issues/77#issuecomment-642312896, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABLTACN4DN5EWBVVELW75GTRWAG47ANCNFSM4N2WUHQQ .

bartona avatar Jun 10 '20 23:06 bartona

It seems like the issue is the planner buffer gets overflown (the qr reports reach 0 just before the firmware freaks out)

On Wed, Jun 10, 2020 at 6:54 PM John Lauer [email protected] wrote:

What computer are you running spjs on? It's written in Go, which is like C, and compiled, so it's screaming fast. Are you sure you're buffering enough Gcode to it ahead of time? Meaning, how big is the buffer in the serial port widget in lower right corner? I'd say keep it up in the 10's of 1000's. Maybe you're starving it there.

On Wed, Jun 10, 2020 at 1:06 PM Aaron Barton [email protected] wrote:

I'm running into a problem where when I send Gcode to a TinyG V9 (Othermill) using ChiliPepper and SPJS, and there are small steps in the Gcode (specifically that of a small arc around the teardrop of a through hold pad), my TinyG just crashes with a "failed to get planning buffer error". When I send the same gcode using another software (CNC.js for example), I don't get the same issue.

Also, is there and documentation on how the tinyg bufferflow options work, and how serial data moves through SPJS at a high level? I was trying to dig into the code to see if I could find a resolution, but it was becoming difficult to follow.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/johnlauer/serial-port-json-server/issues/77, or unsubscribe < https://github.com/notifications/unsubscribe-auth/AB4J23NVS7T6HLOVMBQ6OSTRV7RV5ANCNFSM4N2WUHQQ

.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/johnlauer/serial-port-json-server/issues/77#issuecomment-642309024, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABLTACO6JNX7G5LMCUVKJM3RWAFLLANCNFSM4N2WUHQQ .

bartona avatar Jun 10 '20 23:06 bartona