← Back to team overview

kicad-developers team mailing list archive

Re: Library woes (was Symbol library for FTDI chips)

 



> You can do this on a website, and that would be my preference.  The interface to fetch the
> footprint into Pcbnew can be in C++ using a PLUGIN. 


http://wiki.wxwidgets.org/WxHTTP

http://docs.wxwidgets.org/trunk/classwx_h_t_t_p.html


Seems to be a cross platform http client that might make it pretty easy to grab a
footprint in s-expression form.
Once retrieved, you can then simply instantiate a PCB_IO and parse it:

MODULE*    module;
PCB_IO     pcb_io;


module = dynamic_cast<MODULE*>( pcb_io.Parse( sexpression_from_http ) );

return module;

The above gives you an idea on how to code the HTTP_PLUGIN::FootprintLoad() function.

Most of the work might be on the website I'd guess.  When POSTing or GETing, the query
strings or request parameters tell the website what to do.


It might make you a rock star. 

I mean a bigger one than you already are.




References