CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

My Story Is Just Beginning
Goto page 1, 2  Next
 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
MCUprogrammer



Joined: 08 Sep 2020
Posts: 221

View user's profile Send private message

My Story Is Just Beginning
PostPosted: Tue Sep 08, 2020 7:38 am     Reply with quote

Hello Everybody
I just graduated from school. Sorry for my English. I will write using google translate. Of course I don't always think of using Google Translate like this. I will improve my English by writing and reading over time. I want to do nice work with microprocessors. There are 2 reasons for this.
First of all, it excites me to produce new things and to think about them. This is a very good feeling.
The second is to write programs, it sounds very impressive. I want to do this job.
I have an enormous time ahead of me. I just started walking. Your suggestions are very precious to me, my masters. I bought the necessary equipment for the software. Now where and how should I start?
_________________
Best Regards...
MCUprogrammer
_______________________________
Work Hard
dluu13



Joined: 28 Sep 2018
Posts: 395
Location: Toronto, ON

View user's profile Send private message Visit poster's website

PostPosted: Tue Sep 08, 2020 9:51 am     Reply with quote

Honestly if you are totally new, I would go and buy an Arduino off Amazon or something and start by blinking a light and then go from there. If you're not from the hardware side, programming microcontrollers represents somewhat of a paradigm shift compared to writing software just to run on a computer.
elcrcp



Joined: 11 Mar 2016
Posts: 62
Location: izmir / Turkey

View user's profile Send private message

PostPosted: Tue Sep 08, 2020 2:02 pm     Reply with quote

Hello and welcome,
Quick answer; MCU programming is all about to know the part u are using. You should know what are you programming and what is happening inside the chip with the lines you are writing. Once you understand this, it doesn't matter which MCU u are using, only languages and syntaxes change.
So, first step is to learn and understand MCU architect and register structure, so buy a few good books, watch some videos then buy a development board and start trying.

And this is my idea but I actually would not recommend arduino for learning. Yes it is very easy to use, you can find thousands of examples and drivers, you can make many things easily but you don't see registers, you don't read datasheets, you don't know what is happening in low levels which I think very important to understand.
_________________
There is nothing you can't do if you try
dluu13



Joined: 28 Sep 2018
Posts: 395
Location: Toronto, ON

View user's profile Send private message Visit poster's website

PostPosted: Tue Sep 08, 2020 2:42 pm     Reply with quote

That's valid too.

But I was coming from the standpoint that there are some people who have never coded anything physical before. The Arduino at least provides an easy introduction to how your lines of code are literally pushing voltages around.
Then you know what the correct result is supposed to look like.

Just a different perspective.

Knowing what I do now, if I had not started in easy mode with Arduino, I would have been totally intimidated by microcontrollers.
dyeatman



Joined: 06 Sep 2003
Posts: 1934
Location: Norman, OK

View user's profile Send private message

PostPosted: Tue Sep 08, 2020 4:31 pm     Reply with quote

I agree that one of the easiest routes to get started is the Arduino ESP32 that
you can get for little money and all the software development tools are free.
_________________
Google and Forum Search are some of your best tools!!!!
MCUprogrammer



Joined: 08 Sep 2020
Posts: 221

View user's profile Send private message

PostPosted: Wed Sep 09, 2020 12:44 am     Reply with quote

Thank you very much for your beautiful opinions. I took buy a PCWHD IDE Compiler. And I took buy ICD-U80 and Mach X device. I took buy Embedded C Programming: Techniques and Applications of C and PICĀ® MCUs by Mark Siegesmund. Which site you suggest to me ? Where can I see the code samples for CCS C compiler ?
_________________
Best Regards...
MCUprogrammer
_______________________________
Work Hard
Ttelmah



Joined: 11 Mar 2010
Posts: 19520

View user's profile Send private message

PostPosted: Wed Sep 09, 2020 1:02 am     Reply with quote

When you install the compiler, there is an 'examples' directory.
Guess what this contains!...
Also though look at the code library here on the forum. This has lots
of threads that give yet more examples.
MCUprogrammer



Joined: 08 Sep 2020
Posts: 221

View user's profile Send private message

PostPosted: Wed Sep 09, 2020 1:39 am     Reply with quote

thanks...
_________________
Best Regards...
MCUprogrammer
_______________________________
Work Hard
temtronic



Joined: 01 Jul 2010
Posts: 9229
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Wed Sep 09, 2020 4:54 am     Reply with quote

comment
Consider the PIC18F46K22 and PIC18F26K22 versions.
A few years ago I chose them as the best PIC to use. While more expensive than say an 18 pin PIC, they have LOTS of memeory, 2 hardware UARTS and I2C/SPI, several timers and LOTS of pins ! They also will run with either a 5 or 3 volt VDD, making them directly compatible with all the 3 volt external peripherals. As well the internal clock can run at 64MHz.
While there are always 'newer and better' PICs every day, if you can get ONE that does 'everything' and always use it, you get a solid,reliable PIC. I've yet to run out of memory or pins. I always keep the ICSP pins for programming. while they can be used to control 'stuff',sometimes that 'stuff' interferes with ICSP unless properly designed. You always 'need' another pin, so I use the 46k22 for 99% of all my projects.
By using one PIC , you also build your own libraries of functions and drivers you KNOW work with that PIC.


I understand it can be difficult in other countries,but the Web has made the World smaller, easier to get parts and help like this forum.
MCUprogrammer



Joined: 08 Sep 2020
Posts: 221

View user's profile Send private message

PostPosted: Wed Sep 09, 2020 5:54 am     Reply with quote

understood. For information thank you very much. Mr. temtronic what is your job. What do you do with PIC processors. Where do you do use.
_________________
Best Regards...
MCUprogrammer
_______________________________
Work Hard
diode_blade



Joined: 18 Aug 2014
Posts: 55
Location: Sheffield, South Yorkshire

View user's profile Send private message Send e-mail

PostPosted: Thu Sep 10, 2020 1:52 am     Reply with quote

If I may add my two shillings worth.
After I was made redundant from my first job in electrical motor repair in 1993 (apprentice from 1979), I went back to college to study my second hobby electronics and was introduced to programming on the course using Z80 MCU/MPU boards, entering nouns and verbs, I then went to hallam university on a 2 year HND electronics course in 1995 then going onto a Beng degree course.
That is when I was introduced to the world of PIC's (16F84), all written in assembler, doing that has been a godsend.
due to family circumstances after 3 years I had to give the course up. I then got the job I am working in now, one of my first projects was was using a 16c74 to make keypad number entry system for a steelworks to enter batch numbers for weighing billets of steel on a weigh system (still working) all done in assembler (also a few other projects).
A few years later I upgraded the system but converted the program to CCS C with a more modern Pic.
But that start in assembler helped enormously in understanding how things worked.
Now i'm lucky if I can program my microwave or tv...... Mr. Green
So if you can write a simple LED blinking program on a PIC in assembler it will help you a lot in understanding how things work on them.
temtronic



Joined: 01 Jul 2010
Posts: 9229
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Thu Sep 10, 2020 5:24 am     Reply with quote

I've been retired for 30 years, just 'play with PICs' now, though I do some 'Proof of Concept' projects. When I started, PICs had neat quartz windows on top and needed 15 minutes to erase my code ! Most of my projects have dealt with 'energy control'. Most challenging was to communicate 15 miles using solid copper wire( Bell lines) to control building heaters.This is true single wire communication with extensive fault detection/bypass ability. Also a lot of Greenhouse designs.Easy to test,have GH in backyard ! Currently have a PIC controlling worklights, backup lights and electric brakes on small utility trailers that only have 4 wires.. Neighbour wants LED lights to extend egg production, so thats a PIC with sunrise/sunset calculations and PWM the LEDs to mimic the sunup/sundown.
diode_blade



Joined: 18 Aug 2014
Posts: 55
Location: Sheffield, South Yorkshire

View user's profile Send private message Send e-mail

PostPosted: Fri Sep 11, 2020 1:46 am     Reply with quote

temtronic wrote:
I've been retired for 30 years, just 'play with PICs' now, though I do some 'Proof of Concept' projects. When I started, PICs had neat quartz windows on top and needed 15 minutes to erase my code ! Most of my projects have dealt with 'energy control'. Most challenging was to communicate 15 miles using solid copper wire( Bell lines) to control building heaters.This is true single wire communication with extensive fault detection/bypass ability. Also a lot of Greenhouse designs.Easy to test,have GH in backyard ! Currently have a PIC controlling worklights, backup lights and electric brakes on small utility trailers that only have 4 wires.. Neighbour wants LED lights to extend egg production, so thats a PIC with sunrise/sunset calculations and PWM the LEDs to mimic the sunup/sundown.


Laughing
Yes having a load of windowed pics in the uv eraser unit waiting for them to cook blank...happy days
MCUprogrammer



Joined: 08 Sep 2020
Posts: 221

View user's profile Send private message

PostPosted: Mon Sep 14, 2020 12:20 am     Reply with quote

Thank you very much for answer. What site are you using to research about the PIC project? What to be careful while I do project. Should I continue as Software and Hardware? Or is it just one. Also, when talking to the PC, which compiler would you suggest? For example: Java, c#, vb. So now when I start, I want to continue with the compiler I learned without changing. Your suggestions are very important to me.
_________________
Best Regards...
MCUprogrammer
_______________________________
Work Hard
temtronic



Joined: 01 Jul 2010
Posts: 9229
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Mon Sep 14, 2020 5:02 am     Reply with quote

For PC communications I use RealTerm. It's a free, 'terminal' program similar to Hyperterminal but with more features. It does have the ability to store data into a file. Say you create a 'datalogger' or 'monitoring' PIC program. If you format the data sent to the PC in CSV format (Comma Separated Variables), once the data file is closed, you can then 'import' that data into an Excel spreadsheet and the data will automatically align itself.
For the hardware interface, I use USB<>TTL modules. I stopped using PICs with internal USB,since the cost of USB connector, LED, PCB layout ,etc. was over $1 and the module is just $2 CDN. The module supplies both 5 and 3v and contains all the SW needed to run. This eliminates the 'USB driver', so it frees up PIC programming space, and it WORKS...no need to troubleshoot your code.
I've got a PIC18F46K22 in front of me, using the USBTTL module connected to my PC, recording greenhouse temperatures every minute, has worked for months.
As for hardware vs software, you need to do both ! Consider using the 46k22 as your PIC. By using the same PIC for both big and small projects, you can concentrate on coding as opposed to trying to learn new pinouts or features for several different PICs. Newer PICs may have 'bugs' in them or the compiler may not be 100% compatible. Staying with one PIC also gives you a 'library' of functions and drivers that you KNOW work.
The other module I use is an RTC/EEP unit. Another $2 module, it's actually cheaper than buying the parts ! It has a DS3231 RTC that keeps accurate time and is battery backed.
It would be nice to find a 'protoboard' that had 46k22 socket as well as 'Arduino' module connections. It'd make a nice 'platform' to build projects on.
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group