logo Welcome, Guest. Please Login or Register.
July 22, 2018, 04:30:34 AM
Home Help Search Login Register
 News: You can search the forum for answers to your question in a previous discussion. Please click on the "Search" button above and enter the keyword to search. To get to the full discussion of a listed message, please click on the TITLE of the message listed in the search listing.

  Internet PLC Forum
  General
  Frequently Asked Questions
(Moderator: support)
  Storing Web pages in Nano-10 & FMD PLCs
? previous next ?
Pages: [1] Go Down Reply Notify of replies Send the topic Print
   Author  Topic: Storing Web pages in Nano-10 & FMD PLCs  (Read 4795 times)
support
Global Moderator
*****

Posts: 3070





View Profile WWW E-Mail
Storing Web pages in Nano-10 & FMD PLCs
« on: February 24, 2011, 02:36:57 AM »
Reply with quote

The Nano-10, FMD and F-series PLCs only have 60K bytes of file space to store user's control web page.

These PLCs use a very simple file system. File name can only start with one character (0,1,2,....9,A,B,C....)and can have only 3 character extension.

Each file name is allotted 2K bytes of space but each file name can occupy multiple slots, in which case it takes over the space of other files.

That means 0.xxx will occupy the first 2K bytes, 1.xxx will occupy the next 2K bytes, and so on. A file may extend beyond its own allocated file space and take over the space of its adjacent files.

E.g. 0.xxx can occupy the space of 1.xxx and 2.xxx, therefore allowing you to store a file that is up to 6K bytes long. However, that also means you cannot store any file with name 1.xxx or 2.xxx or it will overwrite the data. Your next file should occupy file name from 3.xxx onwards.

The default control web pages 0.htm is > 2K bytes but < 4K bytes, and therefore occupy the space of 0.xxx and 1.xxx. The second control web page is therefore stored at 2.htm. If you need to store your own special files, such as small JPG or CSS file, they can be stored from 4.xxx up to before N.xxx.

More complex graphics or css file can be stored on any internet or intranet webserver (or stored in the TLServer's /public folder) instead of on the CPU flash memory.
« Last Edit: February 24, 2011, 02:38:49 AM by support » Report to moderator   Logged

Email: support@triplc.com
Tel: 1-877-TRI-PLCS
ssiewert
Newbie
*

Posts: 13





View Profile
Problem Storing small jpeg
« Reply #1 on: January 11, 2013, 02:25:36 PM »
Reply with quote

My goal is to have the background image on the Nano so I don't need internet connection or a server of any kind for storing the background.  I've shrunk the jpeg file to under 16K, and tried storing at ip:port/a.jpg and it doesn't seem to work.  Removed file, tried then at c.jpg.  When using a browser to go to ip:port/c.jpg, I get "The image ?http://10.0.1.60:9083/c.jpg? cannot be displayed because it contains errors." in Foxfire: Safari shows nothing.  A few more clues.  The jpeg file opens fine before transfering to the Nano.  It shows it was transfered fine (all 16K or so) in Filezilla.  However, when I bring it back from the Nano to a folder on the PC, it only shows a hair over 2K, so for some reason, it is getting clipped.  Oddly, it leaves a remnant after the transfer of "U.jpg" on the Nano.  The Nano has only the other user file 0.htm (about 3.5K) on it so I really can't think of how the Nano would be short space. The 16K I'd think would occupy A-H, no?  The Nano is r76a, RTC-0 is installed.  Using Trilogi 6.43 over ethernet.
Thanks
Report to moderator   Logged

Murphy may sleep, but he never dies.
support
Global Moderator
*****

Posts: 3070





View Profile WWW E-Mail
Re:Storing Web pages in Nano-10 & FMD PLCs
« Reply #2 on: January 14, 2013, 02:47:15 AM »
Reply with quote

The Nano r76 only supports 62K bytes of web file space. This mean 0.xxx  to 9.xxx, then A.xxx to U.xxx. 

U.JPG only have 2K bytes of space left and you can't put a 16K Jpg file at this space.

Nano-10 webpage requires the 0.htm and N.JS  (later version has been changed to M.JS). 0.htm occupies 4K, that means you can use the space from 2.xxx to L.xxx to store your JPG file. This is 20K bytes of file space which may just fit your JPEG file.

So try to rename your file 2.JPG and refer to it in your HTML file and see if this work out for you.

For PLC with r78 or later firmware you can use FRAM-RTC-256 to expand another 256K bytes of file space for storing webpage for used by the PLC for storing data into files.

« Last Edit: January 14, 2013, 02:48:55 AM by support » Report to moderator   Logged

Email: support@triplc.com
Tel: 1-877-TRI-PLCS
ssiewert
Newbie
*

Posts: 13





View Profile
Re:Storing Web pages in Nano-10 & FMD PLCs
« Reply #3 on: January 24, 2013, 11:45:19 AM »
Reply with quote

Quote from: support on January 14, 2013, 02:47:15 AM
Nano-10 webpage requires the 0.htm and N.JS  (later version has been changed to M.JS). 0.htm occupies 4K, that means you can use the space from 2.xxx to L.xxx to store your JPG file. This is 20K bytes of file space which may just fit your JPEG file.

For PLC with r78 or later firmware you can use FRAM-RTC-256 to expand another 256K bytes of file space for storing webpage for used by the PLC for storing data into files.

I see, yes I had forgotten about the N file, though I knew it was there.  I understand writing it to U would not work, I was commenting that after the described sequence, I had a weird remnant file that showed up at "U".    I'll give it a try starting at "2.xxx", though when I do the math, saving it at "A" or "C" should offer plenty of space, if the slots were actually 2k each (13x2k). 
****update- success with the 16k  jpg stored at 2.jpg****

Clarification on the use of the FRAM-RTC-256. Is it only r78 and later?  Reason I ask is the Appendix A, Extended File system gives the thumbs up to r77 and later.  Has it been discovered r77 has limited functionality since 2011 when Appendix A looks like it was written?
« Last Edit: January 24, 2013, 04:30:29 PM by ssiewert » Report to moderator   Logged

Murphy may sleep, but he never dies.
support
Global Moderator
*****

Posts: 3070





View Profile WWW E-Mail
Re:Storing Web pages in Nano-10 & FMD PLCs
« Reply #4 on: January 24, 2013, 04:42:27 PM »
Reply with quote

Extended file system works fine on Nano-10 and FMD PLC from r77 onwards.

Extended file system on F-series PLC (F2424 and F1616-BA) only works on firmware version r78B onwards.

A bug was discovered in the F-series firmware r77, r78 and r78A rendering it unable to create file > 4K bytes. This bug was fixed in r78B onwards.
Report to moderator   Logged

Email: support@triplc.com
Tel: 1-877-TRI-PLCS
Pages: [1] Go Up Reply Notify of replies Send the topic Print 
? previous next ?
Jump to: 


Login with username, password and session length

Powered by MySQL Powered by PHP Internet PLC Forum | Powered by YaBB SE
© 2001-2004, YaBB SE Dev Team. All Rights Reserved.
Valid XHTML 1.0! Valid CSS!