I am an Atmel fanboy, and have been programming them since the AT90S1200 in both asm & C.
My point being, I just don't get the Arduino syntax gobbly-gook.
I can't understand what's going on in the background.
What say, for example what pin 13 is tied to in a sketch <- "I hate that word"
Is it PD7 or really pin 13 on the IC?
Another thing is getting for example to display whats in the serial monitor on a port.
Any help to answer my inquiries or point me to any other site besides Arduino. I'm old and don't have a lot of patience to wade through all the stuff scattered on hundreds of large font pages.
Signed: Dazed in the hot southern sun ..... Thanks
Yeah as others have said you really do need to read about the specific board you've bought, if you're using Arduino, as you will be using their Arduino libraries and board description files which map e.g. PA1 to whatever physical pin.
I never did anything with actual genuine Arduino - I started off with an Adafruit Feather M0 (via Arduino IDE) from the get go, which I feel was a positive step as it put me straight into ARM territory and lots of multiplexed I/O peripherals (shitloads of SPI, UART or I2C whereever you want it..)
Crucially, Adafruit do good docs generally. Although as time goes on I'm starting to think they're too focused on flashy lights for kids.
On STM32, it all makes sense because PA1 means GPIO Port A, Pin 1, and GPIOH3 means GPIOH, Pin 3. Once you start trying to do just the simple Arduino things in stm32 (HAL_GPIO_WritePin - after setting the pin type - but you can learn all this from the example code that CubeMX generates), and then you use your proper IDE (PlatformIO with VSCode was my favourite when doing Arduino, but now I'm learning stm32 with HAL and CubeMX, I am using TrueStudio), you can dig into what's actually happening, and then you can see it all tying into the datasheet.
e.g.:
#define SPI_CR2_FRXTH_Pos (12U)
#define SPI_CR2_FRXTH_Msk (0x1U << SPI_CR2_FRXTH_Pos) /*!< 0x00001000 */
#define SPI_CR2_FRXTH SPI_CR2_FRXTH_Msk /*!< FIFO reception Threshold */
once you dig in (right-click, open declaration), the code starts to make sense to the actual chip level datasheet:
http://www.internetsomething.com/stm32/stm32-f767-programming-manual.pdf (page 1358 - it's bit 12!. It takes a bit of a while to get it (especially if you're trying to debug that big clock gap which you will see in a few more posts.. and appears to be caused by the rx buffer /counter seeing 16 bits and then going to an rx-retrieve sub-procedure (even though you'd like it to ignore the first 8 bits) - but doesn't happen if you use DMA). The more you can think in term of bits, registers, and then bit-shifting, the the more it starts to half make sense...)
I really hated the Windows 10 calculator and went out of my way to install a classic calculator up until recently. But - 3 years on, it no longer takes 10 seconds to open (yes, horsepower, vs efficiency), *and* it's great for doing hex -> binary (and vice versa) calculations for those of us that don't just have it in mind naturally.