ryannining / karyacontroller

4 axis CNC, 3D, Laser Controller
GNU General Public License v2.0
59 stars 26 forks source link

i look interest for d1mini and hope in d1 mini 32 in future #2

Open exilaus opened 6 years ago

exilaus commented 6 years ago

i checked board d1 mini board. Dir EZ are combined? see from gerber Heater pin not connected with mosfet.

i stay re-design board, on easyeda for simplify sharing, but want make that compatible with mini 32 image

pin out are compatible from d1 mini need change only pin name from firmware. normaly with esp32 can manage more stepper and more extruders. i can help you on that? regards

ryannining commented 6 years ago

yea, my pcb seem have many bugs. I already test, and jumper some pin .

for E and Z yes its shared for wemos D1, and handled in firmware, it will prioritize the Z. i have test many prints and its all work fine.

For esp32 i still cant compile without error. So perhaps need more time to learn the ESP32. So you can try compile it and inform us.

I try to update the pcb first on easyeda.

Currently i am focusing add raster data for laser engraving (G7)

ryannining commented 6 years ago

easyeda link esp3d have been updated and i check and recheck, hope no error.

last time,

hahahahahaha, i am sorry, so many bugs on pcb

darkberg commented 6 years ago

Hi,

i'm looking on the code / board also for esp8266.

apparently, all compiled ok, for nodemcu 8266, all connected, but no pin output on osciloscope...

tested with D0-D8 numbering and also with direct pin addressing.

what config do you suggest to use as a starting point?

ryannining commented 6 years ago

Well make a new few lines on boards.h just copy from wemos3d i think is good. rename the BOARD_WEMOS3D to BOARD_WEMOS323D.


/*
  ============================================================================================
     _WEMOS3D
  ============================================================================================
*/
#elif defined(BOARD_WEMOS3D)

#define xdirection D5
#define xstep D4
#define ydirection D7
#define ystep D3

// z and e have same direction pin, we think that normally slicer never move z and e together.. we hope we right :D
#define zdirection D6
#define zstep D0
#define e0direction D6
#define e0step D2

#define limit_pin D8

#define temp_pin A0
#define heater_pin D1

//#define INVERTENDSTOP
#define NUMBUFFER 20

Then edit the pins

After that, just edit the config_pins.h uncommend the BOARD_ESP32VN3D

I dont know if the board detected here, maybe you can add some #warning

// ====== ESP32 ====================================================
#elif defined(ESP32)
//#define BOARD_ESP32VN3D
#define BOARD_WEMOS323D
#define THEISR ICACHE_RAM_ATTR 
//#define SUBPIXELMAX 6  // multiple axis smoothing / AMASS maximum subpixel
#warning ESP32 Detected

Just upload then check the serial monitor. Perhaps, you need to turn off the WIFI and telegram first, because they make boot slow.

ryannining commented 6 years ago

Then first you need to adjust the eeprom setting perhaps, i dont know if eeprom work ?

send gcode M205 to check the machine settings.

darkberg commented 6 years ago

hi, i've seen u just modified eeprom h/cpp . currently not compiling.

did you managed to test completely on esp8266 ?

darkberg commented 6 years ago

ok, i will open a new issue

ryannining commented 6 years ago

whats the error, i just test on both stm32 and esp8266 work fine

darkberg commented 6 years ago

what did you used for parsing commands to the esp8266>?

i tried both serial connection & Repetier host.

all commands go well, except that there is no output on the pins.

connected an Hantek osciloscope on D3 ^& \D4 pins, to check for step generation.

nothing appears on the output ( D3 / D4 or any other outputs).

first i thought that the pin mapping might be a problem, so instead of using D0_D8 numbering, i used dirrect numbering, as qouted below.

============================================================================================ _WEMOS3D

*/

elif defined(BOARD_WEMOS3D)

// // Added static const uint8_t definition for D0-D10 // //static const uint8_t D0 = 16; //static const uint8_t D1 = 5; //static const uint8_t D2 = 4; //static const uint8_t D3 = 0; //static const uint8_t D4 = 2; //static const uint8_t D5 = 14; //static const uint8_t D6 = 12; //static const uint8_t D7 = 13; //static const uint8_t D8 = 15; //static const uint8_t D9 = 3; //static const uint8_t D10 = 1; //

define xdirection 14 //D5

define xstep 2 //D4 //2

define ydirection 13 //D7

define ystep 0 //D3

// z and e have same direction pin, we think that normally slicer never move z and e together.. we hope we right :D

define zdirection 12// D6

define zstep 16 // D0

define e0direction 12 // D6

define e0step 4 //D2

define limit_pin 15 //D8

define temp_pin A0

define heater_pin D1//5 //D1

//#define INVERTENDSTOP

define NUMBUFFER 80

/*

 _WEMOS3D

============================================================================================

the same problems appears.

here is repetier 2.1 console output: *** Printer reset detected ! <<<>>>>>>> !

19:37:03.265 : Printer reset detected - initalizing 19:37:03.265 : start 19:37:03.450 : N1 M11034 19:37:03.450 : N2 M11536 19:37:03.465 : FIRMWARE_NAME:Repetier_1.9 19:37:03.465 : N3 M10536 19:37:03.465 : N4 M11435 19:37:03.481 : X:0.000 Y:0.000 Z:0.000 E:0.000 19:37:03.481 : N5 M111 S698 19:37:03.481 : N6 T060 19:37:03.481 : N7 M8028 19:37:03.481 : N8 M220 S100105 19:37:03.497 : N9 M221 S100105 19:37:03.497 : N10 M111 S686 19:37:03.497 : N11 T010 19:37:26.408 : N12 G28 X0104 19:37:26.408 : X:0.000 Y:0.000 Z:0.000 E:0.000 19:37:29.154 : N13 G28 Y0104 19:37:29.160 : X:0.000 Y:0.000 Z:0.000 E:0.000 19:37:30.923 : N14 G28 Z0108 19:37:30.923 : X:0.000 Y:0.000 Z:0.000 E:0.000 19:37:34.289 : N15 G1 X10 F480015 19:37:35.089 : N16 G1 X20 F480015 19:37:35.820 : N17 G1 X30 F480015 19:37:37.835 : N18 G1 X40 F48007 19:37:39.319 : N19 G1 Y10 F48002 19:37:40.004 : N20 G1 Y20 F480011 19:37:40.319 : N21 G1 Y30 F480011 19:37:40.620 : N22 G1 Y40 F480015

ryannining commented 6 years ago

please check the M205 first, and watch the log. to see if the configuration step/mm and other are not zero

ryannining commented 6 years ago

also for repetier, activate Ping Pong communication on the printer settings.

ryannining commented 6 years ago

or, you can use the Repetier Host Eeprom config (Keyboard Alt+E).

darkberg commented 6 years ago

hi found the time to test a M205. apparently eeprom has some problems. will investigate further.

21:01:07.148 : N16 M205*19 21:01:07.148 : EPR:3 145 ?2417.408 Xhome 21:01:07.148 : EPR:3 149 ?1090.176 Y 21:01:07.148 : EPR:3 153 ?7777.408 Z 21:01:07.148 : EPR:3 3 -0.001 StepX 21:01:07.148 : EPR:3 7 -0.001 Y 21:01:07.148 : EPR:3 11 -0.001 Z 21:01:07.163 : EPR:3 0 -0.001 E 21:01:07.163 : EPR:2 15 -1 FeedX 21:01:07.163 : EPR:2 19 -1 Y 21:01:07.163 : EPR:2 23 -1 Z 21:01:07.163 : EPR:2 27 -1 E 21:01:07.163 : EPR:3 181 -1 Jerk 21:01:07.163 : EPR:3 51 ?7391288 Accel 21:01:07.163 : EPR:3 67 -1 MVAccel 21:01:07.163 : EPR:3 177 255 FHome 21:01:07.163 : EPR:3 185 -0.001 XYscale 21:01:07.179 : EPR:3 165 -0.001 Xofs 21:01:07.179 : EPR:3 169 -0.001 Yofs 21:01:07.179 : EPR:3 173 -0.001 Zofs 21:01:07.179 : EPR:3 80 -0.001 Xbcklsh 21:01:07.179 : EPR:3 84 -0.001 Y 21:01:07.179 : EPR:3 88 -0.001 Z 21:01:07.179 : EPR:3 92 -0.001 E

i tried now some modifications on eeprom values, & i will return with updates.

darkberg commented 6 years ago

back it's alive.

after modding the eprom values by hand, it finally outputs signals visible on the osciloscope.

Great Work !

i have to admit, i did not checked eeprom settings.

ryannining commented 6 years ago

yea, i dont check the eeprom value either after a fresh upload. Need some check :smile:

darkberg commented 6 years ago

Did you managed to implement the Laser ON/Off?

Noticed some wdt reset on G4 P1500 commands. I admit, i did not checked yet the code.

I start designing the board (pcb)

On Thu, Jun 21, 2018, 9:59 AM ryannining notifications@github.com wrote:

yea, i dont check the eeprom value either after a fresh upload. Need some check 😄

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/ryannining/karyacontroller/issues/2#issuecomment-398997130, or mute the thread https://github.com/notifications/unsubscribe-auth/AV00ieAWay1_C9xtukpRV3uB-JKFTZUQks5t-0RSgaJpZM4UhWOQ .

ryannining commented 6 years ago

My laser machine uae stm32, havent use wemis for laser

darkberg commented 6 years ago

testing esp8266 for a DiY plasma cutter....

plasma behaviour is a little different than of a laser:

  1. z height needs to be lowered, until the coresponding height for arc initiation ( done)
  2. u need fire plasma ( done)
  3. G4 Pxxxx ( testing)
  4. rise Z 0.xx mm ( done)
  5. continue travel (done)

just tested laser out function.... laser pin got activated only on travel move

what i've noticed so far:

at this stage, G1 E1 & G1 E-1 might be an option, using Extruder direction Pin. to control plasma

one question: on stm32, did you used 1 or 2 pins for laser ? ->> laser pwm or Laseer enable & laser pwm ?

°º¤ø,¸¸,ø¤º°°º¤ø¤º°°º¤ø,¸¸,ø¤º°°º¤ø¤º°°º¤ø,¸¸,ø¤º°`°º¤ø,¸¸,ø¤º°°º¤

                               DarKMooNRiseRs

On Thu, Jun 21, 2018 at 12:33 PM, ryannining notifications@github.com wrote:

My laser machine uae stm32, havent use wemis for laser

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/ryannining/karyacontroller/issues/2#issuecomment-399039363, or mute the thread https://github.com/notifications/unsubscribe-auth/AV00iSSZe1-lu82FsW9QKyWy8jDc_UdKks5t-2iAgaJpZM4UhWOQ .

ryannining commented 6 years ago

For laser:

  1. Call M3 S255 to set intensity. 255 for full laser on every step, if lower than 255 then it will turn on only for defined microseconds then off, on each motor step.
  2. G0 command will not turn on the laser, only G1
  3. To Test the Laser without moving axis, call M3 S255 Pxxx , xxx =time to on in milliseconds
  4. For laser engraving raster data, G7 Sxx [data] xxx= data length, data= ascii encoded intensity a to z will be mapped to 0 - 254 intensity

G4 , is not needed, in fact i does not test G4, i check the code its for delay right.

ryannining commented 6 years ago

Laser only use 1 pin, and doesnot have PWM function. Wemos only have 1 free timer and already used for stepper motion.

Other timer are used by WIFI and AnalogWrite (i try use it and not stable).