More on wireless uploading

As usual, even best-laid plans face hardship, so now I can wireless upload g-code files to the USB memory connected to a DDCSV1.1 CNC controller. But, once I factor in not to upload a code line before I have got the remote echo of it, things get really slow. Like ten minutes per megabyte.

Yes, I wanted it to be wireless. I could accept a not so fast upload speed, but 13 Kbps is not ok as we handle files in the 1-10 MByte range usually. A few seconds is ok, but half an hour or more is not.

So I came up with yet another approach that would recycle some old-tech that I discarded years ago: There was a USB dongle that would accept an SD card and it would work as a USB pen driver but with a twist: the unit did also have wifi connectivity. So the users could access the content of the SD card wirelessly as a network disk. That was cool and made totally unnecessary (apparently) my previous work but, there was a catch: The device would work either as a pen drive (as soon as you connect it to a computer) or as a wireless network device (as soon as you eject the unit from your system but keep the dongle connected so it is still powered by the computer).

Using such a unit would just not be possible on our CNC controller as there is no provision for USB eject, and having to physically remove the unit every time a new upload happened wirelessly would defeat the purpose of a wireless upload in the first place.

Fortunately, there is a lot of information from several hacking groups that come in handy here. It turns out the ZSUN Wifi USB Card reader runs Linux and it has some open holes, like a telnet server on port 11880 where you can log in as root with zsun1188 password.

The transition from USB drive to a wireless network drive (a samba server) can be triggered by this URL: http://10.168.168.1:8080/goform/Setcardworkmode?workmode=0 (provided your computer is already associated with the wireless network created by the device (named zsun-sdXXXXXXXX). If you do that, your computer might complain about the memory being removed abruptly. Moments later you are able to connect to the network drive smb://admin@10.168.168.1/public with no password.

Wireless transfers to this network device can reach around 10 Mbps (a thousand times faster of my previous solution) which is enough for my needs. Once a transfer is over, the device may be restored to work as a USB pen drive (no need to unplug and plug it again) by accessing the URL: http://10.168.168.1:8080/goform/Setcardworkmode?workmode=1 and your computer will think you just plugged in a new pen drive. Or in my case, the newly uploaded files will be seen by the CNC controller and the operator could choose one and start it.

With this new approach, there is no need to solder, open the box or buying a USB hub to deliver g-code files to your CNC controller wirelessly.


Comments

Popular posts from this blog

VFD control with Arduino using RS485 link

How to get sinusoidal s-curve for a stepper motor

Stepper motor step signal timing calculation