JCS-900 DRO with Arduino and LCD

  Рет қаралды 9,616

Curious Scientist

Curious Scientist

Күн бұрын

Пікірлер: 17
@fredgenius
@fredgenius 4 жыл бұрын
Couple of things - if you use INPUT_PULLUP instead of INPUT in your pinMode lines, you don't need to set HIGH in another place. And if you trigger interrupts on both inputs, you can get double the resolution - although takes a bit more coding to do this. I use an encoder library to do this for me. Lastly, you could use a board with a faster cpu clock to overcome the speed problem, the Wemos D1 mini is very cheap, and you can program them using the Arduino IDE. Most of your code would be identical.
@CuriousScientist
@CuriousScientist 4 жыл бұрын
These are great inputs, thank you! I have never heard about this board, I will look it up. I guess you know about the 'blue pill' (STM32F103) boards. They are running at 72 MHz, so they are also much faster than an Arduino, and they are a bit cheaper than the Wemos. I will test these boards later, but I have other tasks to finish first.
@fredgenius
@fredgenius 4 жыл бұрын
@@CuriousScientist You are welcome, and thanks for a good video. The Wemos D1 Mini is based on the ESP8266 chip, has 80MHz clock I think. An alternative would be a board based on the ESP32, also fairly low priced, I think they run at 160MHz, and have dual cores.
@7LegSpiders
@7LegSpiders 8 ай бұрын
I just ordered an eps32 to read two glass scales. I'll let you know soon how that works out.
@fredgenius
@fredgenius 8 ай бұрын
@@7LegSpiders I hope you have success! There are many ESP32 boards on the market now, for example the ESP32-C3 boards, which are very low priced, and very small physical size. The only downside to an ESP32 board is that their GPIO pins are 3.3V, not 5V as with the 'AVR' boards (Uno and Nano). This is easily fixed though, and might not need fixing at all if the read head can work at 3.3V. I don't have a scale to hand to test this right now, but I think it is quite likely. Worst case, a level shifting board would cost very little.
@arva1kes
@arva1kes Жыл бұрын
This is really old, but since I'm starting to work on this too then I just put it in here: - serial printing is slow and will block you whole code. So if you don't need it( usin lcd only) then disable it. If you need it use high speeds (115200 or creater) so arduino won't wait on the code to be sent on this slow link. It will make whole code faster. - it's not necessary to print out every change on lcd since you can't see it anyways. printing to lcd take cpu time. it should be printed with fixed intervals in addition to if change is detected. AFAIK lcd.clear() is slow. It would be better to pad the number to full 5 or 6 digits all the time so that you write 00256 instead of just 256 if you don't fill whole area (or " 256" if you prefer). This also make reprinting of text unnecessary making whole lcd code atleast 2-3x faster. - It seems you are missing pulldown resistor on input and this makes signal to drop really slowly making miss steps on higher speeds. - This digital oscilloscope is not too much more powerful than arduino - it will start missing signal very soon if speeds go high.
@CuriousScientist
@CuriousScientist Жыл бұрын
Hi! I know all these things you mentioned, especially 3 years after publishing this video I learned a lot more. The code is built for demonstration, so I needed the serial printing because otherwise, I could not show that the data comes through the serial port. I both agree and disagree with your second comment. You might want to print every change because if you use this in a milling machine, you may want to see those few microns instantaneously. That's why I update the code when there is a change and not when a certain time interval is elapsed. The lcd.clear is slow, yes, I could have used better practice. Nowadays, I print the permanent characters on the display in the setup() part of the code and then when I update the display, I print whitespaces over the old values and print the new ones. I believe an oscilloscope is much faster than an Arduino when it comes to processing signals.
@Hossein_Ash
@Hossein_Ash 2 жыл бұрын
Thank you, very helpful.
@CuriousScientist
@CuriousScientist 2 жыл бұрын
You are welcome!
@adamspontarelli6418
@adamspontarelli6418 4 жыл бұрын
thank you!
@CuriousScientist
@CuriousScientist 4 жыл бұрын
Hi Adam! I am glad that this video was useful for you! Please check back frequently, because I will release a lot of interesting videos in the coming weeks.
@3goldfinger
@3goldfinger 10 ай бұрын
If you reverse pi 2 and 4, will anything happen, I can't seems to find the right info on it.
@CuriousScientist
@CuriousScientist 10 ай бұрын
As long as you mix data pins, nothing wrong can happen. You just don't get any results. Be sure not to mix power pins.
@3goldfinger
@3goldfinger 10 ай бұрын
Thanks a lot, that was quick.
@CuriousScientist
@CuriousScientist 10 ай бұрын
You're welcome! The notifications are enabled on my phone. 😉
@luizcarlosarrudajunior3402
@luizcarlosarrudajunior3402 4 жыл бұрын
Arduino is no fast enought for fast movements
@CuriousScientist
@CuriousScientist 4 жыл бұрын
I am using it for speeds such as 10 mm/min. It is perfect for that. For large speeds you want a dedicated hardware or an absolute encoder. :)
Digital read out (DRO) using an Arduino and a digital caliper
24:29
Curious Scientist
Рет қаралды 21 М.
300 mm DRO with Arduino (ATTiny85 and Nano)
32:39
Curious Scientist
Рет қаралды 8 М.
Colorful Pasta Painting for Fun Times! 🍝 🎨
00:29
La La Learn
Рет қаралды 308 МЛН
Yay, My Dad Is a Vending Machine! 🛍️😆 #funny #prank #comedy
00:17
DRO Project: Signal Analysis
10:39
m0xya
Рет қаралды 1,8 М.
Cutting DRO glass scales is easier than you think.
11:25
Mike's Workshop Adventures
Рет қаралды 6 М.
LCD repair
12:43
ShortcutElectronics
Рет қаралды 357 М.
I run untested, viewer-submitted code on my 500-LED christmas tree.
45:17
DRO 4 wiring the Digital Read Out and uploading sketches.
9:05
Practice Makes Better
Рет қаралды 2,1 М.
Digital Readout DRO with digital caliper gauge (german)
24:48
Using Rotary Encoders with Arduino
32:10
DroneBot Workshop
Рет қаралды 716 М.
Digital Calipers DRO
9:20
nerdkits
Рет қаралды 86 М.