<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to create</title><link>https://sourceforge.net/p/digitalemulator/wiki/create/</link><description>Recent changes to create</description><atom:link href="https://sourceforge.net/p/digitalemulator/wiki/create/feed" rel="self"/><language>en</language><lastBuildDate>Thu, 07 Jun 2012 14:08:10 -0000</lastBuildDate><atom:link href="https://sourceforge.net/p/digitalemulator/wiki/create/feed" rel="self" type="application/rss+xml"/><item><title>WikiPage create modified by Majenko Technologies</title><link>https://sourceforge.net/p/digitalemulator/wiki/create/</link><description>**Format:** *void * create(void)*

This is called when the device is created by the *device* configuration directive.  The function should allocate a structure for data storage for this instance of the device.  A pointer (cast to void * ) to this structure should be returned.

Example:
--------

    struct context {
        unsigned int foo;
        float bar;
        char lala[30];
    };

    void *create(void)
    {
        struct context *ctx;
        ctx = malloc(sizeof(struct context));
        return (void *)ctx;
    }

</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Majenko Technologies</dc:creator><pubDate>Thu, 07 Jun 2012 14:08:10 -0000</pubDate><guid>https://sourceforge.net6592e9d16334361d4b63e4444dfe304fe19610e3</guid></item></channel></rss>