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

ENC28J60 and PIC24 compatibility
Goto page 1, 2  Next
 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
Franck26



Joined: 29 Dec 2007
Posts: 122
Location: Ireland

View user's profile Send private message

ENC28J60 and PIC24 compatibility
PostPosted: Mon Sep 14, 2009 5:41 am     Reply with quote

Hello,

I would like to use the ENC28J60 connected to a PIC24 to make a simple TCP/IP server.

Do you know if the CCS ENC28J60 driver is compatible with the PIC24?

Does anybody has already implemented a server using the ENC28J60 and a PIC24? Is there any problems?

Thanks,
Franck.
bkamen



Joined: 07 Jan 2004
Posts: 1615
Location: Central Illinois, USA

View user's profile Send private message

PostPosted: Mon Sep 14, 2009 11:18 am     Reply with quote

It's an SPI based device. I imagine it would work just fine with the PIC24 family.


It's a 3.3V device... and the PIC24's are 3.3V as well.

Sounds like a match made in heaven. (or as MCHP would have you believe!)


Hahaha, good luck!

-Ben
_________________
Dazed and confused? I don't think so. Just "plain lost" will do. :D
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Mon Sep 14, 2009 12:49 pm     Reply with quote

The question is really, do the CCS TCP/IP drivers work with the PCD
compiler ? Have they been tested with it ? Also, there are two
sets of drivers. One is shipped as part of the CCS TCP/IP package,
which is downloadable on the compiler update page with a separate
button. The other drivers are shipped with each compiler update.
These two sets are not necessarily in sync. Again, the question is,
do either of these sets of drivers work with the PCD compiler, and
specifically with the ENC28J60 ?

If no one has a definitive answer on that, you need to email CCS support and ask them.
bkamen



Joined: 07 Jan 2004
Posts: 1615
Location: Central Illinois, USA

View user's profile Send private message

PostPosted: Mon Sep 14, 2009 1:36 pm     Reply with quote

That's a good question -- I see Microchip has a PICtail module for the Explorer 16, which I have... (with a 24 series IC on it)

I think I might order me one so I can test it out since I think I foresee a use for such a device in a project I'm currently working on.


-Ben

EDIT: I ordered the PICtail plug-in for my explorer16 to try this out. I should have the module on thursday.
_________________
Dazed and confused? I don't think so. Just "plain lost" will do. :D
Franck26



Joined: 29 Dec 2007
Posts: 122
Location: Ireland

View user's profile Send private message

PostPosted: Thu Sep 17, 2009 2:24 pm     Reply with quote

Hi,
Thanks for your answer and sorry for the lateness of this reply (was traveling...).

@bkamen:
You are right, I don't think that I'll have any hardware issue to connect the ENC28J60 to a PIC24.
Please, let me know if you can make your PICtail working with the CCS librairy Smile.

@PCM programmer:
In the TCP.c header:
Code:
* Processor:       PIC18, PIC24F, PIC24H, dsPIC30F, dsPIC33F

So I suppose the TCP/IP stack is compatible. I didn't check if each file that I need has this line. Anyway, I would feel more comfortable if someone tell me that he has actually connected a PIC24 to a ENC28J60 and that it works...
The ENC28J60 driver doesn't have any processor compatibility on its header...

As you said, if nobody on the forum has already tested that, I'll send an email to the CCS support.

Thanks,
Franck.
bkamen



Joined: 07 Jan 2004
Posts: 1615
Location: Central Illinois, USA

View user's profile Send private message

PostPosted: Thu Sep 17, 2009 3:04 pm     Reply with quote

I just got my PICtail for the explorer16 today... I'll get to it tomorrow or saturday (work work work!)

:D

-Ben
_________________
Dazed and confused? I don't think so. Just "plain lost" will do. :D
Franck26



Joined: 29 Dec 2007
Posts: 122
Location: Ireland

View user's profile Send private message

PostPosted: Fri Sep 18, 2009 1:59 am     Reply with quote

I had never realized how cheap are those microchip demo kit...
I'm going to purchase one too Very Happy .

Franck.
bkamen



Joined: 07 Jan 2004
Posts: 1615
Location: Central Illinois, USA

View user's profile Send private message

PostPosted: Mon Sep 21, 2009 1:30 am     Reply with quote

still working on conversion... hopefully know tomorrow...
_________________
Dazed and confused? I don't think so. Just "plain lost" will do. :D
bkamen



Joined: 07 Jan 2004
Posts: 1615
Location: Central Illinois, USA

View user's profile Send private message

PostPosted: Tue Sep 22, 2009 12:17 pm     Reply with quote

I'm almost done getting an HTTP server running on the board (I hope at least) but ran into a weird PCD issue which I have submitted to CCS.

The program halts because of a function called that isn't declared when it for sure as heck is.

PCH compiles just fine. PCD does not.. so I emailed them the project to take a look.

I need this stack running because of another project I'm working on that might need to jump to PIC24H because of PIC18 performance issues.

More when I have it.

-Ben
_________________
Dazed and confused? I don't think so. Just "plain lost" will do. :D
bkamen



Joined: 07 Jan 2004
Posts: 1615
Location: Central Illinois, USA

View user's profile Send private message

PostPosted: Wed Sep 23, 2009 2:00 pm     Reply with quote

OK, I can compile successfully... but it only runs for a short moment and then resets. (debugger regardless)

So I have more chasing down to do.

Weee...

-Ben
_________________
Dazed and confused? I don't think so. Just "plain lost" will do. :D
Franck26



Joined: 29 Dec 2007
Posts: 122
Location: Ireland

View user's profile Send private message

PostPosted: Fri Sep 25, 2009 1:33 pm     Reply with quote

Have you been able to connect the module via Ethernet during this short moment?
if it is the case, that's already great Razz !!!

Good luck, and keep us informed!!!

Franck.
bkamen



Joined: 07 Jan 2004
Posts: 1615
Location: Central Illinois, USA

View user's profile Send private message

PostPosted: Fri Sep 25, 2009 2:02 pm     Reply with quote

The 28J60 PICtail module initializes (the link/data LED's come to life) -- but the firmware resets before I can do anything else. I'm going to be spending some of today chasing it down.

So I would have to say that the module works... something somewhere is busted and I need to find it.
_________________
Dazed and confused? I don't think so. Just "plain lost" will do. :D
asmallri



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

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

PostPosted: Fri Sep 25, 2009 3:53 pm     Reply with quote

bkamen wrote:
The 28J60 PICtail module initializes (the link/data LED's come to life) -- but the firmware resets before I can do anything else. I'm going to be spending some of today chasing it down.

So I would have to say that the module works... something somewhere is busted and I need to find it.


I suggest looking for any word alignment issues.
_________________
Regards, Andrew

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



Joined: 07 Jan 2004
Posts: 1615
Location: Central Illinois, USA

View user's profile Send private message

PostPosted: Fri Sep 25, 2009 4:05 pm     Reply with quote

Hahah, it's funny you mention that--- I've been doing just that.

:D

-Ben
_________________
Dazed and confused? I don't think so. Just "plain lost" will do. :D
FvM



Joined: 27 Aug 2008
Posts: 2337
Location: Germany

View user's profile Send private message

PostPosted: Fri Sep 25, 2009 4:34 pm     Reply with quote

Did you try to use the address error trap to locate resets caused by data alignment errors?
http://www.ccsinfo.com/forum/viewtopic.php?t=36479

The other "popular" reason for PIC24 resets is PCD's too small default stack assignment. http://www.ccsinfo.com/forum/viewtopic.php?t=40083
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Goto page 1, 2  Next
Page 1 of 2

 
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