Show Posts
Pages: 1 ... 4 5 [6] 7 8 ... 13
76  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: December 04, 2012, 05:36:05 am
Quote
I spent $50 on two soldering irons from radioshack

Madness...pure madness... smiley-mr-green smiley-mr-green smiley-mr-green
77  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: December 04, 2012, 05:34:39 am
As soon as you have the hardware set up we can work through it and get your project working. I'm sure funky will be up for that as well.  smiley-mr-green

Spend whatever time you have on enjoying learning the basics and worry about the AS1130 when you have one.... smiley-wink
78  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: December 04, 2012, 04:18:13 am
@ binarygod

Thank-you so much for your last post and for the apology.  smiley-wink

I will spend as much time as I have trying to help you with your project and I have no wish to see you leave this thread at all.

I just hope that you understand why I posted my feelings above and why I was a bit annoyed.

Please feel that you can contribute to the thread as well when you get your matrix working...we don't want to be "liberated" from you at all!  smiley-mr-green

Now go on....ask me a question......I dare you..... smiley-twist smiley-twist

Take care mate, Roy
79  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: December 03, 2012, 11:11:26 am
@binarygod

As far as I am concerned I posted some code which will run the AS1130 chip with 132 LEDs in the hope that other people would contribute their own efforts and we could all learn something.

This thread has turned into something completely different  smiley-roll

I don't have the time, inclination or skills to teach you C, C++ or any other kind of programming. The same goes for electronics.      

Most of the questions you have asked have been about basic programming or electronics not about my programme or the AS1130.

Many of your questions have already been answered in the software I spent ages commenting but you have either not bothered to read or don't understand because you lack the basic knowledge.

For instance:
Quote
so where do I have to put the as_config(CONTROLREGISTER, SHUTDOWNOPENSHORT, 0b00000011); without making loops all the time?
         

Just makes my blood boil....I have posted code that works well that is commented AND answers this question and there was also a discussion with funkyguy about why all the setting up was done in the setup function and not in the main loop...

This is even worse:
Quote
But where can I set those 400kb/s? Or are they automatically set?

I've posted links which would answer this question, but even if I couldn't be bothered...a simple "arduino fast mode" bunged into Google brings up millions of pages. You only need to look at the first 20.

I've already suggested that you do some basic experiments with an LED matrix before you get involved with a VERY, VERY complicated chip like the AS1130...you have ignored this and continue to ask questions that have already been answered or should not need to be asked in the context of this thread. Not knowing what the setup() and loop() functions are there for is not a good starting point if you want to programme an AS1130.

You don't have a clue about the Arduino IDE and as far as I can ascertain you don't own an Arduino of any kind.

I on the other hand do have an Arduino and know enough of the basics of programming it that I can get the AS1130 working all on my own...I did this by spending a long, long time reading the datasheet and using Google. There is a mountain of information on every aspect of the Arduino freely and easily available...all you have to do is read it. There are 1000's of knowledgeable people willing to answer any questions on any subject, all you have to do is ask.

You also don't appear to have a working AS1130, an LED matrix or a compiler that allows the inclusion of header files (I find that very hard to believe) and spend lots of your time wasting my time by asking questions you should already know the answer to, not responding to the answers and then asking more questions...I've already said in this thread what I think of this, I suggest you start at post 1 and read the whole thread again.

The bottom line is...AND I have said this before to you...get an AS1130 hooked up to an LED matrix, connect your driver MCU, programme it and come back and ask SPECIFIC questions about the AS1130 which I will gladly answer. If your MCU is an Arduino and you have problems I or someone else will try to help...but basic questions about setting up things like I2C DO NOT belong in this thread.
 
80  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: November 30, 2012, 01:40:48 pm
Oh BTW the Arduino defaults to 100kb/s for I2C or you can set fast mode which is 400kb/s.

The AS1130 can work at 1Mb/s but you'll have to bit bang at that speed...or get a compiler that will do it automatically. eg CCS C allows:
Code:
#use I2C(master, scl=PIN_B0, sda=PIN_B1, fast=450000)

//sets the target speed to 450 KBSP

81  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: November 30, 2012, 01:35:28 pm
- int ack = Wire.endTransmission();
- the loop function HAS to be there...I'm just using it to start the AS1130 then pausing for a bit, then resetting, then it loops. It doesn't HAVE to. I could have changed data sets during the pause. etc.
- I already told you where to look for the answer to this and the first question. Did you look?
- why didn't you read about it BEFORE you asked the question?


Why have you STILL not read about I2C?

Here are some links:
http://dsscircuits.com/articles/arduino-i2c-master-library.html
http://www.instructables.com/id/I2C-between-Arduinos/

There are 100's more.
82  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: November 30, 2012, 05:28:02 am
Just another thought Mr God of the Binaries...

If you look in the Arduino installation on your computer, you can find all the code for the libraries and follow what they do and how they work...

...the only problem is that they are written as C++ classes and you need to understand the basics of the Class system and how to create them.





Me....I'm working class and proud of it.... smiley-mr-green smiley-mr-green
83  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: November 30, 2012, 05:21:09 am
Quote
It's arduino code so there can nobody tell me I'm in the wrong topic
ROFLMAO  smiley-mr-green smiley-mr-green


I did post at the beginning somewhere that this is my first attempt at using the Arduino system and the AtMega chips....before I started this project I'd never heard of the Wire library... smiley-razz

I can read though...and have a background in electronics and computer science.  smiley-twist

The code is not optimised or elegant...I just posted it to show how I got the AS1130 working with an Arduino.

Anyway....

I now have the 24 x 11 version working and am starting this weekend to solder up the other 2 chips and 264 LEDs which will give me 24 x 22. My plan then is to look into optimising the code and porting it to the Arduino...then I'll look at RGB, but I haven't found any RGB LEDs that I can solder in a very tight matrix.... smiley-sad

Until the code is optimised and debugged I don't really want to share it because I am changing it all the time...and I haven't even started to include blinking and dot correction yet  smiley-eek-blue


To answer your question...the begin method initialises the I2C bus and sets the internal pullups on SDA and SCL. The beginTransmission method does exactly what it says.... smiley-grin


84  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: November 29, 2012, 12:27:13 pm
To be honest mate...if you insist on using your own compiler, then you are going to run into problems as I said earlier.

I don't know how long the Mods or Admin will allow the discussion of porting code to another system.... smiley-eek

Having said that...I would look up how YOUR compiler works with the I2C bus and concentrate on that. The Wire library is a wrapper for I2C and as such will just confuse you if you don't know the I2C protocol.

Here is some of my code for the CCS C compiler...I hope I don't get banned or repremanded for posting it here.

It may help because it looks like it is closer to your compiler....

Code:
/*****************************************************************************/
/*                      COMMUNICATIONS FUNCTIONS                             */
/*****************************************************************************/

/***** Function to write configuration settings to I2C bus *******************/
void AS1130_config(char AS_addr, char ram_reg, char command, char data)
{
i2c_start();
i2c_write(AS_addr);
i2c_write(REGISTERSELECTION);
  i2c_write(ram_reg);
i2c_stop();

i2c_start();
i2c_write(AS_addr);
  i2c_write(command);
i2c_write(data);
i2c_stop();
}
/*****************************************************************************/
/*                 EXT EEPROM COMMUNICATIONS FUNCTIONS                       */
/*****************************************************************************/

/***** Function to write data to external EEPROM *****************************/
//Standard I2C Protocol (see datasheet)
void write_ext_EEPROM(long int address, BYTE data)
{
   short int status;
   i2c_start();
   i2c_write(EEPROM_WRITE_ADDR);
   i2c_write(address>>8);
   i2c_write(address);
   i2c_write(data);
   i2c_stop();
   i2c_start();
   status=i2c_write(EEPROM_WRITE_ADDR);
   while(status==1)
   {
      i2c_start();
      status=i2c_write(EEPROM_WRITE_ADDR);
// delay_cycles(200);
   }
   i2c_stop();
}
/***** Function to read data from external EEPROM ****************************/
//Standard I2C Protocol (see datasheet)
BYTE read_ext_EEPROM(long int address)
 {
   BYTE data;
   i2c_start();
   i2c_write(EEPROM_WRITE_ADDR);
   i2c_write(address>>8);
   i2c_write(address);
   i2c_start();
   i2c_write(EEPROM_READ_ADDR);
   data=i2c_read(0);
   i2c_stop();
   return(data);
 }

Seriously, you need to understand the I2C protocol fully before Wire or bit banged (or anything in between) I2C will make any sense.

Here is a link to the EEprom's datasheet: http://ww1.microchip.com/downloads/en/DeviceDoc/21754M.pdf
Sections 4, 5 and 6 are pretty revealing as is the I2C description in the AS1130 datasheet.
85  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: November 25, 2012, 03:55:12 pm
Looks like anice bit of kit...did your Uni supply it or are you rich?  smiley-mr-green smiley-mr-green
86  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: November 25, 2012, 12:28:03 pm
All true and helpful....except  smiley-eek-blue you can't have classes in C...that's why they invented the OOP version C++  smiley-razz


Nice to see you back mate...what FPGA are you playing with?
87  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: November 23, 2012, 08:45:11 am
It's just a way of splitting a file into 2 parts so that I don't have to scroll past all the defines etc. while I'm programming.
88  Using Arduino / Sensors / Re: Why HMC5883L error? on: November 23, 2012, 04:06:47 am
That's why I headed my post with:

Quote
For anyone having problems compiling the example:

I downloaded the example from the link above and it isn't updated.  smiley-wink

I'll have a look at the library when I get some time this weekend.
89  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: November 22, 2012, 03:36:40 pm
"AS1130.h" is an included file and not a library and I use it to get it out of my way.

90  Using Arduino / LEDs and Multiplexing / Re: AS1130 First attempt - working on: November 21, 2012, 07:09:34 am
Are you hiding for some reason?  smiley-mr-green smiley-razz
Pages: 1 ... 4 5 [6] 7 8 ... 13