Re: [PIC] Learning C

RussellMc <[email protected]>
Newsgroups gmane.comp.hardware.microcontrollers.pic
Message-ID <CACZQxzMTXsopEEr=nTR5SH9mJ0W8raS4x0dfXAB7K-pYebwffA@mail.gmail.com>
On Tue, 12 Nov 2024 at 02:12, David C Brown <[email protected]> wrote:

> I must stress that I want to learn C as a desktop language before
> converting to PIC use..
> Recommendations for a good book would be appreciated
>
>
At the risk of being cast into outer darkness (weeping, wailing,
gnashing of teeth, ...)
I'll have another try at mentioning Arduinos.

Here is a PIC implementation

https://www.instructables.com/Pinguino-Project-a-PIC-Microcontroller-Based-Ardui/

And here is a page that mentions several , but they me be somewhat more
arcane

        https://forum.arduino.cc/t/arduino-and-pic/868085

BUT Arduino using AVRs is an exceedingly useful extra string to a
multistring bow.
The complete hardware, software, IDE ... (& even the power supply) for your
first attempt will cost you under GBP10.
Possibly under GBP5.
They are exceedingly easy to try and MAy lure you to the dark side.

You don't even have to load the "flash a LED" / hello world equivalent
code. Tey tend to have LED flash preloaded.
Powering? - connect via USB cable to a PC (Windows / Linux / Mac)
Software - download the latest IDE from here
https://www.arduino.cc/en/software
Examples?  There are many dozens of include examples, starting with flas a
LED, read a button.
Plus ADC, DAC (PWM on many, true DAC on some), Serial, USB, SPI, ... .
Typical sensors interfacing. More

In many cases you can use a p[remade "sketch" and tweak it as required.
A competent programmer can usually follow the code well enough without
extra input, and detailed tutorials are available.

The system is not, of course, perfect and gets somewhat arcane and messy as
you start to do more complex things, but millions of people have walked the
same path and there is much advice easily avaialable.

Something like youe=r data logger, if maybe not quite trivial, would be
extremely easy once you'd understood the basic system.

This is an add on to other abilities and systems, but not one that should
be lightly ignored. (I claim :-) ).


     Russell
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.