You are not logged in.

#1 2021-01-24 09:00:43

ConsummatePro
Member
Registered: 2021-01-24
Posts: 18

Phrozen Transform: can't generate calibration plates - Could Not Write

I followed terrific the write up by Frank Collingwood at the FB Phrozen Transform group and have NanoDLP running on the Transform - it's doing the first print right now and looking forward to the results.

The problem is if I try to generate a calibration plate, the Plates screen says "! The plate is not sliced yet" and I see an error at the bottom of the screen saying:
Could Not Write to JSON File public/plates/3/plate.json open public/plates/3/plate.json: no such file or directory in the module JSON according to the logs.

I tried with both Armbian Buster as well as Armbian Focal. I'm using the suggested username by Frank and his script "pi"

Is this a permissions issue or a bug? Top right corner on the NanoDLP webpage says "Phrozen Transform -  Build 4264"

Last edited by ConsummatePro (2021-01-24 09:50:02)

Offline

#2 2021-01-24 09:41:00

Shahin
Administrator
Registered: 2016-02-17
Posts: 3,517

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

It seems folder not created due to permission error. Usually nanodlp require root access eventhough it is possible to run it with lower privilege.
SSH into device and use mkdir and ls -l commands to inspect folders permission.

Offline

#3 2021-01-24 10:01:35

ConsummatePro
Member
Registered: 2021-01-24
Posts: 18

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

Thanks for the reply - Here's what I get for ls -l if logged in as the pi user (which is what the FB setup script sets up):

pi@phrozen-transform:~/printer/public$ ls -l
total 420
-rw-rw-r-- 1 pi   pi   314123 Jan 15 09:04 alert.ogg
drwxrwxr-x 5 pi   pi     4096 Jan 15 09:04 boot3
drwxrwxr-x 2 pi   pi     4096 Jan 15 09:04 css
-rw-rw-r-- 1 pi   pi     5430 Jan 15 09:04 favicon.ico
drwxr-xr-x 2 pi   pi     4096 Jan 15 09:04 general
-rw-rw-r-- 1 pi   pi    18174 Jan 15 09:04 icon.png
-rw-rw-r-- 1 pi   pi    11729 Jan 15 09:04 index.html
drwxrwxr-x 2 pi   pi     4096 Jan 15 09:04 js
drwxr-xr-x 2 pi   pi     4096 Jan 15 09:04 lang
-rw-rw-r-- 1 pi   pi     2698 Jan 15 09:04 logo.png
-rw-rw-r-- 1 pi   pi    10644 Jan 15 09:04 placeholder.jpg
drwxrwxr-x 4 pi   pi     4096 Jan 24 00:53 plates
drwxrwxr-x 2 pi   pi     4096 Jan 15 09:04 shots
-rwxrwxr-x 1 pi   pi    17068 Jan 15 09:04 slkscr.ttf
-rw-r--r-- 1 root root    378 Jan 24 01:56 status.json
drwxrwxr-x 4 pi   pi     4096 Jan 15 09:04 wpaint

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

pi@phrozen-transform:~/printer/public/plates$ ls -l
total 72
drwxr-xr-x 2 root root  4096 Jan 24 00:53 0
drwxr-xr-x 2 root root 69632 Jan 24 01:02 2

The permissions for directory plates/0 and plates/2 are set for root, it seems but "plates" itself is set for pi user  - how would I fix this so NanoDLP will write to this dir?

Offline

#4 2021-01-24 10:55:05

Shahin
Administrator
Registered: 2016-02-17
Posts: 3,517

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

chown will be enough but it should be set to a user which run nanodlp.
Could you let me know how nanodlp being run?

Offline

#5 2021-01-24 19:14:14

ConsummatePro
Member
Registered: 2021-01-24
Posts: 18

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

I think the script has nanodlp running as user pi. Looking at the setup script, it's being installed in /home/pi/printer
===

display_msg "Installing necessary libraries for nanoDLP on Armbian Buster. This will take a while. You can safely ignore any error messages"
apt install -qq -y ntfs-3g pmount debhelper build-essential lockfile-progs avahi-daemon

cd
mkdir -p /usr/src/
git clone https://github.com/kgara/usbmount/ --depth 1 > /dev/null
cd ./usbmount
dpkg-buildpackage -us -uc -b > /dev/null
dpkg -i ../usbmount_0.0.24_all.deb > /dev/null

display_msg "Installing nanoDLP"
mkdir /home/pi/printer
cd /home/pi/printer
wget https://www.nanodlp.com/download/nanodlp.arm.zip > /dev/null
unzip nanodlp.arm.zip > /dev/null
sed -i 's/#!\/bin\/bash/#!\/bin\/bash\nsudo setterm -foreground black -background black -store\nsudo setterm -cursor off\ngpio mode 1 output/' /home/pi/printer/run.sh
echo "generic" > /home/pi/printer/build

display_msg "Setting up logrotate"
cat << EOF> /etc/logrotate.d/printer
/var/log/printer.log {
    rotate 12
    compress
    missingok
    notifempty
    size=10k
    copytruncate
    su root
}
EOF

cp /etc/cron.daily/logrotate /etc/cron.hourly/

display_msg "Setting up automatc startup"
cat << EOF> /etc/systemd/system/nanodlp.service
[Unit]
Description=NanoDLP service
After=basic.service

[Service]
WorkingDirectory=/home/pi/printer
ExecStart=/bin/bash /home/pi/printer/run.sh
Restart=always
RestartSec=5

[Install]
WantedBy=multi-user.target
EOF

systemctl enable nanodlp
sed -i 's/PrivateMounts=yes/PrivateMounts=no/g' /lib/systemd/system/systemd-udevd.service

=======

Last edited by ConsummatePro (2021-01-24 19:15:23)

Offline

#6 2021-01-24 19:37:13

Shahin
Administrator
Registered: 2016-02-17
Posts: 3,517

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

chmod -R pi:pi folder_name

Offline

#7 2021-01-24 19:46:24

ConsummatePro
Member
Registered: 2021-01-24
Posts: 18

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

I didn't change any permissions yet but just imported an stl and it immediately started slicing and didn't complain about the directory. While it is slicing the stl, I tried generating another plate and it gives the same error.

https://www.dropbox.com/s/zz8n1cf6pn41d … M.png?dl=0

Edit: now the stl plate is saying "This plate is corrupt." so I guess the problem is still there?

Last edited by ConsummatePro (2021-01-24 22:54:57)

Offline

#8 2021-01-25 09:16:58

ConsummatePro
Member
Registered: 2021-01-24
Posts: 18

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

I just re-imaged the sd card and started again from fresh - same problem.

If I check the directories, it all seems to be ok for user pi:
phrozen-transform:printer:# ls -l public
total 420
-rw-rw-r-- 1 pi   pi   314123 Jan 15 09:04 alert.ogg
drwxrwxr-x 5 pi   pi     4096 Jan 15 09:04 boot3
drwxrwxr-x 2 pi   pi     4096 Jan 15 09:04 css
-rw-rw-r-- 1 pi   pi     5430 Jan 15 09:04 favicon.ico
drwxr-xr-x 2 pi   pi     4096 Jan 15 09:04 general
-rw-rw-r-- 1 pi   pi    18174 Jan 15 09:04 icon.png
-rw-rw-r-- 1 pi   pi    11729 Jan 15 09:04 index.html
drwxrwxr-x 2 pi   pi     4096 Jan 15 09:04 js
drwxr-xr-x 2 pi   pi     4096 Jan 15 09:04 lang
-rw-rw-r-- 1 pi   pi     2698 Jan 15 09:04 logo.png
-rw-rw-r-- 1 pi   pi    10644 Jan 15 09:04 placeholder.jpg
drwxrwxr-x 2 pi   pi     4096 Jan 15 09:04 plates
drwxrwxr-x 2 pi   pi     4096 Jan 15 09:04 shots
-rwxrwxr-x 1 pi   pi    17068 Jan 15 09:04 slkscr.ttf
-rw-r--r-- 1 root root    291 Jan 25 00:50 status.json
drwxrwxr-x 4 pi   pi     4096 Jan 15 09:04 wpaint

--- and ls-l of the public/plates folder:
drwxrwxr-x 2 pi   pi     4096 Jan 15 09:04 plates

also, after uploading a .zip sliced file, NanoDLP generates a plate no problem but interestingly the plates are user **root**:
phrozen-transform:plates:# ls -l
total 72
drwxr-xr-x 2 root root  4096 Jan 25 00:55 0
drwxr-xr-x 2 root root 69632 Jan 25 00:56 1

I'm not sure that plate "0" is: it just has 7 png files named 1.png-1.png, no json file. Plate "1" is the newly imported file that it literally printing right now.

When I generate the calibration, it throws the "could not write" error. Here's what the log shows:

Error    6    2021-01-25 01:09:19.620277    JSON    Could Not Write to JSON File public/plates/2/plate.json open public/plates/2/plate.json: no such file or directory
Error    6    2021-01-25 01:09:19.619769    JSON    Could Not Write to JSON File public/plates/2/plate.json open public/plates/2/plate.json: no such file or directory

Is the JSON module needing a different permission? Is the slicer also affected?

Offline

#9 2021-01-25 13:47:44

Shahin
Administrator
Registered: 2016-02-17
Posts: 3,517

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

Send me an email lets do anydesk, it is very small issue, probably installation script could not handle an edge case on your system.

Offline

#10 2021-01-27 07:32:41

ConsummatePro
Member
Registered: 2021-01-24
Posts: 18

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

email sent...

Offline

#11 2021-01-27 10:36:29

Shahin
Administrator
Registered: 2016-02-17
Posts: 3,517

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

Answered please check

Offline

#12 2021-03-24 03:54:10

soma
Member
Registered: 2021-03-24
Posts: 1

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

@ConsummatePro  I've just gotten a Phrozen Transform as well, and would really like to get an open version of NanoDLP running.  Very glad that you have tried!!  Heartening to hear that there is some progress even when there are still issues.  I'll let you know how I get along.

Offline

#13 2021-03-24 06:25:58

ConsummatePro
Member
Registered: 2021-01-24
Posts: 18

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

I've gotten the Transform working amazingly well with nanoDLP - with Shahin's and Frank Collingwood's (on the FB Transform group) help, almost all features are now working properly including large sliced files, a way to get a 5" Nextion display working (sadly, we can't use the Transform's display), etc. You can find posts and how-to's at:

Initial install guide:
https://www.facebook.com/groups/2198751 … 705622731/

Updated installer by me:
https://www.facebook.com/groups/2198751 … 845091583/

Info on the Nextion 5" interface (and a followup post on a 3d printed adapter to mount inside your Transform!
https://www.facebook.com/groups/2198751 … 595709008/

Last edited by ConsummatePro (2021-03-24 06:28:31)

Offline

#14 2021-12-13 05:23:49

R3dfuel
Member
Registered: 2021-12-13
Posts: 4

Re: Phrozen Transform: can't generate calibration plates - Could Not Write

@conummatePro I managed to follow your settings along with Franks but now the only thing I can't for the love of printing make the Mono LCD turn on. I've done test prints and they all go according to the settings but the LCD won't turn on the images. Very little info that I can get and I"m still looking around how do I get the Mono LCD that we got from Grace to turn on. Could you shine some light when you get a chance. Thank you!

Offline

Board footer

Powered by FluxBB