CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Once again 18F6720 and the Embedded Internet

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
LITTLE JON



Joined: 20 Oct 2006
Posts: 5

View user's profile Send private message

Once again 18F6720 and the Embedded Internet
PostPosted: Thu Oct 26, 2006 4:09 am     Reply with quote

The whole kit includes two example programs, and one of these is a small WebServer which displays the current A/D readings, using a C function for "writing" on the Web page.

Is there any function to "read" from the Web page(eg: If I press a toggle button in the Web page the PIC will iluminate a LED)

Sorry if my English is not so good.

THANX
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Thu Oct 26, 2006 1:56 pm     Reply with quote

CCS may have additional example files (perhaps in pre-release stage)
that they don't put on the CD-ROM that comes with the kit.

You should email CCS tech support and ask them about this.
Ttelmah
Guest







PostPosted: Thu Oct 26, 2006 2:38 pm     Reply with quote

It would though be very difficult to do 'as described'. Much easier, if this is a server, feeding data 'to' you, to not have a web page as such, but a simple text file in comma deliminated form, that can just be fetched, and parsed. If it also has to be available for human viewing, then have a web page, that displays the contents of this file, at a different address.

Best Wishes
Mark



Joined: 07 Sep 2003
Posts: 2838
Location: Atlanta, GA

View user's profile Send private message Send e-mail

PostPosted: Thu Oct 26, 2006 5:21 pm     Reply with quote

It sounds like you are describing what the CGI scripts are doing.
Ttelmah
Guest







PostPosted: Fri Oct 27, 2006 2:41 am     Reply with quote

Far easier to have a dedicated script returning a value, than to try to 'read' the value out of a human readable page (which seems to be what was being asked for). The former would be very 'specific', and I doubt if anybody would have written code to do this.
However some sites are configured so that while you can generate a 'page', you cannot generate your own scripts. On these, the easiest way would be to not have a 'page' as such, but a ftp entry containing the required data in text form, It was this that I was suggesting. Smile

Best Wishes
Mark



Joined: 07 Sep 2003
Posts: 2838
Location: Atlanta, GA

View user's profile Send private message Send e-mail

PostPosted: Fri Oct 27, 2006 6:39 am     Reply with quote

Ttelmah wrote:
Far easier to have a dedicated script returning a value, than to try to 'read' the value out of a human readable page (which seems to be what was being asked for). The former would be very 'specific', and I doubt if anybody would have written code to do this.
However some sites are configured so that while you can generate a 'page', you cannot generate your own scripts. On these, the easiest way would be to not have a 'page' as such, but a ftp entry containing the required data in text form, It was this that I was suggesting. Smile

Best Wishes


I took it that the poster wants to respond to human interaction from his own page running in the PIC. Sounds like you are referring to another web page running on another server and the PIC being able to respond to it. Is this correct?
Ttelmah
Guest







PostPosted: Fri Oct 27, 2006 9:54 am     Reply with quote

It seem to me that this is what he is asking for. In other words the ability to respond to a 'remote' event on another page. If he only wants to update the local page, then obviously this is easy.

Best Wishes
LITTLE JON



Joined: 20 Oct 2006
Posts: 5

View user's profile Send private message

PostPosted: Mon Oct 30, 2006 3:45 am     Reply with quote

What we are trying to do is what Ttelmah describes:to have the ability to respond to a remote event, but not on another page, but on the PIC's supported page.

Unfortunately, we are just students of electronic engineering, and many of your responses are difficult for us to understand. Embarassed

We will maybe try doing something easier: using PHP we will try to send an empty text file with a name that can be recognised by the PIC(eg:"turn_the_light_on.txt")the PIC is allways looking for this file, and when it finds it, the light will be turned on.

The question now is this: Is this PIC able to support PHP?
I think this is an acceptable solution, but is there any solution more simple?

THANX TO EVERYONE FOR YOUR REPLYS Wink
asmallri



Joined: 12 Aug 2004
Posts: 1634
Location: Perth, Australia

View user's profile Send private message Send e-mail Visit poster's website

PostPosted: Mon Oct 30, 2006 7:28 am     Reply with quote

Take a step back and reexamine the overall problem.

Do HAVE to use a web interface?

Can you just send a UPD packet to the PIC?

It is much easier for a PIC to service UDP requests as they require very little CPU resources compared to having to run a HTTP session on top of TCP.
_________________
Regards, Andrew

http://www.brushelectronics.com/software
Home of Ethernet, SD card and Encrypted Serial Bootloaders for PICs!!
Mark



Joined: 07 Sep 2003
Posts: 2838
Location: Atlanta, GA

View user's profile Send private message Send e-mail

PostPosted: Mon Oct 30, 2006 11:46 am     Reply with quote

Quote:
What we are trying to do is what Ttelmah describes:to have the ability to respond to a remote event, but not on another page, but on the PIC's supported page


If it is on the PIC's page that it is serving, then it is not as Ttelmah describes. Why don't you actually tell us what EXACTLY you are trying to do so that we can better help you.
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group