Searching \ for '[PIC]: I2C sample code (not asking, giving)' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page:
Search entire site for: 'I2C sample code (not asking, giving)'.

Exact match. Not showing close matches.
PICList Thread
'[PIC]: I2C sample code (not asking, giving)'
2000\12\04@230312 by Matt Bennett

A while back, I posted a question about sample code using the MSSP on an
and there was a resounding silence, except for a few people pointing to
Microchip's AN734 and AN735.  After much frustration, I tweaked the code
there enough to make me confident enough to be pretty sure how it
works.  I never could figure out how to get the code as provided to work
(I couldn't get MPLAB to use the linker scripts as provided).  So I
incorporated them into one piece of code.

In case you're interested in looking at this code, here's pointers to
what I've
been working on:

If you look at this page:
under the December 4, 2000 entry, I also have some screen captures of
I2C in action.
To tell you the truth, I'm not *completely* sure what is happening at
the end of
the transfer, but it appears to work, so for now, I'm happy.


-- hint: The list server can filter out subtopics
(like ads or off topics) for you. See

2000\12\05@033947 by Morgan Olsson

picon face
Thanks for sharing, Mark.
I hope and believe somebody will get helped by it.

-Maybe me next year :)


-- hint: The PICList is archived three different
ways.  See for details.

2000\12\05@044617 by Soren Knudsen


Thanks Matt!

I have to use the mssp module of a pic16f874 in the months or so for a
project. I was just begun to read about this module yesterday. -These .asm's
will help me VERY much. Thank you, thank you, thank you...

Soren K

> {Original Message removed}

2000\12\05@142228 by Barry Gershenfeld

picon face
>Thanks for sharing, Mark.
>I hope and believe somebody will get helped by it.
>-Maybe me next year :)

Same here...I did a first cut (master only) for a 16F874 but I have
not even had a chance to start testing it.  I've got serial communications
thanks to Fr. McGahee.  I read his code cover to cover in order to
understand the intricacies of the part, and it was an invaluable
education for entry into PIC'dom.

When I get to the I2C part I will probably find myself studying
your code.

Somebody had to be first...I had a friend who used to say "BYTM"
(Better You Than Me) and yes, it always had a :) attached.



-- hint: The PICList is archived three different
ways.  See for details.

2000\12\06@011141 by Victor Ong

Hi Matt,

I must say that your code came at a very good time. I was about to start
using the reference code from AN734 and AN735 (BTW, I am new to PIC and I2C)
to test out the I2C communications. I intend to test out your code on the
ICD. Can I put your master.asm into one ICD and slave.asm into another ICD
and get them to talk to each other via I2C? Please advise me what I should
be taking note of if I want to test out the above.
I am trying to start with a working reference code to learn more on I2C
using PIC.
Please advise. Thanks.


{Original Message removed}

2000\12\11@044929 by Victor Ong

Hi Matt,

While looking through your code in 'master.asm', I realised that you are
using the instruction 'movfw' (eg movfw PORTD). Is there such an
instruction? What's more is that I did not run into any compilation error!

Please advise.Thanks


{Original Message removed}

2000\12\11@045801 by Michael Rigby-Jones

movfw is a macro in MPASM.  It is simply defined as the instruction movf



> {Original Message removed}

More... (looser matching)
- Last day of these posts
- In 2000 , 2001 only
- Today
- New search...