Using the Arduino Eth shie wi AMIS18 (new thread so not so long scroll to end)


Closed Thread
Results 1 to 5 of 5

Hybrid View

  1. #1
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,612

    Default Re: Using the Arduino Eth shie wi AMIS18 (new thread so not so long scroll to end)

    Hi Don,
    I don't know what's up with your thread title but I'm glad it's not exactly the same as mine.

    Anyway, in retrospect I wish I had just called using the W5100 with PBP instead of bringing in AMICUS18 and the "shield word", after all as long as you have a W5100 the code will work, you don't have to have either a AMICUS18 board OR a Arduino Ethernet shield - which you've showed.

    Right, to your comments.
    1- Use word pad to write and test HTML, very easy
    Agreed - if you know HTML.

    2- Jscript & Jquery to make pages more active

    Agreed - if you know JScript and Jquery. Please, if you have time and knowlege write something up that shows and explains how it works!

    3- Save HTML at end of code with 'db'
    Good idea, nice work! Care to show us how you access/read that data? ReadCode? Example?

    4-Wiznet, use PC interface prog to set IP, port ,Server, or client mode, unloads PIC of teedious work

    Not sure I follow you here. There is, as far as I know, no non-volatile memory in the W5100. This means it has to be configured at each powerup and/or reset. This makes it a bit unpractical to using a PC to set its MAC, IP etc - or am I completely misunderstanding?

    5- DHCP not so good if device is server because IP needs to stay static so can be found from outside more easily.
    Yes and no. The DHCP code allows you to pass along a host-name to the DHCP server. I'm definitely no expert on this but it's my understanding that in a typical home enviroment there's a DNS server running on the typical router also acting as the DHCP-server. So it "connects" the name and the IP-adress it "gives" the client with each other. This way you don't have to know the IP adress at all, just browse to "name of the device". After all, you don't have to know the IP-adress of Googles or Crownhills servers in order to reach them, right? If the device is on the "inside" of your internet router then, to access it from the outside, you'd have to browse to IP-adress that your router is assigned from the ISP - it then forwards (if properly setup) the trafic to the W5100 device.

    6- Idea to store a main HTML page on ones local computer (can have been tested and downloaded) and just have PIC send the dynamic data, and thats Jscript and------ Someone can make a formater so HTML ,created and tested with any text prog can be inserted into 'db' asm code with correct punctuation, legnth etc. The "" quotes do not get handled properly.
    Not sure I follow here.... If storing web-pages in the PC why do you need the W5100? Run a web-server on the PC instead. Or do you mean to create the web-page on the PC and then download it to the PIC/W5100 board? In any case some sort of "parameter format" would be needed in the HTML which the PIC replaces with the content of variables etc.

    7- mabye load new pages into flash somehow, without reprog of PIC.

    Yes, this is definitely needed. On the ethernet shield there's a micro SD-card, on my own board I put 8Mbit SPI flash but if the HTML is small enough it could be stored in the PICs flash. The best approach would be if it could be updated over the Ethernet connection but I guess downloading new HTML content over a serial line would work to.

    /Henrik.

  2. #2

    Default Re: Using the Arduino Eth shie wi AMIS18 (new thread so not so long scroll to end)

    Henrik, i wanted to comment to your original post, so I tried to restart a new ref to original, but to add (comment), ran into max chars so I deleted some letters to make room for my comment. But if it would be less confusing, a new named thread could be done.
    Checking a little further, your using the 5100 chip and working closer with its coding compared to the modules where there is less or no directly accessing the networking controller chip, aside from the few basic tcp/ip and serial settings.
    If you havn't yet, try W3schools.com. Covers about everything and free.

    Name:  Capture15.JPG
Views: 3766
Size:  44.7 KB
    The Wiz701 serial to ethernet module I use stores it settings in flash reguarding power-up.

    Code:
    '''-------TX INT ROUTINE-------------AX is start adderss in prog flash------''''
    TRint:
    READCODE AX , B4         'SEND OUT FLASH MEM
    if b4=0 then 
    @ INT_DISABLE TX_INT   
    else
    txreg=b4       
    AX=AX+1                         
    endif
    @ INT_RETURN
    I send with TX interrupt , like you said, readcode and check for 0 to stop transmit. Allows base PIC program to keep going even with send 1-2000 chars

    Don

  3. #3
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,612

    Default Re: Using the Arduino Eth shie wi AMIS18 (new thread so not so long scroll to end)

    Exactly, the W5100. My code targets the W5100 specifically though I think that it, with some minor changes, will work with the new W5200....
    I took for granted you were using a module containing the W5100, like the Wiz810, 811 or 812. If you're using one of their more intelligent modules my code is of little use to you.

    However, mechanisms and routines to store HTML in the PIC and "pushing it" to the chip/module (be it via USART or MSSP module) can likely be done in the same way for both types - and any other ethernet module, like the X-port for example.

    /Henrik.

  4. #4

    Default Re: Using the Arduino Eth shie wi AMIS18 (new thread so not so long scroll to end)

    DHCP for setting PIC Server inside some LAN. You may already be clear this.
    To access PIC Server from outside of its LAN, it needs to be on a specific PORT and set the Router to pass packets destined for PIC from the internet based on that PORT number. On my router, I had to enter a static PIC address and specific PORT that allows packets to pass through. That doesn't change so from outside, IP and PORT # access to PIC stays the same. I'm not sure if some routers can add that routing based on the HOST NAME,instead of IP, that you may set in the 5100.

    IPV6 will change this but thats still evolving as more devices handle the addressing protocols. I think.

    The HTML pages parts stored locally would be because the PIC Server can only handle so much HTML, so that could make pages more functional and appealing while still getting timely data from PIC.

    Don

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts