Tips for project involving power electronics/control theory

Ok, so thanks to the current virus outbreak, my university has cancelled all my physical classes for the
next 2 weeks. So I looked up online to see what Arduino project I can build to teach myself more about power electronics and control systems which so happens to be the units I am taking this semester.
I have two Arduino Unos, a starter kit, a 33-in-1 sensor kit, a camera module and a 9DOF gyro-accelerometer. I want to be able to build it in a week or so. Any tips?

Power and control, make a Arduino based inverter, that will produce power from a battery source when the mains drop out.

This is the home work they forgot to give out:

Arduino links of interest.


How to use this forum:
https://forum.arduino.cc/index.php?topic=149014.0


Listing of downloadable 'Arduino PDFs' :
Either Google >>>- - - - > arduino filetype: pdf
Or
https://www.google.ca/search?q=arduino+filetype%3A+pdf&rlz=1C9BKJA_enCA739CA739&oq=arduino+filetype%3A+pdf&aqs=chrome..69i57j69i65.1385j0j7&hl=en-US&sourceid=chrome-mobile&ie=UTF-8


Listing of downloadable 'C++ PDFs' :
Either Google >>>- - - - > C++ filetype: pdf
Or
https://www.google.ca/search?q=c%2B%2B+filetype%3A+pdf&rlz=1C9BKJA_enCA739CA739&oq=c%2B%2B+filetype%3A+pdf&aqs=chrome..69i57.22790j0j7&hl=en-US&sourceid=chrome-mobile&ie=UTF-8


Arduino cheat sheet:


Watch these:
Arduino programming syntax:

Arduino arithmetic operators:

Arduino control flow:

Arduino data types:

Jeremy Blume:

Sparkfun External Interrupts

Sparkfun Timer1 Interrupts

Powering You Projects


Understanding Destructive LC Voltage Spikes:

OR

Why MOSFET gate resistors:


Some things to read

LCD information:

OR

Reading a schematic:
https://learn.sparkfun.com/tutorials/how-to-read-a-schematic

Language Reference:
https://www.arduino.cc/en/Reference/HomePage

Foundations:


How and Why to avoid delay():
http://playground.arduino.cc/Code/AvoidDelay

Demonstration code for several things at the same time.
http://forum.arduino.cc/index.php?topic=223286.0


Multitasking:
Part 1:

Part 2:

Part 3:


Neopixels, Adafruit

Fastled


Sparkfun Tutorials:
https://learn.sparkfun.com/tutorials?page=all

Micro Controllers:

Useful links:

Arduino programming traps, tips and style guide:
http://www.gammon.com.au/forum/?id=12153

Call for useful programming discussions

Arduino products:
https://www.arduino.cc/en/Main/Products

Motors/MOSFETs
http://www.gammon.com.au/motors

Switches:
http://www.gammon.com.au/forum/?id=11955

A good book you might want to get:


Share tips you have come across, 500+ posts:


Debug discussion:

Frequently Asked Questions:
https://www.arduino.cc/en/main/FAQ#toc10


Number 'type's:

  • boolean (8 bit) - simple logical true/false, Arduino does not use single bits for bool
  • byte (8 bit) - unsigned number from 0-255
  • char (8 bit) - signed number from -128 to 127. The compiler will attempt to interpret this data type as a character in some circumstances, which may yield unexpected results
  • unsigned char (8 bit) - same as 'byte'; if this is what you're after, you should use 'byte' instead, for reasons of clarity
  • word (16 bit) - unsigned number from 0-65535
  • unsigned int (16 bit)- the same as 'word'. Use 'word' instead for clarity and brevity
  • int (16 bit) - signed number from -32768 to 32767. This is most commonly what you see used for general purpose variables in Arduino example code provided with the IDE
  • unsigned long (32 bit) - unsigned number from 0-4,294,967,295. The most common usage of this is to store the result of the millis() function, which returns the number of milliseconds the current code has been running
  • long (32 bit) - signed number from -2,147,483,648 to 2,147,483,647
  • float (32 bit) - signed number from -3.4028235E38 to 3.4028235E38. Floating point on the Arduino is not native; the compiler has to jump through hoops to make it work. If you can avoid it, you should.

You should always select the 'data type' best suited for your variables.
ex:

  • your variable does not change and it defines a pin on the Arduino. const byte limitSwitchPin = 34;
  • since an analog variable can be 0 to 1023, a byte will not do, you can select 'int'. ex: int temperature;
  • if your variable needs to be within -64 to +64 a 'char' will do nicely. ex: char joystick;
  • if your variable is used for ASCII then you need type 'char', ex: char myText = {"Raspberry Pie Smells"};
  • if your variable enables some code then boolean can be used. ex: boolean enableFlag = false;
  • millis() returns the time in ms since rebooting, ex: unsigned long currentTime = millis();
    etc.

Oh, and have fun too :slight_smile: !