|
|
View previous topic :: View next topic |
Author |
Message |
Linuxbuilders
Joined: 20 Mar 2010 Posts: 193 Location: Auckland NZ
|
TCP/IP |
Posted: Tue Sep 05, 2017 2:24 am |
|
|
Good day,
Anybody with extensive experience in TCP/IP subject? I am slowly digesting the manuals but I guess I need some guidance before I grow old (oh, I am already old...). I need to make UART2TCP bridge working but I would prefer to clean up this all mess which comes supplied to bare minimum so it does not take 90% of my RAM and move on to custom code to do the job.
18F67J60 is my chip. I cannot compile this at all, all I have managed to do is simple Telnet with TCPget/TCPput going and web server. But really I have some bigger aspirations here. Was looking at BRKLEY sockets as a appropriate method. What do I need to initialize to have this starting up, any TCP/IP lite I could use with it?
Thnx for help. _________________ Help "d" others and then you shell receive some help from "d" others. |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19539
|
|
Posted: Tue Sep 05, 2017 7:48 am |
|
|
What TCP/IP library have you actually got?.
The CCS library works, but is quite limited/old. Most people using TCP port the MicroChip stack. Quite a lot of the core code needs to be there, and it is not small. Just like USB, there is a lot of code involved.
You may find it easier to use the ENC28J60, and let this do some of the work for you.
Go and visit the Brush electronics site. Andrew has done a lot of work on very compact code for Ethernet stuff, and it may save you a lot of work....
His bootloaders are based on a compactly coded Ethernet to serial link. |
|
|
Gabriel
Joined: 03 Aug 2009 Posts: 1067 Location: Panama
|
|
Posted: Tue Sep 05, 2017 3:19 pm |
|
|
3 bucks gets you an ESP8266 and online in minutes.
OR
Gprs or 3g modem.
Both easy options... and the ethernet PICs Get HOT AF... so much it makes me uncomfortable.
G. _________________ CCS PCM 5.078 & CCS PCH 5.093 |
|
|
Linuxbuilders
Joined: 20 Mar 2010 Posts: 193 Location: Auckland NZ
|
|
Posted: Wed Sep 06, 2017 1:52 am |
|
|
Ttelmah wrote: | What TCP/IP library have you actually got?.
The CCS library works, but is quite limited/old. Most people using TCP port the MicroChip stack. Quite a lot of the core code needs to be there, and it is not small. Just like USB, there is a lot of code involved.
You may find it easier to use the ENC28J60, and let this do some of the work for you.
Go and visit the Brush electronics site. Andrew has done a lot of work on very compact code for Ethernet stuff, and it may save you a lot of work....
His bootloaders are based on a compactly coded Ethernet to serial link. |
I use supplied stack from CCS, I may be able to port Microchip as I had a look at it and it is close, but as I am the beast who is to understand things before use I have found large amount of errors and unhappiness from the compiler. Then I had a look and I see 50% finished job here. I agree that other chips can do the job (I use XPORT now) but those chips cannot give me full control over the process, direct programing, etc. I need my own one for that. So 18F67J60 gives me ability to do both but the code in the TCP stack comes with minimalistic support in regards to configuration and understanding what is actually needed to get it going. As I do not have time to read line by line in the code and do reverse eng of it I was hoping to find where to really start here. _________________ Help "d" others and then you shell receive some help from "d" others. |
|
|
RF_Developer
Joined: 07 Feb 2011 Posts: 839
|
|
Posted: Wed Sep 06, 2017 3:36 am |
|
|
Having recently done a LAN application with the CCS stack, I can concur with most of what you say. Yes, the CCS port is minimal: just enough to get you going and no more. Yes, I had to port in a number of features and fix issues. I did look at pre-built solutions such as the X-port, but they didn't offer all the few features I needed, which were inherited from a previous PIC solution using the Microchip stack.
I used a ENC624J600 with 8 bit parallel interface via PMP in a 24HJ128GP504. I've got auto-MDX, dynamic webpages stored in external EEPROM, SCPI commands via sockets, though I baulked at implementing VXI-11 or HiSLIP, though that can relatively easily be bolted on later. It was by no means painless, and yes, the only way for me to make it work was painstaking line by line debugging, but there was absolutely no way I needed, wanted or had the time for understanding the details of the entire stack. I probably only dealt with 30-40%, i.e. the bits I needed to use. All the rest is still black box code to me. If I ever need to use it, then that is when I'll get to know it. I simply haven't got the time or energy to get to grips with it all... and it really is TCP/IP-lite, believe me!
But I have to stress the Microchip stack, and hence the CCS port really are "TCP/IP lite". They are very simplified and lack any security features and a whole lot of other stuff. They are really basic and simple and TCP/IP stacks go and implement only a limited subset of TCP/IP functionality and hardware compatibility.
Are they a good place to start if you are new to TCP/IP? No, possibly not, but if you're using PICs they are one of the very few places where its possible to start. Its that or pretty much nothing.
Would I use it again? Oh yes, now that I know what I'm doing I'd use it. It isn't easy to use, and the documentation is sketchy at best. The dependencies are confusing and unclear. However, I got there. It works. It works very well in fact but it wasn't easy or quick. |
|
|
Linuxbuilders
Joined: 20 Mar 2010 Posts: 193 Location: Auckland NZ
|
|
Posted: Thu Sep 07, 2017 1:58 am |
|
|
RF_Developer wrote: | Having recently done a LAN application with the CCS stack, I can concur with most of what you say. Yes, the CCS port is minimal: just enough to get you going and no more. Yes, I had to port in a number of features and fix issues. I did look at pre-built solutions such as the X-port, but they didn't offer all the few features I needed, which were inherited from a previous PIC solution using the Microchip stack.
I used a ENC624J600 with 8 bit parallel interface via PMP in a 24HJ128GP504. I've got auto-MDX, dynamic webpages stored in external EEPROM, SCPI commands via sockets, though I baulked at implementing VXI-11 or HiSLIP, though that can relatively easily be bolted on later. It was by no means painless, and yes, the only way for me to make it work was painstaking line by line debugging, but there was absolutely no way I needed, wanted or had the time for understanding the details of the entire stack. I probably only dealt with 30-40%, i.e. the bits I needed to use. All the rest is still black box code to me. If I ever need to use it, then that is when I'll get to know it. I simply haven't got the time or energy to get to grips with it all... and it really is TCP/IP-lite, believe me!
But I have to stress the Microchip stack, and hence the CCS port really are "TCP/IP lite". They are very simplified and lack any security features and a whole lot of other stuff. They are really basic and simple and TCP/IP stacks go and implement only a limited subset of TCP/IP functionality and hardware compatibility.
Are they a good place to start if you are new to TCP/IP? No, possibly not, but if you're using PICs they are one of the very few places where its possible to start. Its that or pretty much nothing.
Would I use it again? Oh yes, now that I know what I'm doing I'd use it. It isn't easy to use, and the documentation is sketchy at best. The dependencies are confusing and unclear. However, I got there. It works. It works very well in fact but it wasn't easy or quick. |
Fantastic, I am not alone then, would you share some of your experience then? _________________ Help "d" others and then you shell receive some help from "d" others. |
|
|
bkamen
Joined: 07 Jan 2004 Posts: 1615 Location: Central Illinois, USA
|
|
Posted: Thu Sep 07, 2017 11:17 am |
|
|
How odd I check in today after being away for so long working on Embedded linux and such....
So I'll also chime in...
The CCS TCPIP Stack is Microchips's TCPIP v3.25 stack (last I knew).
It is minimal because back then, Microchip's stack was minimal. We're talking about 10yrs ago too!
Microchip has since moved on and added a LOT to the stack.
I haven't used the Microchip version stack in probably 6yrs. It was on version 6 or so back then. It required Microchip's compilers (C18/C30/C32) to compile it. I also used the XC series compilers for a bit.
Then I got involved in FPGAs and the embedded Linux to run those projects and haven't been back in a while.
One of the last projects I did with CCS and it's TCP stack was in fact an 8 port TCP->Serial board like an Xport (times 8).
but yea... the CCS version is pretty basic -- but that's all there was back then.
Cheers,
-Ben _________________ Dazed and confused? I don't think so. Just "plain lost" will do. :D |
|
|
Linuxbuilders
Joined: 20 Mar 2010 Posts: 193 Location: Auckland NZ
|
|
Posted: Fri Sep 08, 2017 1:06 am |
|
|
New stack seem to be way more powerful to what was then, but it does not compile, there is many define functions to be done to get it going that without spending hours on decoding it is not easy to get it up. I actually considered dropping the whole PIC and CCS all together and move to ARM because it is crazy that in 2017 TPC/IP is in such poor support. The only thing which keeps me on the platform is the fact that I have designed equipment which is using it and it is hell to start over. So at this point XPORT is the way to go but in the end it is too expensive and too limited to what I need. As a time is a factor here, there is no time available for reinventing CCS TCP stack, so if this would be possible to run with some guidance then I guess it would be get it done and settle on it.
What I will do? I will start posting in here skeleton code and compiler output as I go.
I hope together we get it up, if anybody wants to join I will be happy to supply fully functional network card with 1M chip for web on it. This way we can work on the single unit. I will release the circuit and other info on open source terms if needed. I have some 20 cards here which I can give away.
Card -> https://www.dropbox.com/s/26qxc41bhbrw7k2/15048541827940.jpg?dl=0 _________________ Help "d" others and then you shell receive some help from "d" others. |
|
|
|
|
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
|