mcp2515: Initial implementation; C; C++

The mcp2515 is a CAN bus controller.  It was developed using the Seeed
CAN bus shield.

Signed-off-by: Jon Trulson <jtrulson@ics.com>
This commit is contained in:
Jon Trulson
2016-11-10 11:55:48 -07:00
parent 5eb8af6d70
commit fcb4d9d36d
23 changed files with 4129 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
%module javaupm_mcp2515
%include "../upm.i"
%include "typemaps.i"
%include "arrays_java.i"
%include "../java_buffer.i"
%include "std_string.i"
%include "../carrays_uint8_t.i"
%include "mcp2515_regs.h"
%include "mcp2515.hpp"
%{
#include "mcp2515.hpp"
%}
%pragma(java) jniclasscode=%{
static {
try {
System.loadLibrary("javaupm_mcp2515");
} catch (UnsatisfiedLinkError e) {
System.err.println("Native code library failed to load. \n" + e);
System.exit(1);
}
}
%}