176

Re: Davinci Jr Repetier Port

Let me know if you guys need more captures! So far I have not been able to get any data off the serial monitor interface for U2, the SWDIO pin for U17, or the JTAG header, but that's probably cus I don't have the right software for it.

I can continue pulling serial captures from the U2-U17 link though. What I may end up doing is trying to pull simultaneous traffic using two different serial interfaces simultaneously, that way we can get a better understanding of the bi-directional traffic

177 (edited by yizhou.he 2017-09-22 22:21:05)

Re: Davinci Jr Repetier Port

Hi, pyroball, you really did great job here. But decode the message need lots of experiment, and make as little change as possible so that we can compare the change in code. And it will be helpful if you have more note on what you have done and then what code shows up.

For example, you can do clean nozzle, it should heat up to 200C while move XYZ to right spot. Since step motor don't generate communication here, and clean nozzle don't involve check spool status, we should only see command to raise temperature to 200C, and NTC report temperature change. Once temperature arrived 200C, the NTC report temperature change will become different. Since we have some vocabulary now, it is time to find out where the 200C is in the code and we will have better chance to decode the rest of the code. But it will be very helpful if you can mark in the log when clean nozzle command is send and when temperature riased to 200C and start to maintain 200C

Also, will you be able to fake message to U17 or U2? Once we decode the message, it will be nice if you can fake a command and see if it works.

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

178

Re: Davinci Jr Repetier Port

You might be able to get serial data off the serial monitor interface for U2 if you do bed leveling.

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

179 (edited by yizhou.he 2017-09-22 22:48:43)

Re: Davinci Jr Repetier Port

http://www2.lauterbach.com/pdf/training_jtag.pdf

For debugging any JTAG communication the use of a logic analyzer such as the TRACE32 PowerProbe is
recommended.

By using this tool it is not only possible to record the signals but also decode the JTAG protocol for a better
interpretation. The JTAG decoder is built-in but also available as source-code allowing to extend the analysis
by a higher-level decoder for custom use.

[Never mind, this thing is more expensive than 3d printer]

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

180

Re: Davinci Jr Repetier Port

I think we should be able to fake messages to U17 if we can figure out the heartbeat syntax.

In this printer, when the user requests a "clean nozzle" function, the print head does an auto-home before moving to the center of the printer and then heating up.

The Serial monitor header outputs 3 lines in ASCII plaintext, then the port shuts off for the remainder of the time the printer is on, probably for security.

I'll try getting more isolated commands recorded and will upload those with detailed descriptions

181

Re: Davinci Jr Repetier Port

ppl117 wrote:

I don't have a DaVinci jr, but I do like patterns, so maybe this can be of some help....

ppl117, If you like number patterns, I have a challange for you ( after helping out here ).
As you know, the Jr, and mini use a RFID  tag that must be in place for the printer to function.  There are many efforts to work around it, one of which is this thread here.   The tag , among other information, contains a 7 byte UID, a 4 Byte Pasword and a 2 byte PACK ( Password Acknowledge) code. 
Its these 3 pieces of information that keep us from making our own UID and generating the correct Password and PACK.  No one here know thee algorithm use. 
If you want a challenge, I can provide you about 500 valid UID / Password / PACK combinations and perhaps you can see a pattern and help create ( or create ) an algorithm that works.

What do you say?

Let me know, I dont want to hi-jack this thread, but wanted to get this out to you.

182

Re: Davinci Jr Repetier Port

yizhou.he wrote:

Will it make sense if it is mark of end of command or switch between devices?

I do see it frequently framing the 0C F3 message, which may be coincidental, but the 0C F3 message is interesting because it is 16 bytes containing no other inverted pairs.  The first byte after 0C F3 has the most change and looks important, the second may be even parity for the first.  It would be interesting to know what the machine is doing when these messages come through and see if they map to certain operations.

DaVinci 1.0A with Repetier, mostly stock with some extruder mods.  Prints ABS, PLA, HIPS, PETG and Taulman Bridge.

183

Re: Davinci Jr Repetier Port

JTag communication have certain format, it start with "run test/idle", probably the stuff before 11 EE, Then followed by muti-runs of shift-IR(Instruction Register) and shift-DR(Data Registers). Although I still don't fully understood how JTAG works, my guess is 11EE are shift-IR and 22 DD/0C F3 are shift-DR




"Test Logic Reset sets the Instruction Register to its reset value (IDCODE or BYPASS). This state
can be reached from any other state by shifting five times “1” on TMS.
Some CPUs do also reset the DTAB and/or the on-chip debug logic when this state is entered.
As a result an active debug connection might get lost, if this state is driven by a PRACTICE script
or a custom application.
• Run-Test/ Idle and Select DR-Scan are used by most debuggers as pause parking position.
• In the Shift-IR state the debug tool shifts an instruction into the Instruction Register. The
instruction is activated once the TAP controller reaches the Update-IR state.
• In the Shift-DR state the debug tool shifts data to/from the Data Register selected by the
currently loaded instruction."

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

184 (edited by pyr0ball 2017-09-29 05:17:53)

Re: Davinci Jr Repetier Port

OK guys, I got a second serial adapter and captured simultaneous data.

Included:
Bootup messages
Bootup + Cleaning cycle

My advice is to use the bootup messages as a diff or control to parse out the differences between the logs.

Behavior:
Home all axis'
Move to Z-Max
Move to X-Mid
Heat to 210C
Move Z -10
Await user input for finished cleaning

I'm also attaching a video of the serial capture itself so you can see the flow in relation to eachother

Post's attachments

2017-09-28 at 20-23-15_reduced.mp4 2.64 mb, 15 downloads since 2017-09-29 

Bootup_and_Cleaning_Cycle_U17.log 74.17 kb, 5 downloads since 2017-09-29 

Bootup_and_Cleaning_Cycle_U2.log 40.54 kb, 3 downloads since 2017-09-29 

U17_Bootup.log 8.08 kb, 8 downloads since 2017-09-29 

U2_Bootup.log 4.24 kb, 5 downloads since 2017-09-29 

You don't have the permssions to download the attachments of this post.

185

Re: Davinci Jr Repetier Port

Great job! pyr0ball, I will try to break down the communication and see if we can find something. I think it will be very useful if we have a working system to test these commands. If we can record a message, break it down, and fake the same message from code (repeitor-firware or reprap) and see if faked message will be accepted. Then we can manipulate the message say change heat hotend 200C to heat hotend 180C and see if the change is effective. This will greatly accelerate the decoding process.

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

186

Re: Davinci Jr Repetier Port

Any progress?

187 (edited by yizhou.he 2017-10-12 21:40:34)

Re: Davinci Jr Repetier Port

Only thing I figured out so far is the temperature
11 EE 0C F3 98 01 FA 03 BB 00 00 00 64 64 01 00 03 00
---------------||-----------------------------------------------

98 01 after 11 EE 0C F3 and before 01 FA 03 BB 00 00 00 64 64 01 00 03 00 is the temperature. This number change from F7 03 to 98 01 in the U17 cleaning cycle which is heating up. the first digit change first, so the real number should be 03 F7 to 01 98. It most likely to be resistance of the themistor (1015 to 408). We will need a temperature table for this conversion.

What else information do we need to get out of the communication?

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

188 (edited by yizhou.he 2017-10-12 22:14:16)

Re: Davinci Jr Repetier Port

Another possible observation is in bootup log, U2 have only 91 EE 80 FF, in bootup and cleaning cycle, U2 have lots of 91 EE 00 FF. Sepeculation is 91 EE 80 FF means NO HEATING, and 91 EE 00 FF mean KEEP HEATING. Need test experimentally thought. 

Anyone put up a bootable system together so that we can test these hypothesis?

Post's attachments

Bootup_and_Cleaning_Cycle_U17.log.docx 37.57 kb, 1 downloads since 2017-10-12 

Bootup_and_Cleaning_Cycle_U2.log.docx 18.25 kb, 2 downloads since 2017-10-12 

U17_Bootup.log.docx 14.78 kb, file has never been downloaded. 

U2_Bootup.log.docx 14.27 kb, 1 downloads since 2017-10-12 

You don't have the permssions to download the attachments of this post.
(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

189

Re: Davinci Jr Repetier Port

Well not a super necessary thing, but figuring out the trigger to activate the exhaust fan would be good. I think I can probably get captures at different temperatures which would help with the table.

I could also pull direct voltage readings off the divider circuit and map those to the temperature. Based on the way this board is designed, I don't think it can measure thermistor resistance directly. It's taking analog voltage measurements from out-2 on the voltage divider.

190

Re: Davinci Jr Repetier Port

the fan should be activated when temperature is above 50C.
it is best to convert to resistance in case people want to switch to E3D hotend or use different themistates.

I will check again to see if there is command that activates the fan.

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

191 (edited by yizhou.he 2017-10-13 03:57:52)

Re: Davinci Jr Repetier Port

Are you certain when you do the bootup log, the exhost fan is not on? If your fan is always on, I can not tell which code is responsible for the fan. The hotend need to cool down below 50C in order for the fan to shut down, Please re-record the U2 bootup log and make sure the fan is not on. Also re-record the U2-bootup clean cycle and make sure temperature start from room temperature so that the fan is off in the beginning and then temperature raise to 50C and 210C.

I suspect 02 FD 20 30 50 AF 40 BF 22 DD is the command for the fan, but it also shows up in bootup log. However, if your hotend temperature is above 50C when you record the bootup log, this will all make sense.

I remember you disconnect NTC, all you get is 91 EE 00 FF and no  02 FD 20 30 50 AF 40 BF 22 DD. I think disconnect NTC you get large resistance which suggest super low temperature, then hotend try to heat up but no need to turn on the fan.

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

192

Re: Davinci Jr Repetier Port

Anyone put up a bootable system together yet?

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

193 (edited by pyr0ball 2017-11-02 18:07:16)

Re: Davinci Jr Repetier Port

Sorry for some reason I stopped getting notifications on replies for this thread.

Yes 100% no fans are turned on when booting. The fans both come on simultaneously a short time after starting a heating cycle.

What would be the best way to test resistance? Should I solder a test wire onto the thermristor input line directly, or on part of the voltage comparator circuit?

194 (edited by yizhou.he 2017-11-02 19:22:37)

Re: Davinci Jr Repetier Port

OK, I don't think the fan code is super important at this point, put together a partially working system together is more important. We can wire the fan from 3rd party power source if necessary and control it manually for now. We need something to test our hypothesis and once that confirmed, it will be easier to decode the rest. And with a working system, we can build temperature table based on the real life temperature and the number machine sends instead of read the resistance.

Solder a test wire onto the thermristor directly is the best way to test resistance, but I don't know if the reading is accurate if you don't disconnect the thermristor from the machine. I would prefer just test hotend temperature with thermistats and compare with the reading from the U2 for temperature table.

I think you only get notification if you start the post or someone quoting your post.

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

195

Re: Davinci Jr Repetier Port

Nah I got a notification this time.

Ok so I'll get a few test wires in place first for various points. Do some heating and measuring, and provide as much data as I can. My main concern is going to be the delay of the printer display to actual temperature

196

Re: Davinci Jr Repetier Port

OK just FYI, going on my annual vacation this coming week so I'll get back on this when I return

197

Re: Davinci Jr Repetier Port

Do you think it will be possible to port it in the nearer future or would it be better to change the boards to Ramps?
Is there any way to support the repetier port without any knwwoledge about how to use an analyzer?

Kind regards and thanks for keeping the project alive!

198

Re: Davinci Jr Repetier Port

Getting the communication with u17 working is going to be tricky. I'd grab an MKS Gen board to minimize the number of connectors you need to change, and just keep the original board handy in case the port ever happens

199

Re: Davinci Jr Repetier Port

pyr0ball wrote:

Getting the communication with u17 working is going to be tricky. I'd grab an MKS Gen board to minimize the number of connectors you need to change, and just keep the original board handy in case the port ever happens

Have you talked to nilezon about the JTAG hacking, he seems to have lots of experience on JTAG and might provide different angle to it.

http://www.soliforum.com/topic/16879/da … ag-access/

(Da Vinci 1.0, Jr. 1.0 RAMPS, miniMaker) X4, (Creality CR-10S, CR-10 mini, Ender-3) X4, Anycubic MEGA X4, Anycubic Chrion X1, ADMILAB Gantry X2 (MonoPrice Maker Select V2, Plus, Ultimate)X4--Select mini X1, Anycubic photon X4, Wanhao duplicate D7 X1.
iNSTONE Inventor Pro X2, CTC Dual X2, ANET-A8, Hictop 3DP-11, Solidoodle Press, FLSUN I3 2017X1

200

Re: Davinci Jr Repetier Port

No I haven't. Been working on my diy printer lately tongue

https://youtu.be/tgtFHiUZ6DE