Questions tagged [object-oriented]
The object-oriented tag has no summary.
13 questions
0
votes
1
answer
342
views
Accessing funcition in object via `->` is crashing (resetting) Arduino
I have several classes that call each other running on an Arduino Mega. I am using the ArduinoSTL library to get the std library, most notably the std::vector.
The core problem is as follows: my ...
1
vote
2
answers
362
views
Detecting different objects closeness
iam currently working on a new project, where i would like to detect the existence/closeness of several objects around the arduino up to like 1 meter. I was thinking about an rfid setup, but as the ...
1
vote
1
answer
2k
views
request for member 'attribute' in 'object', which is of non-class type 'int'
I am trying to create a basic snake game using the arduino UNO along with the MAX72XX module, the LCD module and the analog joystick module. I am wanting to program my program using object orientated ...
2
votes
1
answer
4k
views
Does Arduino C++ support dynamic arrays of objects
My C++ is seriously out-of-date, and I'm working on a project that will be juggling multiple timed actions at the same time, with a menu system to manage the interface and control those timed actions (...
1
vote
1
answer
150
views
Problems with passing objects in tree structure [closed]
I'm new to C++ and arduino. I want to build an object Tree, but it did not behave like I expected. Here is the code:
TreeNode.h
class TreeNode {
public:
TreeNode(String inputNodeName);
...
3
votes
1
answer
2k
views
How do string pointers work in Arduino?
To the best of my understanding, when I declare
String s = "This is a string.";
what happens is that space is allocated on the stack for a pointer which points to some String object which internally ...
2
votes
1
answer
1k
views
Creating public instance of class in another class's initialization
I'm using several TM1637 displays to create timers, so I decided to make a Timer class. Every time I initialize an instance of the Timer class, I want it to create an instance of the TM1637Display ...