Arduino board for electrical training

Brian Owner Ohio Posted   Latest  

Hello every one, Is any one using arduino for demonstration proposes like cam can crank signals or intermittent drop outs? I am prepping for a basic scope class and this is what I have so far. I have made a sketch of 06 impala 3.5 liter I think I have this pretty close to normal cranking, Let me know what you think. If anyone thinks that sharing sketches is a good idea send me what you have or are using. I am just copying the sketch as this file type is not supported. O(diag​.​net/file/f2o5fzadg…diag​.​net/file/f2kfdaqrm…

diag​.​net/file/f1d6sgn2o…

//Brian …

// 06_impala_3.5_cam_crank_good;

void setup() {

pinMode(LED_BUILTIN, OUTPUT);

pinMode(12, OUTPUT);

void loop() {

digitalWrite(LED_BUILTIN, LOW);

delay(50);

digitalWrite(LED_BUILTIN, HIGH);//1

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//2

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//3

digitalWrite(12, HIGH);

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//4

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//5

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//6

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//7

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//8

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//9

digitalWrite(12, LOW);

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//10

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//11

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//12

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//13

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//14

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//15

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//16

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//17

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//18

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//19

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(05);

digitalWrite(12, LOW);

delay(05);

digitalWrite(LED_BUILTIN, HIGH);//20

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//21

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//22

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//23

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//24

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//25

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//26

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//27

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//28

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//29

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//30

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//31

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//32

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//33

digitalWrite(12, HIGH);

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//34

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//35

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//36

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//37

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//38

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//39

digitalWrite(12, LOW);

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//40

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//41

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//42

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//43

digitalWrite(12, HIGH);

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//44

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//45

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//46

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//47

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//48

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//49

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//50

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//51

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//52

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//53

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//54

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//55

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//56

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//57

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//58

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(50);

digitalWrite(LED_BUILTIN, HIGH);//1

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//2

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//3

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//4

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//5

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//6

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//7

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//8

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//9

digitalWrite(12,LOW);

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//10

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//11

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN,HIGH);//12

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//13

digitalWrite(12,HIGH);

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//14

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//15

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//16

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//17

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//18

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//19

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(05);

delay(05);

digitalWrite(LED_BUILTIN, HIGH);//20

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//21

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//22

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//23

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//24

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//25

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//26

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//27

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//28

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//29

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//30

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//31

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//32

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//33

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//34

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//35

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//36

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//37

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//38

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//39

digitalWrite(12,LOW);

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//40

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//41

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//42

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//43

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//44

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//45

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//46

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//47

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//48

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//49

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//50

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//51

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//52

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//53

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//54

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//55

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//56

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//57

delay(10);

digitalWrite(LED_BUILTIN, LOW);

delay(10);

digitalWrite(LED_BUILTIN, HIGH);//58

delay(10);

0
Dr. Engineer
Washington
Dr. Default
 

Brian: I like the idea of using the Arduino for stuff like this........and for catching intermittents. We teach many of these things and more in our Electronics and Software Boot Camps. Your code may work better if you use the Millis Function instead of the "delay" Function. The Delay Function stops the code while the Millis Function will permit the code to run without delay. Using the Millis…

+1
Default Ð Awarded
Brian Owner
Ohio
Brian Default
 

Huge help! Thanks Dr. Mark I was having to write the high and lows @ the same time, and on my "bugged / out of time" version it was a a huge hassle to shift all the events and split the delay 's to make the timing off. I am going to try the Millis Function this evening. I am working to get this board to run off a 12v battery and be able to fire injector and coils, using hall effect cam and…

0
Default Ð Awarded
Chad Owner/Technician
Colorado
Chad Default
 

It’s been a few years since I’ve written any scripts but it would be nice if you had it set up on a multiplier that was adjustable with a potentiometer to simulate engine speed changes. Just to show how timebase may need to be changed to suit the operating conditions.

0
Default Ð Awarded
Brian Owner
Ohio
Brian Default
 

Changes in engine speeds would be great.. I am still on baby steps getting going, but that will be great when I figure it out.

0
Default Ð Awarded
Dr. Engineer
Washington
Dr. Default
 

Brian: Before you connect the Arduino to the vehicle (or any other) 12V system, make sure you place a reverse polarity diode on the input (use a 1 or 2 amp Schottky). Also, place an 18V Zener diode on the positive input lead of the Arduino to clip any transients. Once last thing.......place a 1 - 5mF capacitor on the positive input line to smooth the power input. This should help protect and…

0
Default Ð Awarded
Brian Owner
Ohio
Brian Default
 

Thanks for all the input, currently I am learning the millis function, trying to figure out how to get the 58 pulses for 360 / 116 for 720, Its a little more complex than I thought it would be. I would be interested in a class in the future, I have to teach some classes to make some $$ first LOL.

0
Default Ð Awarded
Tom Technician
Iowa
Tom Default
 

forum​.​arduino​.​cc/index​.​php?topi…

0
Default Ð Awarded
Pam Owner/Technician
Florida
Pam Default
 

Looking good; your students will thank you for your efforts! I’ve been using Ardurino boards - teaching hands-on, electrical - in my classes for the past, four years. Always get the “ah-ha moment” from the techs, when they accomplished the assigned task. � Should be a law against “death by PowerPoint.“ (Bueller...Bueller....) I feel there is no, bigger disservice to a tech - that takes time…

+1
Default Ð Awarded
Tony Inspector
California
Tony Default
 

Suggestion: could have used a pwm pin and incremental loop and/or pot to eliminate all that typing to generate the signal and got it down to about a quarter of the lines. Ill try and post something over the weekend.

0
Default Ð Awarded
Robert Engineer
North Carolina
Robert Default
 

Hello Brian, Do a google, or Alibaba search for ECU simulator. You will find some very amazing teaching tools. Most have all the sensor/actuator outputs you could ever want, and the more advanced ones have arbitrary waveform generator functions where you can easily define any waveform you like. These things used to cost as much as a really nice car but not anymore. I did so much early on with…

0
Default Ð Awarded
Brian Owner
Ohio
Brian Default
 

I will look into this! I have a cheap Hanteck 2 channel scope that can generate many waves, all <2V amplitude. I guess when I was searching for automotive wave form generator I did no find much, Alibaba ECU simulator : :diag​.​net/file/f1qboh7xs… Thanks for the help.

0
Default Ð Awarded
Dmitriy Analyst
Ontario
Dmitriy Default
 

Brian, maybe this advice is obvious, but here it goes: if you are planning to use this for hands-on training, you will have to make it "solid". What I mean is all those wires and breadboard connections are going to disconnect/[intermittently fail] in the middle of presentation, making you chase completely different issues than what you wanted to show! Something like this will make your life…

0
Default Ð Awarded
Brian Owner
Ohio
Brian Default
   

Hi Dmitriy, I am still in early stages of this project, class that I intend on using is on the 24th . I am planning on a rigid / robust set up , solder a 328 chip holder to a board etc. . I am going to experiment with how long of wires I can have going to individual tables ( 3 students to table) and multiple scopes hooked up before the signal goes south. Goal is to have everyone have access to…

0
Default Ð Awarded
Dmitriy Analyst
Ontario
Dmitriy Default
 

Students with direct access to the signal from Arduino Uno? Recipe for trouble! May be it's just me, but I would be adding optoisolator circuits to Arduino/Atmega328 pins. Have you looked at using 3.5mm Male-to-Male Stereo Audio Cable + PCB-mounted jacks to pass signal 4-8 feet at a time?

0
Default Ð Awarded
Bob Educator
California
Bob Default
 

For the less accomplished among us, Snap on builds a similar device. snapon​.​com/display/3871/Z…​.​pdf They have a scanner demo module also. Snap on seems to be heading down another path though. (Finally here: "The computer you just plug in, and it tells you everything.") They seem less interested in trying to teach tool operators how to interpret data. That's just…

0
Default Ð Awarded
Brian Owner
Ohio
Brian Default
 

I was looking at a couple of simulators a bit high in price IMO( heart of it is a atmega 328) , so I was taking matters into my own hands. If nothing else I am learning from the experience. I am hoping to be able to write the basic cam crank patterns for a handful of vehicles, so that the students get to see 1st hand the differences on the tool that they are using. If I can not get the techs to…

0
Default Ð Awarded
Saul Owner
Texas
Saul Default
   

Brian if you are looking for a waveform generator bought one which comes with a software and everytime you need a particular waveform you load them to the device. Software comes with more than 500 waveforms, It could do up to 3 signals, CMP1, CMP2 and CKP. If that's what you looking for I will find the link and send it to you once I get to the office. Let me know.

0
Default Ð Awarded
Brian Owner
Ohio
Brian Default
 

Yes Saul , I would like a look at what you are talking about. In the meantime I am really having a good time building some demo boards, making them look professional, and maintaining portability is a challenge.

0
Default Ð Awarded