Pages: [1] 2 3 ... 5   Go Down
Author Topic: "The Brick" - All In One - Arduino Platform Compatible  (Read 13164 times)
0 Members and 1 Guest are viewing this topic.
NZ
Offline Offline
Sr. Member
****
Karma: 0
Posts: 390
Turtle in a hard shell
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello,

Just thought I would share the project I am currently working on.

This is "The Brick", a All-In-One board which features a AtMega2560 and 3 AtTiny84's, with the following I/O.

18 General Purpose IO, PTC Fused with Zeners, capable of handling up to 30VDC inputs
12 Digital Outputs, which you can select for 5V or 24V output, capable of being PWM'ed, (3x L293D chips).
6 Relay Outputs (30VDC @ 10A, 240VAC @ 10A - Resistive Load, or 28VDC @ 5A, 120VAC @ 5A - Inductive Load)
8 Single Ended Analog Inputs 12 bit 16 Bit (Selectable from 0-5V or 0-10V) or 4 Diffrential Inputs (Selectable input ranges within 0-5V or 0-10V) (MCP3208 ADS1115)
4 Analog Outputs, 8 Bit 12 Bit (0-10V) (MCP4728)
3 High Speed Inputs capable of handling up to 30VDC inputs (These are the 3 seperate AtTiny84's, talking to the AtMega2560 over SPI)
USB Programming and Serial port like the Arduino (UART0)
RS232 Comms (UART1)
RS485 Comms (UART2) - With Power on the socket to supply slave boards (fed from Adjustable Supply, mentioned below)
It supports either Bluetooth (Sena Bluetooth Module) or XBee Module for wireless comms (UART3)
Real Time Clock (DS3231S)
External EEPROM (24LC256)
Micro SD Card Flip-Lid Socket

5VDC Switchmode power supply on board, capable of 2-3A (LM2596S-5.0)
Adjustable Switchmode power supply, designed with 24VDC in mind however adjustable from 10V to 24V, capable of 2-3A also. (LM2596S-ADJ)

Here is a picture of the PCB:



Here is a rendered picture of the PCB is the case, top removed:


Here is a rendered picture of the case closed up, back view:


I am just finalising it at the moment and hope to get the first prototypes ordered this week.

smiley

James
« Last Edit: August 15, 2011, 04:46:31 am by WanaGo » Logged

NZ
Offline Offline
Sr. Member
****
Karma: 0
Posts: 390
Turtle in a hard shell
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Another render, with plugs in one side.

3.81mm screw plugs.



James
Logged

nr Bundaberg, Australia
Offline Offline
Tesla Member
***
Karma: 129
Posts: 8601
Scattered showers my arse -- Noah, 2348BC.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Great-looking board Wanago, talk about a Mega on steroids smiley

Any price guesstimates yet? I'm guessing it won't be cheap but then it's a lot more "industrial strength".

______
Rob
Logged

Rob Gray aka the GRAYnomad www.robgray.com

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 361
Posts: 17303
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

That is quite an ambitious board. Of the features, I would only have liked to see 12 bit DAC or even 10 bit DAC over the 8 bit you listed.

Good luck with the project.


Lefty
Logged

NZ
Offline Offline
Sr. Member
****
Karma: 0
Posts: 390
Turtle in a hard shell
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks smiley

I was thinking about high resolution for the DAC also - its still a possibility.
Might look at that now actually.

Rob - watch this space, just waiting for the quote back for assembly for the prototype. Prototype will be more expensive than the final product, but will at least give an estimation.

Cheers
James
Logged

NZ
Offline Offline
Sr. Member
****
Karma: 0
Posts: 390
Turtle in a hard shell
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Oh and for the people looking, this wont be a $40 board like the Mega etc, it will be more - but is intended to be used as the final product, and not as a prototyping board.
I am creating this for my own use, a local guy here and for a guy in the UK. That said though, if others are interested then I have no objection to making some for others.
I have another company looking at this for feasibility of sale etc, so it could be for sale at some point.
Again watch this space smiley
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 547
Posts: 27363
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

"8 Analog Inputs 12 bit (Selectable from 0-5V or 0-10V)"

Support for AC signal  instead, +/-5v
What data rate on that?
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

NZ
Offline Offline
Sr. Member
****
Karma: 0
Posts: 390
Turtle in a hard shell
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Right now its only 0-5 or 0-10 sadly...

I will have a look at whats involved to get it to do +/-5...

Its 100k Samples/s

using this:
http://ww1.microchip.com/downloads/en/DeviceDoc/21298E.pdf

Hope that helps

Cheers
James
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 361
Posts: 17303
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Right now its only 0-5 or 0-10 sadly...

I will have a look at whats involved to get it to do +/-5...

Its 100k Samples/s

using this:
http://ww1.microchip.com/downloads/en/DeviceDoc/21298E.pdf

Hope that helps

Cheers
James

I've been having a lot of fun playing with a TI ADS1115 16 bit I2C ADC chip. Works at 3.3 or 5vdc, has like five gain settings down to +/- .256 vdc, 4 channels single ended or 2 channels differential. Makes it useful to read Wheatstone bridge type sensors without needing external op-amps. Build in comparator function also. Only 960 SPS however. Check it out.

http://www.ti.com/lit/ds/symlink/ads1115.pdf

Lefty
Logged

NZ
Offline Offline
Sr. Member
****
Karma: 0
Posts: 390
Turtle in a hard shell
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ok changes in progress, 12 bit DAC is being added, which will replace the 4x 8bit DAC outputs currently on the board.

MCP4728 is the weapon, and what do you know - someone has a library for it already - perfect.

Perfect spot for it on the board too, will be done in a few mins.

Cheers
James
Logged

NZ
Offline Offline
Sr. Member
****
Karma: 0
Posts: 390
Turtle in a hard shell
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


I've been having a lot of fun playing with a TI ADS1115 16 bit I2C ADC chip. Works at 3.3 or 5vdc, has like five gain settings down to +/- .256 vdc, 4 channels single ended or 2 channels differential. Makes it useful to read Wheatstone bridge type sensors without needing external op-amps. Build in comparator function also. Only 960 SPS however. Check it out.

http://www.ti.com/lit/ds/symlink/ads1115.pdf

Lefty

Great, I will have a look at that - thanks.

960 SPS isnt anything to snuff at anyway, thats quite respectable in my opinion.

I will take a look once I sort this DAC smiley
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 361
Posts: 17303
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Great, I will have a look at that - thanks.

960 SPS isnt anything to snuff at anyway, thats quite respectable in my opinion.

I will take a look once I sort this DAC


Cool. Here is a check out sketch I wrote last weekend to test out it's capablities:

Code:
/* Basic testing and check out sketch for a TI ADS1115 4 channel 16 bit I2C analog to digital converter chip.
   Reads voltage at desired range on desired channel and displays it on serial monitor. Also allows comparitor
   to output a active low signal pin if enabled.
   
   Leftyretro 08/10/11
*/

#include <Wire.h>

int topofScale;          // global to use adc range value to display millivolt reading conversion
int hiCompair = 17000;   // high setting for comparitor threshold value, must be higher then loCompair 32767
int loCompair = 11000;   // low  setting for comparitor threshold value, must be lower then hiCompair -32768


void setup()
  {
    Wire.begin();           // join I2C bus
    Serial.begin(38400);    // initialize serial communication
    setadcConfiguration();  // configure ADS1115 chip for range, channel input, and comparitor options desired
   }
   
void loop() {
    int   rawValue;       // holds 16 bit result read from A/D device
    int   scaledValue;    // to convert to millivolts
     
    Serial.print("Analog input #1 counts =  ");
    rawValue = getadcReading();  // read current A/D value
    Serial.print(rawValue);
    Serial.print("  Millvolts =  ");
    scaledValue = map(rawValue, 0, 32767, 0, topofScale);  //convert raw adc counts to millivolts
    Serial.print(scaledValue);
    Serial.println("     Hit any key to continue");
    while(Serial.available() < 1) {}   // wait for user keystroke
    while(Serial.available() > 0) {byte userKeys = Serial.read();} //read keystrokes
}

int getadcReading()   // read 16 bit analog voltage reading
    {
      int data;
      int deviceAdd = 0x48;              // ADS1115 address with address pin grounded
      Wire.beginTransmission(deviceAdd); // transmit to I2c device address
      Wire.send(0x00);                   // point to device register 0
      Wire.endTransmission();            // stop transmitting
     
      Wire.requestFrom(deviceAdd, 2);    // request 2 bytes from slave device
      while(Wire.available())            // need two bytes, MSB and LSB of converstion value
        {
          data = Wire.receive();         // get MSB of reading
          data = data << 8;              // shift it to high byte of data
          data = data + Wire.receive();  // add LSB to data
        }
      return data;
    }
   
void setadcConfiguration()
    {
      int deviceAdd = 0x48;   // ADS1115 address with address pin grounded
     
            /* uncomment one desired voltage input range */
           
      int confWord= 0x0000; topofScale = 6144;  // +/-6.144 vdc range
      //int confWord= 0x0200; topofScale = 4096;  // +/-4.096 vdc range
      //int confWord= 0x0400; topofScale = 2048;  // +/-2.048 vdc range
      //int confWord= 0x0600; topofScale = 1024;  // +/-1.024 vdc range
      //int confWord= 0x0800; topofScale =  512;  // +/-.512 vdc range
      //int confWord= 0x0A00; topofScale =  256;  // +/-.256 vdc range
     
      /*  uncomment one desired channel input
          This also sets sample rate to 860 SPS and turns on continous conversion mode. */
         
      confWord = confWord | 0x00E0;  //input wired to + AIN0 - AIN1, diff +/- max range
      //confWord = confWord | 0x30E0;  //input wired to + AIN2 - AIN3, diff +/- max range
      //confWord = confWord | 0x40E0;  //input wired to + AIN0 - gnd, single ended, 0 to +max range
      //confWord = confWord | 0x50E0;  //input wired to + AIN1 - gnd, single ended, 0 to +max range
      //confWord = confWord | 0x60E0;  //input wired to + AIN2 - gnd, single ended, 0 to +max range
      //confWord = confWord | 0x70E0;  //input wired to + AIN3 - gnd, single ended, 0 to +max range
     
      /* uncomment one desired comparator options
         active low ready pin, window mode = input voltage is inside window values
         active low ready pin, traditional = voltage raised above or fell below set values */
             
      //confWord = confWord | 0x0003;   //disable comparitor
      //confWord = confWord | 0x0008;    //enable comparitor in traditional comparator mode
      confWord = confWord | 0x0018;   //enable comparitor in window comparator mode
         
      //send configuration word to device
      Wire.beginTransmission(deviceAdd); // transmit to ADS1115 device
      Wire.send(0x01);                   // point to configuration register
      Wire.send(highByte(confWord));     // sends MSB of configuration word
      Wire.send(lowByte(confWord));      // sends LSB of configuration word
      Wire.endTransmission();            // stop transmitting
         
      //send low threshold value word to device
      Wire.beginTransmission(deviceAdd);  // transmit to ADS1115 device
      Wire.send(0x02);                    // point to low threshold register
      Wire.send(highByte(loCompair));     // sends MSB of low threshold word
      Wire.send(lowByte(loCompair));      // sends LSB of low threshold word
      Wire.endTransmission();             // stop transmitting
       
      //send high threshold value word to device
      Wire.beginTransmission(deviceAdd);  // transmit to ADS1115 device
      Wire.send(0x03);                    // point to high threshold register
      Wire.send(highByte(hiCompair));     // sends MSB of high threshold word
      Wire.send(lowByte(hiCompair));      // sends LSB of high threshold word
      Wire.endTransmission();             // stop transmitting
     
    }
Logged

NZ
Offline Offline
Sr. Member
****
Karma: 0
Posts: 390
Turtle in a hard shell
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

OK Done.

Board now has 4x 12bit DAC Analog Outputs, amplified to 0-10V, instead of 8 bit which was generated from the standard PWM and filtered.

Good suggestion, thanks.
Logged

NZ
Offline Offline
Sr. Member
****
Karma: 0
Posts: 390
Turtle in a hard shell
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Few more specs listed on first post.
Logged

NZ
Offline Offline
Sr. Member
****
Karma: 0
Posts: 390
Turtle in a hard shell
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


I've been having a lot of fun playing with a TI ADS1115 16 bit I2C ADC chip. Works at 3.3 or 5vdc, has like five gain settings down to +/- .256 vdc, 4 channels single ended or 2 channels differential. Makes it useful to read Wheatstone bridge type sensors without needing external op-amps. Build in comparator function also. Only 960 SPS however. Check it out.

http://www.ti.com/lit/ds/symlink/ads1115.pdf

Lefty

Ok after look at the datasheet that does look like a very cool ADC, especially since it has programmable gain!
I still need to be able to read 0-10V, so I will have to do a divide by 2 opamp as I am currently doing anyway.
However I still need to figure out how to do the opamp configuration for -ve voltages being divided by 2...
Never created a circuit do divide a negative voltage before.

I will have to do some more thinking, but more likely than not I will use this chip - well, 2 of them.

Cheers
James
Logged

Pages: [1] 2 3 ... 5   Go Up
Jump to: