@FSL: Problems using IIC module on 9S08QG8

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

@FSL: Problems using IIC module on 9S08QG8

2,096 Views
Oliver
Contributor III

Dear Freescalers,

 

we have just spend days trying go get the IIC module on the QG8 to work, with limited success unfortunately. The QG8 is master with a single slave on the "bus". Our code is not using the complicated interrupt mechanism as described in the application notes on this topic, I like to reserve interrupts for timing critical tasks. I want to keep the code as simple as possible, and sending 2-3 bytes to a peripheral should not require the use of interrupts. The SPI module sure doesn't. And the reference manual does not say so either. 

 

The data sheet is confusing at best, and the application notes only rely on the interrupt approach, and I have yet to find a clear description of the meaning and interaction of the various bits.

 

There is nothing in the errata sheets of the mask set we're using, although after browsing the forum here the problems we are seeing seem to be common (IIC module locking up, waiting for the interrupt flag indefinitely, delays between register accesses, etc.)

 

These problems have been known for years (as evident by the posts in the forum), so I wonder why there is no solution to date. There would be several possibilities:

 

- If there is a problem with the IIC module, please admit it and put it in an updated errata sheet. It's not much work on behalf of FSL, and it can save your customers thousands of hours of accumulated work.

 

- If certain conditions (delays, dependencies, whatever) need to be considered, please put them in the data sheet or at least errata sheet.

 

- Does the customer really have to write a bit-bang driver to reliably shift 2-3 bytes out through the IIC bus when a dedicated module is available on the chip? If that is so, please mention this fact as well in the data sheet. We could have written 3 bit bang drivers in the time it has taken us to realize the various problems associated with the IIC on the QG8 (and other 9S08 IIC modules as well, from what can be read on the forum).

 

Maybe someone at Freescale reads this and finds the time to respond, I am sure many customers would appreciate this.

 

Best regards,

 

Oliver

Labels (1)
0 Kudos
5 Replies

497 Views
jag
Contributor IV

Hi,

 

actually code tends to be simpler if you use interrupts.

And IIC IS time critical, you have to send bits out without delay or jitter or else the other device will not understand you. It's for this that Freescale (and the other UC manufactorer) put a IIC module with interrupts.

 

If you stop complaining and write what is the problem, maybe someone can help you (the crystal sphere is out for repair). 

 

By the way I'm using the QG8 in a project and the IIC module works quite well with an Atmel EEPROM (with interrupts).

 

Bye Jack 

Message Edited by jag on 2009-06-17 03:31 PM
0 Kudos

497 Views
irob
Contributor V

Jag, care to post your code or snippets?  I've been using the bit-baning approach for years myself, but would like to migrate.

 

To be fair to the OP, I too have read lots of scary anecdotal posts about problems with the IIC module.

0 Kudos

497 Views
Oliver
Contributor III

Hi,

 

the point was, the documentation should correspond with the silicon. Period.

If it is required (not just recommended!) to use interrupts, the documentation should say so. Period.

All Freescale employees that I have talked to since were not aware of the problem. Period.

 

If you step through the IIC interrupt routine, you will experience the same problems like a lot of others on the forum did before

they switched to either the "recommended" code or manual bit banging. And the problem is obviously in many derivatives.

I'm sorry, I like to be able to step through my code for whatever reason without locking up the silicon. This does not

build confidence in the silicon if a module has issues.

 

I was complaining not to get Jags attention/help/sarcastic remarks, but trying to get Freescale to maybe update their documentation if they realized more people had the same problem.

 

Lesson learned and advice for all who read this post in the future: use the IIC interrupt, or do everything manually (or use a different micro altogether).

 

Best regards,

 

OIiver

0 Kudos

497 Views
Oliver
Contributor III

Hi Peter,

 

I know, I've read those threads, and I thought the QG8 was fairly new back then, now that some time has passed I figured there should be a solution. 

 

I think the problem is that if we were customers working on a prototype for say an automotive supplier, we'd be asking our assigned FAE, and we'd get attention.

 

I am working "only" with students with the QG8, and I'm a big supporter of Freescale, but you can imagine the impression my students get of Freescale products when they try to get a module to work only to find out the manuals are inadequate and/or the parts don't work reliably. They may not be a corporate customers now, but they are tomorrow's engineers - let's hope they don't get to make purchase decisions...

 

Best regards,

 

Oliver 

 

 

0 Kudos

497 Views
PeterHouse
Contributor I

Oliver,

 

I asked these questions at least 3 years ago and have yet to see a coherent response.

 

Good Luck,

 

Peter House

 

Using Mot/FSL since XORMACS and original 6800 family in the early '80s

0 Kudos