Difference between revisions of "Programming"

From The TinkerNet Wiki
Jump to navigation Jump to search
(Created page with " ==Atom as a full IDE== *[https://discuss.atom.io/t/can-i-turn-atom-to-a-full-c-ide/51736/6 Can I turn Atom into a full C++ IDE (forum thread)] *[https://atom.io/packages/gpp...")
 
Line 20: Line 20:
  
 
*[https://www.allaboutcircuits.com/technical-articles/learn-embedded-c-programming-language-understanding-union-data-object/?utm_source=All+About+Circuits+Members&utm_campaign=00717a1d5f-EMAIL_CAMPAIGN_2019_05_22_02_31_COPY_01&utm_medium=email&utm_term=0_2565529c4b-00717a1d5f-266664249/ Learn the Embedded C Programming Language: Understanding the Union Data Object]
 
*[https://www.allaboutcircuits.com/technical-articles/learn-embedded-c-programming-language-understanding-union-data-object/?utm_source=All+About+Circuits+Members&utm_campaign=00717a1d5f-EMAIL_CAMPAIGN_2019_05_22_02_31_COPY_01&utm_medium=email&utm_term=0_2565529c4b-00717a1d5f-266664249/ Learn the Embedded C Programming Language: Understanding the Union Data Object]
 +
*[https://www.tutorialspoint.com/c_standard_library/c_function_printf.htm printf()]
 +
*
  
 
==C++==
 
==C++==
Line 26: Line 28:
  
 
*[http://www.cplusplus.com/reference/cstdlib/itoa/ itoa - C++ Reference]
 
*[http://www.cplusplus.com/reference/cstdlib/itoa/ itoa - C++ Reference]
 +
 +
=== Problem Solving ===
 +
 +
* <code>Error] cannot pass objects of non-trivially-copyable type 'std::string {aka class std::basic_string<char>}' through '…'</code>
 +
** [https://stackoverflow.com/questions/23450300/error-cannot-pass-objects-of-non-trivially-copyable-type-stdstring-aka-clas/23450339 Discussion & Solution]
  
 
==Processing==
 
==Processing==
Line 53: Line 60:
 
[https://playground.arduino.cc/Main/PROGMEM PROGMEM]
 
[https://playground.arduino.cc/Main/PROGMEM PROGMEM]
  
== Troubleshooting ==
+
==Troubleshooting==
 
When trying to compile things on a Linux machine...
 
When trying to compile things on a Linux machine...
  
 
You get silly-ass errors like '''fatal error: stdio.h: No such file or directory''' or other files missing that just don't make ANY sense...
 
You get silly-ass errors like '''fatal error: stdio.h: No such file or directory''' or other files missing that just don't make ANY sense...
  
* <code>sudo apt update</code>
+
*<code>sudo apt update</code>
* <code>sudo apt install --reinstall build-essential</code>
+
*<code>sudo apt install --reinstall build-essential</code>
  
 
'Coz sumpin' borked yer compiler install...
 
'Coz sumpin' borked yer compiler install...

Revision as of 18:28, 26 January 2021

Atom as a full IDE

bash

Dialogs

C

C++

(Apparently, a language designed to make C programmers lose their minds...)

Converting numbers to strings

Problem Solving

  • Error] cannot pass objects of non-trivially-copyable type 'std::string {aka class std::basic_string<char>}' through '…'

Processing

JavaScript

Arduino (Language)

Data Type Conversions

char* to String

char *message = "Hello";
String myString = String(message);

String to char*

Messing about with strings & not Strings

http://www.cplusplus.com/reference/cstring/

Specifically: strcat

Memory Saving

PROGMEM

Troubleshooting

When trying to compile things on a Linux machine...

You get silly-ass errors like fatal error: stdio.h: No such file or directory or other files missing that just don't make ANY sense...

  • sudo apt update
  • sudo apt install --reinstall build-essential

'Coz sumpin' borked yer compiler install...