Free (GPLv2) TCP/IP stack developed by TASS Belgium

Dependents:   lpc1768-picotcp-demo ZeroMQ_PicoTCP_Publisher_demo TCPSocket_HelloWorld_PicoTCP Pico_TCP_UDP_Test ... more

PicoTCP. Copyright (c) 2013 TASS Belgium NV.

Released under the GNU General Public License, version 2.

Different licensing models may exist, at the sole discretion of the Copyright holders.

Official homepage: http://www.picotcp.com

Bug tracker: https://github.com/tass-belgium/picotcp/issues

Development steps:

  • initial integration with mbed RTOS
  • generic mbed Ethernet driver
  • high performance NXP LPC1768 specific Ethernet driver
  • Multi-threading support for mbed RTOS
  • Berkeley sockets and integration with the New Socket API
  • Fork of the apps running on top of the New Socket API
  • Scheduling optimizations
  • Debugging/benchmarking/testing

Demo application (measuring TCP sender performance):

Import programlpc1768-picotcp-demo

A PicoTCP demo app testing the ethernet throughput on the lpc1768 mbed board.

Committer:
tass
Date:
Thu Jan 28 15:12:00 2016 +0100
Revision:
155:a70f34550c34
Parent:
29:1a47b7151851
Adding TCP flag for FIN.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
daniele 29:1a47b7151851 1 #ifndef __PICOMUTEX__
daniele 29:1a47b7151851 2 #define __PICOMUTEX__
daniele 29:1a47b7151851 3 /*
daniele 29:1a47b7151851 4 * Cross-Threading Mutex Class
daniele 29:1a47b7151851 5 */
daniele 29:1a47b7151851 6
daniele 29:1a47b7151851 7 #include "mbed.h"
daniele 29:1a47b7151851 8 #include "rtos.h"
daniele 29:1a47b7151851 9 #include "Queue.h"
daniele 29:1a47b7151851 10
daniele 29:1a47b7151851 11 class PicoCondition
daniele 29:1a47b7151851 12 {
daniele 29:1a47b7151851 13 private:
daniele 29:1a47b7151851 14 Queue <int,1> * queue;
daniele 29:1a47b7151851 15 public:
daniele 29:1a47b7151851 16 PicoCondition()
daniele 29:1a47b7151851 17 {
daniele 29:1a47b7151851 18 queue = new Queue<int,1>();
daniele 29:1a47b7151851 19 }
daniele 29:1a47b7151851 20
daniele 29:1a47b7151851 21 ~PicoCondition()
daniele 29:1a47b7151851 22 {
daniele 29:1a47b7151851 23 if(queue)
daniele 29:1a47b7151851 24 {
daniele 29:1a47b7151851 25 delete queue;
daniele 29:1a47b7151851 26 queue = NULL;
daniele 29:1a47b7151851 27 }
daniele 29:1a47b7151851 28 }
daniele 29:1a47b7151851 29
daniele 29:1a47b7151851 30 bool unlock(uint32_t millisec=0,int * ptr=NULL)
daniele 29:1a47b7151851 31 {
daniele 29:1a47b7151851 32 osStatus status;
daniele 29:1a47b7151851 33 status = queue->put(ptr, millisec);
daniele 29:1a47b7151851 34 return (status == osEventMessage || status == osOK);
daniele 29:1a47b7151851 35 }
daniele 29:1a47b7151851 36
daniele 29:1a47b7151851 37 bool lock(uint32_t millisec=osWaitForever)
daniele 29:1a47b7151851 38 {
daniele 29:1a47b7151851 39 osEvent event = queue->get(millisec);
daniele 29:1a47b7151851 40 return (event.status == osEventMessage || event.status == osOK);
daniele 29:1a47b7151851 41 }
daniele 29:1a47b7151851 42 };
daniele 29:1a47b7151851 43
daniele 29:1a47b7151851 44
daniele 29:1a47b7151851 45 #endif