Click here to Skip to main content
15,796,456 members
Home / Discussions / Hardware & Devices
   

Hardware & Devices

 
PinnedHOW TO ANSWER A QUESTION Pin
Chris Maunder16-Jul-09 4:09
cofounderChris Maunder16-Jul-09 4:09 
PinnedHow to get an answer to your question Pin
Chris Maunder16-Jul-09 4:05
cofounderChris Maunder16-Jul-09 4:05 
QuestionCan't write to my NTFS-formatted external hard drive on Mac, what should I do? Pin
seekco30-Oct-23 22:55
seekco30-Oct-23 22:55 
AnswerRe: Can't write to my NTFS-formatted external hard drive on Mac, what should I do? Pin
jschell20-Nov-23 8:37
jschell20-Nov-23 8:37 
AnswerRe: Can't write to my NTFS-formatted external hard drive on Mac, what should I do? Pin
k505420-Nov-23 11:28
mvek505420-Nov-23 11:28 
QuestionMemory Pin
Calin Negru21-Oct-23 4:31
Calin Negru21-Oct-23 4:31 
AnswerRe: Memory Pin
trønderen21-Oct-23 6:16
trønderen21-Oct-23 6:16 
AnswerRe: Memory Pin
Dave Kreskowiak21-Oct-23 6:27
mveDave Kreskowiak21-Oct-23 6:27 
GeneralRe: Memory Pin
Calin Negru21-Oct-23 6:54
Calin Negru21-Oct-23 6:54 
QuestionCpu pins Pin
Calin Negru7-Oct-23 3:49
Calin Negru7-Oct-23 3:49 
AnswerRe: Cpu pins Pin
Richard MacCutchan7-Oct-23 4:30
mveRichard MacCutchan7-Oct-23 4:30 
GeneralRe: Cpu pins Pin
Calin Negru7-Oct-23 5:26
Calin Negru7-Oct-23 5:26 
AnswerRe: Cpu pins Pin
Dave Kreskowiak7-Oct-23 5:11
mveDave Kreskowiak7-Oct-23 5:11 
GeneralRe: Cpu pins Pin
Calin Negru7-Oct-23 5:24
Calin Negru7-Oct-23 5:24 
GeneralFirst question solved and with your permission I came up with another one Pin
Calin Negru7-Oct-23 9:05
Calin Negru7-Oct-23 9:05 
GeneralRe: First question solved and with your permission I came up with another one Pin
Dave Kreskowiak7-Oct-23 10:15
mveDave Kreskowiak7-Oct-23 10:15 
GeneralRe: First question solved and with your permission I came up with another one Pin
Calin Negru7-Oct-23 22:23
Calin Negru7-Oct-23 22:23 
AnswerRe: Cpu pins Pin
trønderen7-Oct-23 14:20
trønderen7-Oct-23 14:20 
GeneralRe: Cpu pins Pin
Calin Negru7-Oct-23 22:16
Calin Negru7-Oct-23 22:16 
QuestionZero insertion force (zif) connector esthetes, listen up! Pin
RedDk7-Sep-23 7:50
RedDk7-Sep-23 7:50 
QuestionArduino not looping??? Pin
glennPattonWork321-Jun-23 5:14
professionalglennPattonWork321-Jun-23 5:14 
Hi All,

Using an Arduino to drive a servo motor (well trying).
C++
#include <Servo.h>

Servo myServo;
int servoPin = 2;
uint16_t i = 0;

void setup() {
  // put your setup code here, to run once:
 myServo.attach(servoPin);
 pinMode(LED_BUILTIN, OUTPUT);
}

void loop() {
  // put your main code here, to run repeatedly:
  HERE:
  i = 0;
   for(i = 1; i <= 180; i++)
   {
    myServo.write(i);
    delay(15);
  }
 for(i = 180; i >= 1; i--)
  {
    myServo.write(i);
     delay(15);
  }
goto HERE;
}
Now what I believe Should happen is digital Pin 2 which is being used as the servo pin goes high and the due to the loop the pulse is 'stretched' from 1 to 180 which is taken by Servo and magiced it into a value and sent via pin 2, once this is done the value get counted down from 180 back to 1 by the second loop.
What happens is by scoping the pin the pulse is one get to 180 counts back and does not loop.
This started as a 'Hmmm' problem and has slowly been upgraded. I have put the loops in separate functions to see if that helps, no. Google has been a no and I can't log on to Arduino board as my Pass word was rejected ands the sent pass word link doesn't. Going fully bananas here.

Glenn

PANIC OVER THE CODE NOW WORKS!
AnswerRe: Arduino not looping??? Pin
pkfox21-Jun-23 6:26
professionalpkfox21-Jun-23 6:26 
GeneralRe: Arduino not looping??? Pin
glennPattonWork321-Jun-23 7:13
professionalglennPattonWork321-Jun-23 7:13 
AnswerRe: Arduino not looping??? Pin
jschell21-Jun-23 7:01
jschell21-Jun-23 7:01 
GeneralRe: Arduino not looping??? Pin
glennPattonWork321-Jun-23 7:16
professionalglennPattonWork321-Jun-23 7:16 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.