Skip to main content

Questions tagged [pointer]

A variable in C/C++ which stores the type and location of data in memory.

Filter by
Sorted by
Tagged with
0 votes
2 answers

Pass a member function pointer to a method of a foreign class (EDB Lib)

I'm currently working on my own arduino library and I'm becoming exasperated with the following problem: I want to store data with the extended database library (
Andreas Müller's user avatar
3 votes
1 answer

ArduinoJSON v6 - Passing buffer as function parameter

I'm new to ArduinoJSON - so perhaps it is a newbie's question.... but I wish to pass a StaticJsonDocument into a function as a parameter ( later on it should be implemented in a library ). exmaple ...
guyd's user avatar
  • 1,049
12 votes
4 answers

Why is it considered bad practice to use the 'new' keyword in Arduino?

I previously asked this question: Is it required to delete variables before going to sleep? On that question, @Delta_G posted this comment: ... Really on a microcontroller I would create the object ...
Tono Nam's user avatar
  • 938
2 votes
2 answers

Problem with wrapping Adafruit Motor Controller function calls in a class

I'm working on an Arduino robot and I ran into a problem when reorganizing my code. I have an Adafruit Motor Shield v2.3 connected to an Arduino Uno. My robot can be controlled using a bluetooth ...
hubbabubba's user avatar
2 votes
3 answers

Storing an array of function pointers

I have some Arduino code that looks like: char packet =; switch(packet){ case 'a': someobj.somefunc(); break; case 'b': otherobj.otherfunc(); ...
Cerin's user avatar
  • 1,648
1 vote
1 answer

Casting a struct member between uint8_t and char, with regard to serial transfer

Im simply trying to pass my payload to another device that has the same architecture and struct. I'm using UART to transfer, and modeling the protocol from EasyTransfer. When I call Serial.print((char*...
Womble's user avatar
  • 189
0 votes
1 answer

Assigning an empty array row to reference [duplicate]

int colors[][3] = { { 255, 0, 0 }, { 0, 255, 0 }, { 0, 0, 255 }, { 253, 7, 210 } }; int (*EXCLUSIVE_COLOR)[3]; I have a two-dimensional array to store some color values. I have a 2nd ...
VerySeriousSoftwareEndeavours's user avatar