atmega powered autonomous tank

I want to make an atmega powered autonomous tank but i dont know what atmega i need to use i need it to be able to process video give me a video feed from anywhere cost less than $150 and use an rc hovercraft that i have

Posted by taterkiller 8 years ago


atmega based robot controller kit

Help make low cost robot controllers a reality http://www.marcogrilli.com/thenerdling/atmega-based-robot-controller/

Posted by The nerdling 5 years ago


Help with basic arduino sketch for Halloween

Hello all, I'm very new to Arduino programming, and was trying to write a basic sketch to flash some LEDs in a jack o lantern for halloween, but I'm struggling with the code. Essentially what I wanted to accomplish was blinking a LED from pin 13 x times, followed by fading (pulsing) another LED from pin 9 x times and then repeat.   If anyone would be so kind as to help me accomplish this, I would be very grateful. Thanks in advance.

Posted by SubEclipse 5 years ago


USnooBie

The USnooBie is a microcontroller kit that does not require any sort of AVR programmer or USB-to-serial converters to load and run compiled code. It's hardware design allows the user to develop low cost USB devices with Atmel's AVR ATmega microcontrollers. It can also be used to develop projects which are not USB devices. It is even compatible with Arduino. No AVR programmer is needed and no USB-to-serial converter is needed to bootload. The bootloader uses native USB and works with AVRDUDE. This makes USnooBie the fastest and cheapest way to get started programming AVR microcontrollers AVRDUDE is cross platform, so it works on Windows, Linux, and Macs. Make V-USB based USB devices using AVR microcontrollers, great for making keyboards, mice, joysticks, gamepads, and other neat gadgets. Of course, you can also make non-USB projects as well because USnooBie uses the same microcontroller as Arduino. Compatible with Arduino. Thin design for use with breadboards or plugs straight into a USB port. Operating voltage is selectable between 5V and 3.3V by a jumper. Protection diode and self-resetting fuse protects your computer from over voltage, reverse current, and short circuits. Buy one from Seeed Studio Instructions and Tutorials on the Official Website

Posted by frank26080115 7 years ago


Arduino bootloading circuit

Hi everyone, I have a short question. I am making a project that uses a ATmega328P and I'd like it to be stand alone, so I have been burning bootloders on this chip but only on the DIP socket and with a shield I made after a tutorial. I know that when burning the ISP you can't have anything connected to the board, and I was wondering if you must have the same conditions for the bootloading procedure since I am going to use the TQFP32 package and it is going to be a little bit difficult to make a shield for it. So if I solder everything to the board and put a connector for the ISP do you think it will burn the bootloader?

Posted by shinystuff 3 years ago


Uploading to ATmega328 with preloaded blink sketch through ArduinoISP doesnt work?

I'm using my Arduino Mega as an ISP and have successfully uploaded a blink sketch to an atmega on a breadboard, with the led @ D13. Thats the SCK pin, and now i cant upload another program to the atmega on the breadboard. I tried resetting both the boards JUST before uploading, but it didnt work. my connections are secure, reset pin is tested, auto-reset is off. im at a loss. Please HELP!!!

Posted by DangerousTim 3 years ago


FatFs Library

Hello everyone, I have recently been working on porting the FatFs Generic FAT File System library to an Atmega328p for use with a project I'm working on and I'm really having some issues with it.  I've tried a couple of different tutorials and walkthroughs and in the end I either get odd errors that seems will be an incredible hassle to correct, or my program compiles but the actual program won't work correctly (none of the open, write, etc functions actually work) I am writing this in Atmel Studio 6 (AVR Studio) If anyone can please help me out, or if you have ported this for the atmel mega series before and can provide your files that would be awesome Thank you

Posted by BooRan 5 years ago


Plans for AVR LCD display, need some help..

I've just ordered at ATMEGA644 after running out of space on my ATTINY2313 too easy. Along with that, i got a 20X4 LCD screen, character one that displays letters, and the cursors are 5X7 matrix.How does one write to a LCD screen? like is there a good place for a tutorial? maybe a simple sample code of HELLO WORLD? I know in DOS you need stlib or w/e, and you do printf("HELLO WORLD\n"); does it work similar to displaying on a 20X4 character screen? I'm a ok C programmer, knowing the basics to create little games with 3X3 leds and speakers. I've got a C programming book to help along with it. So feel free to explain, or just give code samples. i can figure it.http://www.mpja.com/prodinfo.asp?number=17165+OP

Posted by Killa-X 10 years ago


Where can I get a cheap AVR programmer

Hi, I'm working on a project and am wondering: Where can I get a cheap AVR programmer compatible with Atmega chips? Specifically the ATmega32U4. It does not need to have a socket for the chip, I'll be doing in circuit programming. Please help.

Posted by gimmelotsarobots 8 years ago


Want to move "tv b gone" project from Arduino(Atmega328P) to Atmega8A

Hello. I found "Tv b gone" project which i can write to my arduino. It worls perfectly. I want to make it smaller but i don't want to waste my arduino board and Atmega328P which sits inside of an arduino. Here is a video on YouTube https://www.youtube.com/watch?v=rfdVdPwPhWU Works on one IR diode (would be glad if can do the same on atmega8a) There is a link to download the code for arduino: http://arcfn.com/files/arduino-tv-b-gone-1.2.zip Project page (guy changed the code to working on arduino) http://www.righto.com/2009/12/tv-b-gone-for-arduino.html Original project page where originally everything is working on ATtiny85. https://learn.adafruit.com/tv-b-gone-kit/design-notes If needed I've got Arduino UNO, USBasp (can burn program with USBasp using Eclipse C/C++ or ArduinoIDE) I want to know if i could make it work on Atmega8 (internal oscilator/external crystal?) (got many of these, don't want to buy new microcontroller) without any effort? I would appreciate if someone help me. Sorry for my English. I'm from Europe.

Posted by DELETED_AndrzejŁ 3 years ago


Arduino - Mega or Duemlianove

I have been thinking about getting an arduino from Adafruit Industries. They carry two - The arduino duemlianove with the Atmega328 and the more powerful Mega with atmega1280 chip. I am having difficulty choosing between the two microcontrollers. My main focus will be on larger projects like the Garduino(www.instructables.com/id/Garduino_Gardening_Arduino/) but again also on smaller robotics projects like advanced balancing robots(multiple accelerometers and sonar sensors)or even arduino smart drones(aircraft).Some of the factors in my descision will depend on: Price Weight Dimensions Power requirements Flash ROM Output pins Protoshield/other shield capabilities PWM control XBee wireless support Integration with logic systems Support for multiple(3) LCD screens/Dot Matrix displays Multiple Servo support Sound/Media support Please help me choosing this microcontroller.I will only buy once in maybe 4-5 years so I want it to be good buy. Also tell me which shields should I buy for my requirements: either the sound shield or the servo shield.I think I will buy the servo shield because it will give me greater control over my robotcs projects Kabir

Posted by mhkabir 8 years ago


where can i get a under water ultrasonic sensors in india or online. i'm doing a progect on under water robot using arduino

Hello, im from bangalore india. looking for a under water ultra sonic sensor for a under water robot. compatible with atmega 8, arduino.

Posted by opadigela 6 years ago


D-Pad data compression?

So, I'm working on a small, simple, and yet very inefficient game console using multiple ATmega328 chips. Basically, I'm trying to compress the controller data into as few wires as possible using an ATmega. Hopefully using something along the lines of http://pinouts.ru/Game/genesiscontroller_pinout.shtml. Anyone have any idea how to do this? I can handle coding, it's just the actual logic of it. 

Posted by Krayzi99 3 years ago


Micro drone construction help

For a school project a partner and I are attempting to build a self controlling quadcopter. It should be able to use a specific input from a photo transistor and the be able to navigate on its own. The only problems that I can see running into at the moment are finding an atmega compatible rotor controller, and that not including the propellers it is going to be under two inches (5.08 cm). I would appreciate any assistance possible in finding a motor controller of this size, and will keep this post up to date with our project.

Posted by Kaptia Teramo 2 years ago


Design idea help needed- nightvision

Is it possible to create a night vision with the following circuit... fitted with scanning disk tv method (accept for the fact that i'll use multiple mirrors instead of disk with holes) of video capture and display. Will it be sensitive enough? what I plan to do is- In simple terms, ill be using atmega as ADC... and photodiode as signal input. output will be via port d... if value of input is 1, one led red is turned on.. if value is 2,one green led red is turned on.. if value is 3,1 red and 1 green if 4=blue if 8, 2 reds 9, 3 reds so on

Posted by Suraj Grewal 3 years ago


403 FORBIDDEN

Not sure if this is a bug or if should be brought up in this section, I apologize in advance if it does not belong here. I was on the site gearing up to do the "Perfboard Hackduino (Arduino-compatible circuit) "by jmsaavedra and all was good until I selected the view all steps button. I received and still receive       "403 Forbidden                                                                                   Request forbidden by administrative rules."                                                                                     Can anyone lend a hand here? I've been looking forward to making a few of these for some time now and finally have just about everything needed (except my sockets for atmegas,any day now) but figured I could just leave all final connections to chip open to do later. Would post a pic but I'm sure we've all seen the white page with black letters at one point in our lives. It happenes on all my computers and my android.Please help.

Posted by taattooed3 5 years ago


how can one incorporate multiple USB-like connections to/from an arduino?

Hello All, I am hoping to create peer-to-peer connections (essentially a network) of multiple arduinos (or for that matter, ATMega's). However these do not have separate power supplies and each one will be powered up when connected to the other previously connected one. At the same time I would like these units to know about each other's existence when they connect (each chip should know if another chip is connected to it). I was told to think of a USB-like connection where you can share both the power and the data on the same, say, bus line. My question is how do I create multiples of this connections (more than one) and how could I make sure they work as OTG (e.g. hot plug) and can be used as both host or client at any given time? Any help is much appreciated. Thanks. Karim.

Posted by karimskarim 3 years ago


Circuit works when I poke a connection, but the connection is sound

So, I've started playing with vfds since this weekend jaycar (if your an Aussie) is selling 11 digit, 10 segment vfds for $1.90. Cheap as :P. It runs off 12v for the segments, 4.5v for the filament. I'm using 3 4094s to control the segments and an atmega168 to control the 4094s, using 3 transistors to up the voltage between the 4094s data, clock and latch pins and the the atmega I/O ports. I'm pretty sure everythings hooked up correctly but, as with most projects, it's not working first time :P. Here's the thing, it works if I poke either the green or brown connection with just one probe of my multimeter/finger it works. My first thought is that i've hooked up my transistors incorrectly, the base is 5v with a 2.2k current limiting resistor, and the collector is 12v with a 5.1k current limiting resistor. To much? I blew out a resistor in initial testing and it got me a little worried :P Thoughts?

Posted by greendude 9 years ago


FT232RL+breadboard arduino programming problems

I am trying to program a breadboard arduino with an ft232rl programming adaptor that I found online. I made the 'duino using a atmega 328 preloaded with arduino uno optiboot from sparkfun. I attached 5volts power, 16mhz crystal, reset button, and an led to pin 13. When power is supplied, the led pulses then stopps suggesting that the bootloader is working correctly. I then connected a ft232rl to the arduino with rx to tx and tx to rx as well as the DTS pin to a 0.1 UF cap and to reset. Then i connected it to my computer via usb and installed the VCP drivers. It shows up as a com port in the IDE and I selected the board as an uno and tried to flash the blink sketch. The lights on the breakout blink, but i keep getting the avrdude not in sync message. I have tried switching cables, usb ports, pressing the reset button while programming, i have gotten rig of the 0.1 uf cap and jumped directly to DTS, i have tried both sets of drivers and have restarted the board, my computer, and the IDE as well as feeding a separate 5 volt source to the chip. How can I fix this? I am using windows vista SP1 with ide version 1.0.1 and a cheap programmer from ebay. 

Posted by qquuiinn 5 years ago


Wiring stripboard tracks to common ground

I'm planning a stripboard POV kit to solder with learners over about 3 hours or so, and I have a problem designing the wiring for the LEDs. It's straightforward to use the required series resistors to wire the output pins of an ATMEGA like http://www.arduino.cc/en/Hacking/PinMapping to the anodes of 8 5mmx2mm rectangular leds like http://www.rapidonline.com/Electronic-Components/Kingbright-L-383IDT-5x2-5mm-H-i-Red-LED-Rectangular-56-0398 packed side by side onto 0.1 inch stripboard. However, I'm facing a puzzle when trying to wire the LEDs' cathodes together to ground. It's fairly easy for me myself to do this, just by free-soldering a couple of spare legs directly over the cathode tracks, or chaining loads of wires. However, I can't see myself guiding 45 people through this in a workshop without hassle and errors. Does anyone have a simple way to wire 8 'odd' stripboard tracks together to a ground track (the 'even' tracks have the anodes in them). To give a flavour of the solutions I'm considering, I'm looking into 0Ohm bussed resistor networks like http://www.interfacebus.com/resistor-network-schematic-bused-resistors-sip.html to wire theparallel tracks into a single ground track using a standard through-hole component with legs clipped off. However I'm having trouble sourcing anything like this, and I'm sure others have better ideas.

Posted by cefn 5 years ago


RadioShack Tri Color LED strip light show help?

I'm having partial success creating a synchronized light show by calling some colors and adding delays. My main problem is creating specific colors or even displaying one color on the entire strip. Sorry that I put the whole code on here! I just got really stuck. Thank you in advance!! here's the default code for the strip for arduino: #include // ******** DEBUG ==== should auto config to adapt different mother board ********* //#define DATA_1 (PORTF |=  0X01)    // DATA 1    // for ATMEGA //#define DATA_0 (PORTF &=  0XFE)    // DATA 0    // for ATMEGA //#define STRIP_PINOUT DDRF=0xFF  // for ATMEGA #define DATA_1 (PORTC |=  0X01)    // DATA 1    // for UNO #define DATA_0 (PORTC &=  0XFE)    // DATA 0    // for UNO #define STRIP_PINOUT (DDRC=0xFF)    // for UNO PROGMEM const unsigned long pattern_test_red[10][10]={   {0xff0000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0xff0000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0xff0000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0xff0000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0xff0000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0xff0000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xff0000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xff0000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xff0000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xff0000}, }; PROGMEM const unsigned long pattern_test_blue[10][10]={   {0x00ff00,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x00ff00,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x00ff00,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x00ff00,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x00ff00,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x00ff00,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x00ff00,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x00ff00,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x00ff00,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x00ff00}, }; PROGMEM const unsigned long pattern_test_green[10][10]={   {0x0000ff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x0000ff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x0000ff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x0000ff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x0000ff,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x0000ff,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x0000ff,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x0000ff,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x0000ff,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x0000ff}, }; PROGMEM const unsigned long pattern_test_white[10][10]={   {0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff}, }; PROGMEM const unsigned long pattern_test_comet1[][10]={   {0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff}, }; PROGMEM const unsigned long pattern_test_comet2[][10]={   {0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000},   {0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000},   {0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000},   {0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000},   {0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff},   {0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000},   {0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000},   {0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000},   {0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000},   {0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff}, }; PROGMEM const unsigned long pattern_test_comet3[][10]={   {0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff},   {0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff,0x444444},   {0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0xffffff,0x444444,0x111111},   {0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0xffffff,0x444444,0x111111,0x000000},   {0x000000,0x000000,0x111111,0x444444,0xffffff,0xffffff,0x444444,0x111111,0x000000,0x000000},   {0x000000,0x000000,0x111111,0x444444,0xffffff,0xffffff,0x444444,0x111111,0x000000,0x000000},   {0x000000,0x000000,0x000000,0xffffff,0x444444,0x444444,0xffffff,0x000000,0x000000,0x000000},   {0x000000,0x000000,0xffffff,0x444444,0x111111,0x111111,0x444444,0xffffff,0x000000,0x000000},   {0x000000,0xffffff,0x444444,0x111111,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000},   {0xffffff,0x444444,0x111111,0x000000,0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff}, }; PROGMEM const unsigned long pattern_test_rainbow[10][10]={   {0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000},   {0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000},   {0x000000,0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000},   {0x000000,0x000000,0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff},   {0x8f00ff,0x000000,0x000000,0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff},   {0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff},   {0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00},   {0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000,0xff0000,0xff7f00,0xffff00},   {0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000,0xff0000,0xff7f00},   {0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000,0xff0000}, }; // *********************************************************************************************************** // * // *                            Power Up Init. // * // * // *********************************************************************************************************** void setup() {                 STRIP_PINOUT;        // set output pin - DEBUG: should auto detect which mother board for use   reset_strip();   //noInterrupts(); } // *********************************************************************************************************** // * // *                            Main Loop // * // * // *********************************************************************************************************** void loop() {   send_1M_pattern(pattern_test_red, 10, 500);   delay(500);   send_1M_pattern(pattern_test_blue, 10, 500);   delay(500);   send_1M_pattern(pattern_test_green, 10, 500);   delay(500);   send_1M_pattern(pattern_test_white, 10, 500);   delay(500);   send_1M_pattern(pattern_test_comet1, 10, 70);   delay(500);   send_1M_pattern(pattern_test_comet2, 10, 70);   delay(500);   send_1M_pattern(pattern_test_comet3, 10, 70);   delay(500);   while (1)   {     send_1M_pattern(pattern_test_rainbow, 10, 70);   }   /* frame++;     if(frame<=10) LEDSTRIP_PATTERN_0();     if(10     if(20     if(frame>30) frame=1;    */   //delay(1); } /******************************************************************************* * Function Name  : send_1M_pattern * Description    : Transmit pattern to whole 1 meter strip *                 * Input          : pointer to ROM pattern; pattern length; frame rate *                 * Output         : None * Return         : None *******************************************************************************/ void send_1M_pattern(const unsigned long data[][10], int pattern_no, int frame_rate) {   int i=0;   int j=0;   uint32_t temp_data;   for (i=0;i   {     noInterrupts();     for (j=0;j<10;j++)     {       temp_data=pgm_read_dword_near(&data;[i][j]);       send_strip(temp_data);     }     interrupts();     delay(frame_rate);   } } /******************************************************************************* * Function Name  : send_strip * Description    : Transmit 24 pulse to LED strip *                 * Input          : 24-bit data for the strip *                 * Output         : None * Return         : None *******************************************************************************/ void send_strip(uint32_t data) {   int i;   unsigned long j=0x800000;   for (i=0;i<24;i++)   {     if (data & j)     {       DATA_1;       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");         __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");      /*----------------------------*/       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       /*----------------------------*/           DATA_0;     }     else     {       DATA_1;       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");         DATA_0; /*----------------------------*/            __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");     /*----------------------------*/            }     j>>=1;   } } /******************************************************************************* * Function Name  : reset_strip * Description    : Send reset pulse to reset all color of the strip *                 * Input          : None *                 * Output         : None * Return         : None *******************************************************************************/ void reset_strip() {   DATA_0;   delayMicroseconds(20); } //***********AND HERE"S MY MODIFIED LIGHT SHOW CODE:*********** #include // ******** DEBUG ==== should auto config to adapt different mother board ********* //#define DATA_1 (PORTF |=  0X01)    // DATA 1    // for ATMEGA //#define DATA_0 (PORTF &=  0XFE)    // DATA 0    // for ATMEGA //#define STRIP_PINOUT DDRF=0xFF  // for ATMEGA #define DATA_1 (PORTC |=  0X01)    // DATA 1    // for UNO #define DATA_0 (PORTC &=  0XFE)    // DATA 0    // for UNO #define STRIP_PINOUT (DDRC=0xFF)    // for UNO PROGMEM const unsigned long pattern_test_red[10][10]={   {0xff0000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0xff0000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0xff0000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0xff0000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0xff0000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0xff0000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xff0000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xff0000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xff0000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xff0000}, }; PROGMEM const unsigned long pattern_test_blue[10][10]={   {0x00ff00,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x00ff00,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x00ff00,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x00ff00,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x00ff00,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x00ff00,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x00ff00,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x00ff00,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x00ff00,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x00ff00}, }; PROGMEM const unsigned long pattern_test_green[10][10]={   {0x0000ff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x0000ff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x0000ff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x0000ff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x0000ff,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x0000ff,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x0000ff,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x0000ff,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x0000ff,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x0000ff}, }; PROGMEM const unsigned long pattern_test_white[10][10]={   {0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff}, }; PROGMEM const unsigned long pattern_test_comet1[][10]={   {0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000},   {0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff}, }; PROGMEM const unsigned long pattern_test_comet2[][10]={   {0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000},   {0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000},   {0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000},   {0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000},   {0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff},   {0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000},   {0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000},   {0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000},   {0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000},   {0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0x111111,0x444444,0xffffff}, }; PROGMEM const unsigned long pattern_test_comet3[][10]={   {0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff},   {0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0x000000,0x000000,0xffffff,0x444444},   {0x111111,0x444444,0xffffff,0x000000,0x000000,0x000000,0x000000,0xffffff,0x444444,0x111111},   {0x000000,0x111111,0x444444,0xffffff,0x000000,0x000000,0xffffff,0x444444,0x111111,0x000000},   {0x000000,0x000000,0x111111,0x444444,0xffffff,0xffffff,0x444444,0x111111,0x000000,0x000000},   {0x000000,0x000000,0x111111,0x444444,0xffffff,0xffffff,0x444444,0x111111,0x000000,0x000000},   {0x000000,0x000000,0x000000,0xffffff,0x444444,0x444444,0xffffff,0x000000,0x000000,0x000000},   {0x000000,0x000000,0xffffff,0x444444,0x111111,0x111111,0x444444,0xffffff,0x000000,0x000000},   {0x000000,0xffffff,0x444444,0x111111,0x000000,0x000000,0x111111,0x444444,0xffffff,0x000000},   {0xffffff,0x444444,0x111111,0x000000,0x000000,0x000000,0x000000,0x111111,0x444444,0xffffff}, }; PROGMEM const unsigned long pattern_test_rainbow[10][10]={   {0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000},   {0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000},   {0x000000,0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000},   {0x000000,0x000000,0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff},   {0x8f00ff,0x000000,0x000000,0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff},   {0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00,0x0000ff},   {0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000,0xff0000,0xff7f00,0xffff00,0x00ff00},   {0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000,0xff0000,0xff7f00,0xffff00},   {0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000,0xff0000,0xff7f00},   {0xff7f00,0xffff00,0x00ff00,0x0000ff,0x6f00ff,0x8f00ff,0x000000,0x000000,0x000000,0xff0000}, }; // *********************************************************************************************************** // * // *                            Power Up Init. // * // * // *********************************************************************************************************** void setup() {                 STRIP_PINOUT;        // set output pin - DEBUG: should auto detect which mother board for use   reset_strip();   //noInterrupts(); } // *********************************************************************************************************** // * // *                            Main Loop // * // * // *********************************************************************************************************** void loop() {   send_1M_pattern(pattern_test_white, 0, 0);   delay(36000);   send_1M_pattern(pattern_test_white, 500,0);   delay(5000);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);    send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);    send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);     send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 10, 70);   delay(10);   send_1M_pattern(pattern_test_white, 500, 0);   delay(4000);      while (1)   {     send_1M_pattern(pattern_test_rainbow, 10, 70);   }   /* frame++;     if(frame<=10) LEDSTRIP_PATTERN_0();     if(10     if(20     if(frame>30) frame=1;    */   //delay(1); } /******************************************************************************* * Function Name  : send_1M_pattern * Description    : Transmit pattern to whole 1 meter strip *                 * Input          : pointer to ROM pattern; pattern length; frame rate *                 * Output         : None * Return         : None *******************************************************************************/ void send_1M_pattern(const unsigned long data[][10], int pattern_no, int frame_rate) {   int i=0;   int j=0;   uint32_t temp_data;   for (i=0;i   {     noInterrupts();     for (j=0;j<10;j++)     {       temp_data=pgm_read_dword_near(&data;[i][j]);       send_strip(temp_data);     }     interrupts();     delay(frame_rate);   } } /******************************************************************************* * Function Name  : send_strip * Description    : Transmit 24 pulse to LED strip *                 * Input          : 24-bit data for the strip *                 * Output         : None * Return         : None *******************************************************************************/ void send_strip(uint32_t data) {   int i;   unsigned long j=0x800000;   for (i=0;i<24;i++)   {     if (data & j)     {       DATA_1;       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");         __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");      /*----------------------------*/       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       /*----------------------------*/           DATA_0;     }     else     {       DATA_1;       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");         DATA_0; /*----------------------------*/            __asm__("nop\n\t");       __asm__("nop\n\t");       __asm__("nop\n\t");     /*----------------------------*/            }     j>>=1;   } } /******************************************************************************* * Function Name  : reset_strip * Description    : Send reset pulse to reset all color of the strip *                 * Input          : None *                 * Output         : None * Return         : None *******************************************************************************/ void reset_strip() {   DATA_0;   delayMicroseconds(20); }

Posted by ray33_ 4 years ago


I want some one to help me at making RC car controlled by wifi esp2866 and AVR atmega 32?

Greetings,iam mustafa,working right now as it technical support engineer for 3 years and 7 months .I have never made project for RC car or any project related to embedded systems as i was always scared and think that people who create these things are super smart and iam not smart enough .i always wish to work as embedded software engineer but i've never made a project in real life. i studied c programming and materials related with avr architecture and had many interviews but i fail always .At last interview, i'd failed and the interviewer asked me to do a project so that i get better .i decided to challenge myself and build an rc car .i asked a friend of mine to help me in project& i made a code using atmel studio IDE and simulator(proteus) to test my code..my code could move the dc motor right ,left and backward and forward till this moment on the simulator (proteus software) .After while i was sick and my friend was busy as he traveled abroad cause of his work.and iam very disappointed as i didn't finish my project .i get older and i want to make a shift career and work as an embedded software engineer but iam afraid that i won't achieve my dream . i hope this post will give me a hope to continue the path of achieving my dream careeri have bought this things: 4 DC motors 12 vwifi moduleH bridge moduleresistors and wires and breadboard===============================i hope that i find some one who is patient and keep an eye on me while i do the project .Thanks all

Posted by MustafaS72 4 months ago


Robosapiens india and IIT-G presents

'Short Term Internship Program in Robotics and Embedded 'C' certified by Techniche'09 IIT-Guwahati and robosapiens India.http://www.robosapiensindia.comSTIP or Short Term Internship Program is a career oriented program which gives the participants the opportunity to have a tété-a-tété with the industrial approach to Robotics and Embedded C. It gives you an insight into micro controller and what goes into the making of an embedded system. This duration specific program has been introduced as a result of popular demand from participants of our previous programs.We fell proud to present you with this unique internship variation which will not only change the perception of an internship but will also improve its credibility and efficiency. The course outline is as follows:Course Outline:- • Embedded System Design and Robotics: An Introduction• Microcontrollers & their Architecture• Introduction to Embedded C Programming • Interfacing of peripherals to Microcontrollers • Project Building • Introduction to concepts of RTOSThis course includes the Free Embedded system SDK to all participants.Why this course is a ‘must’?So why should a student go for STIP. We think the following summarizes the plethora of reasons why STIP is a dream for every embedded system and robotics enthusiast:• Embedded System is best understood by applying it in robotics.• Robotics and Embedded systems have a lot of scope in college projects.• The AVR series that we will be using is the most commonly employed series for micro controller at both academic and industrial level.• A participant gets to learn and apply Embedded C programming which is the main programming language for embedded systems with resource constraints. • This is the best way to get to know other robotics enthusiast around the country. • One gets to be in touch with the most talented and experienced professionals in this area of academics and interact with them.STIP benefits in a nutshell:• Exhaustive training with extensive guidance by our panel of experts.• The project based completion of curriculum with both theory classes and hands on sessions.• One can also buy development boards and other robot parts that we’ll use throughout the program.• Certification by IIT Guwahati; Techniche’ 09.• Accommodation facility for participants coming from far away locales.Free Embedded system SDK kit includes :• AVR series microcontroller Based Reserach plateform.• 1 Atmega 16 Microcontroller.• AVR series Universal Programmer.• Connecting cables.• 1 LCD display.• Robosapiens india AVR Loader v1.0 Beta software package.Certification by Techniche'09 IIT-Guwahati and Robosapiens India.Robosapiens India ties up with Techniche'09 India Institute of Technology. All the participants will get a valid Certificate from us.STIP Program cost includes:• Two weeks instructor led exhaustive training.• Two weeks of industry defined, project work.• Take away Embedded system SDK Kit.• Post Training assistance for Project work.• Accommodation assistance.Course Curriculum Details :Embedded System Design: An Introduction Introduction to micro controller is the first step to know about embedded systems. What is a micro controller? What’s inside it? What makes it an embedded system? What are the different families of microcontroller, its derivatives and its applications in industrial projects? Why AVR is the most widely used micro controller family? What goes into designing an embedded system? Its criteria and handling resource constraints.Introduction to Microcontrollers and AVR Architecture This session includes introduction to the AVR series of micro controller, especially ATMega16, which we will be using in our program.Introduction to ATMega16 features viz. • I/O Ports. • Data Registers• Interrupts. • Timer/Counter. • External/Internal clocks• ADC (Analog to Digital Conversion using ATMega16). This session is for familiarization with various functional blocks of the microcontrollers and knowing the inside story of it. Introduction to Embedded C Programming • Embedded C-Programming for Microcontroller. • Introduction to C, Flow control statements, functions. • Data Types, operators and expressions. • Program structures and debugging. • Program Burning and Execution Interfacing of peripherals to Microcontroller(Atmega 16) • Actuators. • Geared DC Motor. • Stepper Motor. • Motor Driver. • Relays. • Solid State Drivers. • Integrated Circuit drivers. Interfacing of various kind of Display devices• Displays. • LED. • LCD. Interfacing various human interface devices with the microcontroller.• Input Devices. • Switches. Interfacing and Study of Sensors to enable microcontroller to acquire environmental data.• Sensors. • Temperature Sensors. • Light Sensors. Project Building and implementation of ideas• Designing• Devlopment• Programming and customizing • Debugging

Posted by meetbajwa 9 years ago


Ethernet.h causing problems with 7 segment display driver [Arduino]

Hey Instructables,  I have a really annoying issue with some Arduino code I am writing.  The code is for an ethernet controlled countdown timer.  In it's component parts the functions all work fine,  I can drive the 7 segment display fine. I can start/stop/set a count over Ethernet However as soon as I add the line  Ethernet.begin(mac, ip); in void setup()  The 7 segment display starts to show errors, specifically the first of the four digits. Even If I don't include any additional Ethernet related code in the loop, just calling the library on setup causes problems.  I'm not an especially experienced programmer so I'm really hoping someone can share a little of their wisdom here! #include #include          // needed for Arduino versions later than 0018 #include #include          // UDP library from: bjoern@cs.stanford.edu 12/30/2008 int digit1 = 11; //PWM Display pin 1 int digit2 = 10; //PWM Display pin 2 int digit3 = 9; //PWM Display pin 6 int digit4 = 6; //PWM Display pin 8 //Pin mapping from Arduino to the ATmega DIP28 if you need it //http://www.arduino.cc/en/Hacking/PinMapping int segA = A1; //Display pin 14 int segB = 3; //Display pin 16 int segC = 4; //Display pin 13 int segD = 5; //Display pin 3 int segE = A0; //Display pin 5 int segF = 7; //Display pin 11 int segG = 8; //Display pin 15 // Enter a MAC address and IP address for your controller below. // The IP address will be dependent on your local network: byte mac[] = {   0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED }; IPAddress ip(192, 168, 1, 177); unsigned int localPort = 8888;      // local port to listen on // buffers for receiving and sending data char packetBuffer[UDP_TX_PACKET_MAX_SIZE]; //buffer to hold incoming packet, char ReplyBuffer[] = "acknowledged";       // a string to send back // An EthernetUDP instance to let us send and receive packets over UDP EthernetUDP Udp; elapsedMillis timeElapsed; //declare global if you don't want it reset every time loop runs //  milliseconds in a second unsigned int interval = 1000; unsigned int seconds = 0; unsigned int state = 1; unsigned int timeSetting = 10; unsigned int oldSeconds = 0; char theCount[9] = "01:06:30"; int secs = 0; int mins = 0; int hours = 0; String isItTime = ""; String firstFour = ""; void setup() {                      Ethernet.begin(mac, ip);   Udp.begin(localPort);      pinMode(segA, OUTPUT);   pinMode(segB, OUTPUT);   pinMode(segC, OUTPUT);   pinMode(segD, OUTPUT);   pinMode(segE, OUTPUT);   pinMode(segF, OUTPUT);   pinMode(segG, OUTPUT);   pinMode(digit1, OUTPUT);   pinMode(digit2, OUTPUT);   pinMode(digit3, OUTPUT);   pinMode(digit4, OUTPUT);     pinMode(13, OUTPUT);     } void loop() {     displayNumber(millis()/1000);    } void displayNumber(int toDisplay) { #define DISPLAY_BRIGHTNESS  500 #define DIGIT_ON  HIGH #define DIGIT_OFF  LOW   long beginTime = millis();   for(int digit = 4 ; digit > 0 ; digit--) {     //Turn on a digit for a short amount of time     switch(digit) {     case 1:       digitalWrite(digit1, DIGIT_ON);       break;     case 2:       digitalWrite(digit2, DIGIT_ON);       break;     case 3:       digitalWrite(digit3, DIGIT_ON);       break;     case 4:       digitalWrite(digit4, DIGIT_ON);       break;     }     //Turn on the right segments for this digit     lightNumber(toDisplay % 10);     toDisplay /= 10;     delayMicroseconds(DISPLAY_BRIGHTNESS); //Display this digit for a fraction of a second (between 1us and 5000us, 500 is pretty good)     //Turn off all segments     lightNumber(10);     //Turn off all digits     digitalWrite(digit1, DIGIT_OFF);     digitalWrite(digit2, DIGIT_OFF);     digitalWrite(digit3, DIGIT_OFF);     digitalWrite(digit4, DIGIT_OFF);   }   while( (millis() - beginTime) < 10) ; //Wait for 20ms to pass before we paint the display again } //Given a number, turns on those segments //If number == 10, then turn off number void lightNumber(int numberToDisplay) { #define SEGMENT_ON  LOW #define SEGMENT_OFF HIGH   switch (numberToDisplay){   case 0:     digitalWrite(segA, SEGMENT_ON);     digitalWrite(segB, SEGMENT_ON);     digitalWrite(segC, SEGMENT_ON);     digitalWrite(segD, SEGMENT_ON);     digitalWrite(segE, SEGMENT_ON);     digitalWrite(segF, SEGMENT_ON);     digitalWrite(segG, SEGMENT_OFF);     break;   case 1:     digitalWrite(segA, SEGMENT_OFF);     digitalWrite(segB, SEGMENT_ON);     digitalWrite(segC, SEGMENT_ON);     digitalWrite(segD, SEGMENT_OFF);     digitalWrite(segE, SEGMENT_OFF);     digitalWrite(segF, SEGMENT_OFF);     digitalWrite(segG, SEGMENT_OFF);     break;   case 2:     digitalWrite(segA, SEGMENT_ON);     digitalWrite(segB, SEGMENT_ON);     digitalWrite(segC, SEGMENT_OFF);     digitalWrite(segD, SEGMENT_ON);     digitalWrite(segE, SEGMENT_ON);     digitalWrite(segF, SEGMENT_OFF);     digitalWrite(segG, SEGMENT_ON);     break;   case 3:     digitalWrite(segA, SEGMENT_ON);     digitalWrite(segB, SEGMENT_ON);     digitalWrite(segC, SEGMENT_ON);     digitalWrite(segD, SEGMENT_ON);     digitalWrite(segE, SEGMENT_OFF);     digitalWrite(segF, SEGMENT_OFF);     digitalWrite(segG, SEGMENT_ON);     break;   case 4:     digitalWrite(segA, SEGMENT_OFF);     digitalWrite(segB, SEGMENT_ON);     digitalWrite(segC, SEGMENT_ON);     digitalWrite(segD, SEGMENT_OFF);     digitalWrite(segE, SEGMENT_OFF);     digitalWrite(segF, SEGMENT_ON);     digitalWrite(segG, SEGMENT_ON);     break;   case 5:     digitalWrite(segA, SEGMENT_ON);     digitalWrite(segB, SEGMENT_OFF);     digitalWrite(segC, SEGMENT_ON);     digitalWrite(segD, SEGMENT_ON);     digitalWrite(segE, SEGMENT_OFF);     digitalWrite(segF, SEGMENT_ON);     digitalWrite(segG, SEGMENT_ON);     break;   case 6:     digitalWrite(segA, SEGMENT_ON);     digitalWrite(segB, SEGMENT_OFF);     digitalWrite(segC, SEGMENT_ON);     digitalWrite(segD, SEGMENT_ON);     digitalWrite(segE, SEGMENT_ON);     digitalWrite(segF, SEGMENT_ON);     digitalWrite(segG, SEGMENT_ON);     break;   case 7:     digitalWrite(segA, SEGMENT_ON);     digitalWrite(segB, SEGMENT_ON);     digitalWrite(segC, SEGMENT_ON);     digitalWrite(segD, SEGMENT_OFF);     digitalWrite(segE, SEGMENT_OFF);     digitalWrite(segF, SEGMENT_OFF);     digitalWrite(segG, SEGMENT_OFF);     break;   case 8:     digitalWrite(segA, SEGMENT_ON);     digitalWrite(segB, SEGMENT_ON);     digitalWrite(segC, SEGMENT_ON);     digitalWrite(segD, SEGMENT_ON);     digitalWrite(segE, SEGMENT_ON);     digitalWrite(segF, SEGMENT_ON);     digitalWrite(segG, SEGMENT_ON);     break;   case 9:     digitalWrite(segA, SEGMENT_ON);     digitalWrite(segB, SEGMENT_ON);     digitalWrite(segC, SEGMENT_ON);     digitalWrite(segD, SEGMENT_ON);     digitalWrite(segE, SEGMENT_OFF);     digitalWrite(segF, SEGMENT_ON);     digitalWrite(segG, SEGMENT_ON);     break;   case 10:     digitalWrite(segA, SEGMENT_OFF);     digitalWrite(segB, SEGMENT_OFF);     digitalWrite(segC, SEGMENT_OFF);     digitalWrite(segD, SEGMENT_OFF);     digitalWrite(segE, SEGMENT_OFF);     digitalWrite(segF, SEGMENT_OFF);     digitalWrite(segG, SEGMENT_OFF);     break;   } }

Posted by drkovorkian 3 years ago