What Arduinos do yo...
 
Notifications
Clear all

What Arduino models do you use in your experiments? Poll is created on Dec 25, 2019

  
  
  
  
  
  

What Arduinos do you use?  

Page 2 / 2
  RSS

VE1DX
(@ve1dx)
Estimable Member
Joined: 1 year ago
Posts: 134
2020-02-13 5:54 pm  
Posted by: @robo-pi

If you're really good at it you can just go right down the line without skipping over every other pin.  I've done that too.  If things are working smoothly it should go really fast.  If you get to a pin that doesn't seem to want to heat up.  Just clean the tip.  Touch some fresh solder onto the tip, and go at it again.  I typically clean the tip and touch it with fresh solder every 3 or 4 pins.   That seems to work the best for me.   The tip will tend to accumulate old solder and you don't want that.  So clean the tip often you should be just fine.

IMG 4257
IMG 4258

You are a genius with your tips, James! I never soldered anything that small. I didn't try it with the STM32 series or to get the FTDI adapter going yet. I need to convince myself I could follow your instructions, and they were clear. I got it the first time with an Elegoo NANO clone. It's running Blink fine, so I am pretty sure I have it down. Now on to the "blue" and "black" pills.

You said you'd been doing this for years, and your instructions show it. The 4-corners first and "every second pin" were particularly useful. As you said, that guarantees alignment and minimizes overheating.

While this site is mostly Arduino, Pi and Robotics oriented, most members have excellent expertise in the basics of one area or the other. Some day you might have a question I can answer as well as you did mine! Thanks so much.

Paul VE1DX


ReplyQuote
VE1DX
(@ve1dx)
Estimable Member
Joined: 1 year ago
Posts: 134
2020-02-13 6:13 pm  
IMG 4260

And more thasn just Blink . . . drop in replacement, as it should be!

 

Paul VE1DX


ReplyQuote
Robo Pi
(@robo-pi)
Robotics Engineer Moderator
Joined: 1 year ago
Posts: 1774
2020-02-13 6:44 pm  

I'm glad to hear my suggestions were helpful.   Without realizing it, you have actually inspired me to finally make a wooden stand for my soldering station.  This is something I've been wanting to do, and after our conversation I decided to go out in the wood shop and just build it.  So here it is:

Station (4)

It holds the main unit, and the soldering stand is also firmly attached to the base.   And I also fastened the tip cleaner on top so it is nice and sturdy too.  And lastly I made a dowel rod to hold the solder.   Now instead of having to grab a lot of separate pieces (or look for where they went), I can just grab the entire station in one fell swoop.  It's nice. ? 

Posted by: @ve1dx

Some day you might have a question I can answer as well as you did mine!

I have lots of questions so you'll have lots of opportunities.   You wouldn't happen to know how to calculate the decision boundary for a perceptron from the neural network weights would you?   I've been reading articles on how to do this, but I'm not having much success when it comes down to actually calculating the parameters for drawing the lines.

DroneBot Workshop Robotics Engineer
James


ReplyQuote
VE1DX
(@ve1dx)
Estimable Member
Joined: 1 year ago
Posts: 134
2020-02-13 7:45 pm  
Posted by: @robo-pi

You wouldn't happen to know how to calculate the decision boundary for a perceptron from the neural network weights would you? 

I think one has to understand the question to answer it!  Seriously, I passed this on to my son who does somewhat complex modelling of the ocean and atmosphere, but he's run off his feet and likely won't respond.  However, hope springs eternal! ?  It may be something he's encountered.

Paul VE1DX


ReplyQuote
VE1DX
(@ve1dx)
Estimable Member
Joined: 1 year ago
Posts: 134
2020-02-13 7:58 pm  
Posted by: @robo-pi

You wouldn't happen to know how to calculate the decision boundary for a perceptron from the neural network weights would you?   I've been reading articles on how to do this, but I'm not having much success when it comes down to actually calculating the parameters for drawing the lines.

He did respond, but I don't know if it's of any help. "Use a reticulated discriminator to identify the perception limit and then you have to choose a value of alpha (usually 0.5 is used here) and that gives you the result. There's probably more than one way to do it but that is the classic approach. I guess you have to hit the academic papers to sort out how that all works. t's an active area of research so I don't know if this has been distilled down to textbook techniques yet."

https://medium.com/@thomascountz/calculate-the-decision-boundary-of-a-single-perceptron-visualizing-linear-separability-c4d77099ef38

Paul VE1DX


ReplyQuote
VE1DX
(@ve1dx)
Estimable Member
Joined: 1 year ago
Posts: 134
2020-02-13 8:13 pm  
Posted by: @robo-pi

Without realizing it, you have actually inspired me to finally make a wooden stand for my soldering station.  This is something I've been wanting to do, and after our conversation I decided to go out in the wood shop and just build it.

The stand for the soldering station looks great.  Much of my stuff is spread all over the place, falling on the floor and usually missing to the point I need to look for an hour to find it.  Then I ask my wife, and she says, "That thing laying there?" while pointing at whatever I can't find.  I guess there are none so blind as those who cannot see.  I really should create something like you did.

Paul VE1DX


ReplyQuote
Robo Pi
(@robo-pi)
Robotics Engineer Moderator
Joined: 1 year ago
Posts: 1774
2020-02-13 8:31 pm  
Posted by: @ve1dx

The stand for the soldering station looks great.   I really should create something like you did.

It was well worth it.  Something I should have done the day it arrived!   It didn't take that long to build and it's much easier to use this way as well as being more easily portable.   It was well worth the hour or so it took to build it.

Posted by: @ve1dx

He did respond, but I don't know if it's of any help.

I actually already read the article you linked to.    In fact, that is one of the more succinct articles on how to do it.   Unfortunately it isn't working for me.   Although this could be a problem elsewhere in my code.  I have code that calculates both the weights and the decision boundary.    I confess that I've been quite confused on it as it seemed to work in some cases but not in others.   It could be other parts of my program that are causing the problems.   I actually haven't worked on that specific program in a while because I was getting to frustrated with the failures.   Maybe if I go back and look at it now things will click better.

DroneBot Workshop Robotics Engineer
James


ReplyQuote
VE1DX
(@ve1dx)
Estimable Member
Joined: 1 year ago
Posts: 134
2020-02-14 5:21 pm  
Posted by: @zeferby

Remember to include the STM into the Arduino IDE Preferences/Additional Boards Manager URLs :

Posted by: @robo-pi

Just be aware that some pins and signals may be on different pins.  Have a pinout chart handy

Thanks, fellows! You both saved me a ton of headaches. I have an STM32F103C8T6 working well. I'm using USB interface to program it right now, but the FTDI module does look better and simple to get going. I want to benchmark the new system with a few sketches first. You guys know your stuff.  ? 


ZeFerby liked
ReplyQuote
Robo Pi
(@robo-pi)
Robotics Engineer Moderator
Joined: 1 year ago
Posts: 1774
2020-02-14 9:07 pm  

@ve1dx

Just another tip on how to preserve soldering tips,....

When you are all done soldering and you're going to put the soldering station away for a while.  Load the soldering tip up with some molten solder before turning it off.   That layer of solder on the tip will actually protect the tip from corroding in the air.   If you actually clean the tip  off of all solder before turning it off, that will leave the tip exposed to air while the soldering station is just sitting around.  The surface of the tip will oxidize in the air. Then the next time you get the soldering iron out it may not perform as well as it did when new.   So load it up with molten solder before shutting down the iron.  This way when you get it out the next time only the surface of that old solder will be oxidized, but the tip underneath will remain as pristine as new.

This will make your tips last a lot longer.

DroneBot Workshop Robotics Engineer
James


ReplyQuote
VE1DX
(@ve1dx)
Estimable Member
Joined: 1 year ago
Posts: 134
2020-02-15 5:22 pm  

@zeferby and @robo-pi

This with the "blue pill" and an old computer speaker.

Paul VE1DX


ZeFerby liked
ReplyQuote
Robo Pi
(@robo-pi)
Robotics Engineer Moderator
Joined: 1 year ago
Posts: 1774
2020-02-15 6:11 pm  

@ve1dx

Now you're a blue pill expert. ? ? ? 

I'll soon be picking your brain for tips and tricks on how to program an STM32.

DroneBot Workshop Robotics Engineer
James


ReplyQuote
VE1DX
(@ve1dx)
Estimable Member
Joined: 1 year ago
Posts: 134
2020-02-15 7:17 pm  
Posted by: @robo-pi

Now you're a blue pill expert. ? ? ? 

I'll soon be picking your brain for tips and tricks on how to program an STM32.

Fat chance of that! I'm still a beginner. The sketch for that is something I got from the Internet and modified to run on regular Arduino Uno. It did load and played on the SM32 first go, so it proves they are very close to compatible, and a heck of a lot faster. I'll post the sketch, although I can't take credit for it other than a few minor tweaks. What you and @zeferby did was give me the confidence to solder the little pins and how to set up the IDE to software on them. Now to move on to something more complex. Thanks again to both of you.

/* 
Ode to Joy - Beethoven's Symphony No. 9
*/

#define NOTE_B0 31
#define NOTE_C1 33
#define NOTE_CS1 35
#define NOTE_D1 37
#define NOTE_DS1 39
#define NOTE_E1 41
#define NOTE_F1 44
#define NOTE_FS1 46
#define NOTE_G1 49
#define NOTE_GS1 52
#define NOTE_A1 55
#define NOTE_AS1 58
#define NOTE_B1 62
#define NOTE_C2 65
#define NOTE_CS2 69
#define NOTE_D2 73
#define NOTE_DS2 78
#define NOTE_E2 82
#define NOTE_F2 87
#define NOTE_FS2 93
#define NOTE_G2 98
#define NOTE_GS2 104
#define NOTE_A2 110
#define NOTE_AS2 117
#define NOTE_B2 123
#define NOTE_C3 131
#define NOTE_CS3 139
#define NOTE_D3 147
#define NOTE_DS3 156
#define NOTE_E3 165
#define NOTE_F3 175
#define NOTE_FS3 185
#define NOTE_G3 196
#define NOTE_GS3 208
#define NOTE_A3 220
#define NOTE_AS3 233
#define NOTE_B3 247
#define NOTE_C4 262
#define NOTE_CS4 277
#define NOTE_D4 294
#define NOTE_DS4 311
#define NOTE_E4 330
#define NOTE_F4 349
#define NOTE_FS4 370
#define NOTE_G4 392
#define NOTE_GS4 415
#define NOTE_A4 440
#define NOTE_AS4 466
#define NOTE_B4 494
#define NOTE_C5 523
#define NOTE_CS5 554
#define NOTE_D5 587
#define NOTE_DS5 622
#define NOTE_E5 659
#define NOTE_F5 698
#define NOTE_FS5 740
#define NOTE_G5 784
#define NOTE_GS5 831
#define NOTE_A5 880
#define NOTE_AS5 932
#define NOTE_B5 988
#define NOTE_C6 1047
#define NOTE_CS6 1109
#define NOTE_D6 1175
#define NOTE_DS6 1245
#define NOTE_E6 1319
#define NOTE_F6 1397
#define NOTE_FS6 1480
#define NOTE_G6 1568
#define NOTE_GS6 1661
#define NOTE_A6 1760
#define NOTE_AS6 1865
#define NOTE_B6 1976
#define NOTE_C7 2093
#define NOTE_CS7 2217
#define NOTE_D7 2349
#define NOTE_DS7 2489
#define NOTE_E7 2637
#define NOTE_F7 2794
#define NOTE_FS7 2960
#define NOTE_G7 3136
#define NOTE_GS7 3322
#define NOTE_A7 3520
#define NOTE_AS7 3729
#define NOTE_B7 3951
#define NOTE_C8 4186
#define NOTE_CS8 4435
#define NOTE_D8 4699
#define NOTE_DS8 4978
#define REST 0

// change this to make the song slower or faster
// int tempo=114;
int tempo=130;
// change this to whichever pin you want to use
int buzzer = 0;

// notes of the moledy followed by the duration.
// a 4 means a quarter note, 8 an eighteenth , 16 sixteenth, so on
// !!negative numbers are used to represent dotted notes,
// so -4 means a dotted quarter note, that is, a quarter plus an eighteenth!!
int melody[] = {


NOTE_E4,4, NOTE_E4,4, NOTE_F4,4, NOTE_G4,4,//1
NOTE_G4,4, NOTE_F4,4, NOTE_E4,4, NOTE_D4,4,
NOTE_C4,4, NOTE_C4,4, NOTE_D4,4, NOTE_E4,4,
NOTE_E4,-4, NOTE_D4,8, NOTE_D4,2,

NOTE_E4,4, NOTE_E4,4, NOTE_F4,4, NOTE_G4,4,//4
NOTE_G4,4, NOTE_F4,4, NOTE_E4,4, NOTE_D4,4,
NOTE_C4,4, NOTE_C4,4, NOTE_D4,4, NOTE_E4,4,
NOTE_D4,-4, NOTE_C4,8, NOTE_C4,2,

NOTE_D4,4, NOTE_D4,4, NOTE_E4,4, NOTE_C4,4,//8
NOTE_D4,4, NOTE_E4,8, NOTE_F4,8, NOTE_E4,4, NOTE_C4,4,
NOTE_D4,4, NOTE_E4,8, NOTE_F4,8, NOTE_E4,4, NOTE_D4,4,
NOTE_C4,4, NOTE_D4,4, NOTE_G3,2,

NOTE_E4,4, NOTE_E4,4, NOTE_F4,4, NOTE_G4,4,//12
NOTE_G4,4, NOTE_F4,4, NOTE_E4,4, NOTE_D4,4,
NOTE_C4,4, NOTE_C4,4, NOTE_D4,4, NOTE_E4,4,
NOTE_D4,-4, NOTE_C4,8, NOTE_C4,2

};

// sizeof gives the number of bytes, each int value is composed of two bytes (16 bits)
// there are two values per note (pitch and duration), so for each note there are four bytes
int notes=sizeof(melody)/sizeof(melody[0])/2;

// this calculates the duration of a whole note in ms (60s/tempo)*4 beats
int wholenote = (60000 * 4) / tempo;

int divider = 0, noteDuration = 0;

void setup() {
// iterate over the notes of the melody.
// Remember, the array is twice the number of notes (notes + durations)
for (int thisNote = 0; thisNote < notes * 2; thisNote = thisNote + 2) {
// calculates the duration of each note
divider = melody[thisNote + 1];
if (divider > 0) {
// regular note, just proceed
noteDuration = (wholenote) / divider;
} else if (divider < 0) {
// dotted notes are represented with negative durations!!
noteDuration = (wholenote) / abs(divider);
noteDuration *= 1.5; // increases the duration in half for dotted notes
}

// we only play the note for 90% of the duration, leaving 10% as a pause

tone(buzzer, melody[thisNote], noteDuration*0.9);

// Wait for the specified duration before playing the next note.

delay(noteDuration);

// stop the waveform generation before the next note.

noTone(buzzer);

}

}

void loop() {
// if you want to repeat the song forever,
// just paste the setup code here instead.

/* for (int thisNote = 0; thisNote < notes * 2; thisNote = thisNote + 2) {

// calculates the duration of each note
divider = melody[thisNote + 1];
if (divider > 0) {
// regular note, just proceed
noteDuration = (wholenote) / divider;
} else if (divider < 0) {
// dotted notes are represented with negative durations!!
noteDuration = (wholenote) / abs(divider);
noteDuration *= 1.5; // increases the duration in half for dotted notes
}

// we only play the note for 90% of the duration, leaving 10% as a pause
tone(buzzer, melody[thisNote], noteDuration*0.9);

// Wait for the specief duration before playing the next note.
delay(noteDuration);

// stop the waveform generation before the next note.
noTone(buzzer);
*/ }

ReplyQuote
Page 2 / 2