LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 12-10-2015, 12:53 PM   #1
samSbai
LQ Newbie
 
Registered: Dec 2015
Posts: 1

Rep: Reputation: Disabled
Question Wrapping up cfiles and related dependences to implement them in C++/Windows?


Hello,

I have an assignment to write a program to implement i2c communication between a temp sensor and the Adafruit FT232H Breakout board (https://learn.adafruit.com/adafruit-...akout/overview).

The end result is this running on a Linux computer, and they did not want it implemented in python like the examples, so I decided on using the suggested C library, libmpsse,(https://code.google.com/p/libmpsse/).

after installing the libftdi library that it needs, as well as the libpmpsse code. I was able to get the .c code working, using the make provided.

There Make(
LDFLAGS= -lmpsse

all: spiflash spiflashfast i2ceeprom ds1305 gpio bitbang

spiflash:

spiflashfast:

i2ceeprom :
$(CC) $(CFlags) i2ceeprom.c -o i2ceeprom $(LDFLAGS)

ds1305:

clean:
rm -f* .dsym
rm -f spiflash spiflashfast i2ceeprom ds1305 gpio bitbang

distclean: clean

)


What I am hoping to be able to do, is take all the required library's and wrap it all together in one package (cmake?) With the end result being single functions in a c++ file that will be able to run the functions in my .c code.

Thanks for any ideas or help you might have,
If my explanation is a little weird I would be happy to explain better.
 
Old 12-14-2015, 11:31 AM   #2
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,882
Blog Entries: 13

Rep: Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930
Why don't you start by completing the assignment of writing a program to implement I2C communications between a temp sensor and the Adafruit FT232H Breakout board, and have that running on a Linux computer, where you did not use Python as your source?

Or are you saying that you've already technically completed the assignment and you're just looking for improvements as well as cross platform portability?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Implement a linux proxy server in windows environment Tomy_5684 Linux - General 1 01-10-2014 05:53 AM
how to implement java code on PuTTY on a windows computer? pras.prag@gmail.com Linux - Software 5 06-11-2013 10:33 AM
[SOLVED] Counting the number of cfiles in a project Ajit Gunge Linux - Newbie 1 06-15-2010 07:09 AM
Wrapping Windows Drivers (Ubuntu 6.10) Pun Linux - Wireless Networking 7 08-16-2007 11:16 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 06:28 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration