![]() | |
| Home Page | Mark Forums Read | Today's Posts | My Replies | Classifieds | Reviews | Photo Gallery | Web Links | Share Files | Advertise With Us | Ad List |
| |||||||
| PIC Programing / Design Discuss programing of PIC chips here and design of electronics using PIC chips. |
![]() |
| | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
#1
| |||
| |||
I don't know much about programming pic's, but would like to learn & build a pic timer with battery back up for my pool pump and later add on a few extra's. I have a EASYPIC2 development board from MikroElectronika and would like some advice on choice of micro chips for such a project. Eventually I want to add things like temp sensors - rain sensor - day/night sensor - wind sensor etc. Advice on choice of programming language & chips (16f628A/16f877A)would be great thanks anilam |
|
#2
| ||||
| ||||
| I was in the same boat as you a couple of years ago. I started with PIC Basic initially because I knew some Basic from the mid 80's (Commodore 64) and knew nothing about C let alone Assembly Language. I started with the 12F675 (6 pins) because they were cheap cheap cheap. My first project was a boost button for a battery powered rideon toy that would double the power output of the motors by switching from 12 volts to 24 volts on the fly. The 12F675 monitored 3 internal timers/counters and three inputs (gas, gear position, and boost button press) and if the conditions were met would drive the output pins for an RGB LED circuit to inform the driver whether Boost was available (flashing red - stopped, red - in low gear or reverse, yellow - 10 second timer for "boost charging", green - BOOST AVAILABLE for six seconds when button pressed and held.) PIC Basic is easy to learn and if your timers do not need to be accurate to clock cycle resolution, then this is an easy way to get introduced. In other words, if your timers only need to be accurate to say the second, minute, or hour, and you don't need to simultaneously monitor inputs via interrupt routines, PIC Basic is fantastic - especially on the 8 lane highway PICs (8 Bit). I still use PIC Basic today for a lot of projects which are quick and dirty - but there is nothing like using assembly language to really control the power of the PIC - once I started getting into complex timing projects which required the use of interrupt routines, I quickly learned PIC Assembly language. I had never programmed in Assembly before but there are lots of online tutorials to help - Assembly will also force you to become intimately involved with your PIC datasheet which is where you learn the true power of a PIC. If you understand basic electronic theory, basic binary math and basic boolean logic, you will master PIC based assembly in no time. Once you learn PIC assembly, you will inherently understand C programming from reading a particular C command's description. The structure of C will also make way more sense. The 8 Bit pics are extremely powerful for what they pack - the 12F675 may seem like an entry level PIC (and is) but it still has an onboard oscillator, 6 I/O pins, 128 Bytes of EEPROM, 2 timers, 1 comparator, and one A/D converter with 4 inputs. It will easily handle you project you describe. Higher up the 8 Bit food chain you can look at the 16F9xx PICS which have more inputs, more timers, more AD converters, more comparators, more memory, LCD drivers, serial port communications, etc. - all with the same instruction set as the lowly 12F675! If the 8 lane highway starts getting too crowded, jump over to the 16 or 32 lane PICS such as the 18F series or 24F series - want to start playing with High Speed BUSES like CAN, these are the PICS for you. The instruction sets add a few more cool commands which will make programming even easier. Anyway, PICS are like heroin - once you use them, withdrawal symptoms are killer! |
|
#3
| |||
| |||
I think I'll stick with basic for now. I will have to source some of these 12f675's in the mean time I will just use my 16f628A to experiment with? great thanks till later anilam |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search this Thread |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Need advice in my project | elchip | UHU Servo Controllers | 1 | 10-31-2009 06:15 PM |
| Need motor advice for a project... | kentrob11 | General Electronics Discussion | 0 | 03-21-2008 09:05 AM |
| Need advice, newb question here. | DerHammer | Fanuc | 6 | 11-13-2007 12:23 AM |
| Need some advice on my project | sigipa | Mechanical Calculations/Engineering Design | 9 | 09-16-2007 11:43 AM |
| Advice for a Complete Newb on DIY CNC | waglo | DIY-CNC Router Table Machines | 2 | 04-05-2005 07:59 AM |