![]() |
|
|||||||
| Embedded Systems and Microcontrollers Discussion forum for projects and working with embedded systems and microcontrollers (FPGAs, PICs, AVRs). Get help with hardware issues and embedded programming. |
|
|
|
Thread Tools | Display Modes |
|
#11
|
|||
|
|||
|
Oh, and Stuntman, none of my rant (and I suspect Mr. Chips' as well) was directed specifically at you. In fact, I applaud you for asking the question you did in order to get a better understanding, especially since you (thought you) had found a solution to your problem. Too many people are like monkeys at a keyboard and as soon as they find some random way of writing the code the produces the immediately desired answer, will mark the issue resolved and moved on. You didn't -- and good for you!
|
|
#12
|
||||
|
||||
|
I appreciate the comprehensive explanation, I did not realize this was a rudimentary concept in C for mcu's.
|
|
#13
|
|||
|
|||
|
That's basics in C, in general, not just MCUs
|
|
#14
|
|||
|
|||
|
It's not just a rudimentary concept in C for MCUs, it is a rudimentary concept in the C language, period.
Since code compiled for an integer-only processor (as most MCUs are) has to work under much greater restrictions and suffers much greater penalties for having to emulate things that other processors support natively, I highly recommend becoming familier with the C standard. While you have to buy the actual standard, you can download the draft standard for free from a lot of places and there are very few differences (I'm not aware of any that are of substance, but I could be wrong). It is a big document and can be intimidating, so take it in chunks. Use it to explore specific issues and questions, first. There are a lot of things there, especially in the early material, that will be hard to wrap your mind around. That's fine, read it anyway and some of it will make a bit of sense and then, as you work with the material, more chunks will start to make sense. Trust me, you will learn a LOT about a LOT more than C. You will get a glimpse of how high level programs are made to work under the hood and that will greatly expand the toolbox you havefor figuring out how to even attack complex problems with an MCU, an FPGA, or even scratch logic. |
|
#15
|
||||
|
||||
|
This is rudimentary in all computer languages. One needs to be aware of how all variables are stored and manipulated on a computer.
__________________
Most computer problems can be attributed to a simple problem - a loosewire behind the keyboard. |
|
#16
|
|||
|
|||
|
Agreed. It is one of the reasons why I hate dynamically-typed languages where the compiler/interpretter gets to choose what kind of data storage I need. I don't want a compiler that does too much of my thinking for me and I want to be able to easily force it to do what I want in most circumstances. This is becoming harder and harder to do; yes, it is also making it easier for relatively unskilled programmers to make working code that doesn't have many of the flagrant flaws and weaknesses that a less capable language/compiler might produce, but it also makes programmers stay unskilled and shrinks the pool of programmers that really know what they are doing. As with all things, it's a tradeoff and there really are reasonable and valid arguments for both sides and, as usual, the key is in striking the proper (hard to even define) balance, but for the most part, we aren't even discussing finding a balance, but instead just charging down the road to complete dependency on the tools to take our ill-formed notions and produce quality code that gets it right. There's a day of reckoning down that road.
|
|
| Tags |
| issue, multiplication, pic |
Related Site Pages
|
||||
| Section | Title | |||
| Worksheet | Analog-to-Digital conversion | |||
| Worksheet | Binary math circuits | |||
| Textbook | Conversion from decimal numeration : Numeration Systems | |||
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| help using a logic gate to do multiplication and division | denisdaniel | The Projects Forum | 2 | 04-04-2012 09:18 PM |
| Treadmill motor / voltage, controller board issue | animateme | The Projects Forum | 1 | 06-03-2011 04:48 PM |
| Virtual ground issue | Shashi_PMTC | The Projects Forum | 8 | 03-03-2011 04:53 AM |
| Usb issue | aliashar86 | General Electronics Chat | 2 | 02-09-2010 03:06 PM |
| boolean algebra - multiplication and division | arwin | Homework Help | 5 | 02-03-2008 10:30 AM |
| Thread Tools | |
| Display Modes | |
|
|