Author

Topic: Using functions from api.c in cgminer (Read 252 times)

legendary
Activity: 4466
Merit: 1798
Linux since 1997 RedHat 4
May 17, 2019, 07:16:56 PM
#2
Hello!

I am creating my own application for manage of Antminer S9.
I found source with API here: https://github.com/ckolivas/cgminer
And there is file api.c with functions i need and example in api-example.c
But how i can use API from api.c and create my own application for send command?

Is it possible to create library from cgminer for using functions in my C++ project? How is possible to use functions from this project?
I put an example in C, Java, PHP and there's also an example in Python and Ruby.
Look for the word api in the filenames.
If that doesn't help, you'll not be able to write anything anyway.
It's a simple socket, you just send a command and get a reply then close the socket.
The "library" is called socket programming.
newbie
Activity: 14
Merit: 0
May 16, 2019, 07:09:48 AM
#1
Hello!

I am creating my own application for manage of Antminer S9.
I found source with API here: https://github.com/ckolivas/cgminer
And there is file api.c with functions i need and example in api-example.c
But how i can use API from api.c and create my own application for send command?

Is it possible to create library from cgminer for using functions in my C++ project? How is possible to use functions from this project?
Jump to: