Тёмный

16-key keypad with an Arduino and a PCF8574 I/O expander module 

Curious Scientist
Подписаться 34 тыс.
Просмотров 14 тыс.
50% 1

Опубликовано:

 

10 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 47   
@TVV-04
@TVV-04 2 года назад
A quite in-depth look at these incredibly useful chips! You could chop down on the lines by using a for loop as an example containing 4 if statements with some multiplication to figure out what each button will be depending on the first 4 bytes sent. Would be less code, but I do understand that it would not be as readable for demonstration purposes. These chips are plenty of fun indeed 😄 Thanks for the videos!
@CuriousScientist
@CuriousScientist 2 года назад
Thank you! Yes, there could have been more done in terms of code optimization. I agree that this chip is a very cool chip; it helped me in many projects where I needed a large number of I/O ports. Cheers!
@m.zubair387
@m.zubair387 2 года назад
i have a customized row column keypad, which I am running with 4094 and 4052, its working but i was looking for help about denounce and hold key, your video and code will help me. Good content
@CuriousScientist
@CuriousScientist 2 года назад
I am glad to hear that my content was helpful!
@m.zubair387
@m.zubair387 2 года назад
Beautifully explained everything, ♥️
@CuriousScientist
@CuriousScientist 2 года назад
I try my best to explain everything in details.
@chrisgilbert7573
@chrisgilbert7573 3 года назад
Hi! I really enjoy your channel, extremely interesting and thorough. It would be super interesting to see a ESP32 Bluetooth version of this. I would imagine it could be used for your camera slider and the coil winder. Again, great work!
@CuriousScientist
@CuriousScientist 3 года назад
Hi and thank you! I used ESP32 for other projects that I have not published here, but generally, it is the same code as for Arduino as long as it does not require wifi or bluetooth. I try to avoid ESP32 for now because I do not need the wireless function and I still have a lot to learn in the world of Arduino and STM32.
@micultimy91
@micultimy91 3 года назад
hey. just discovered your channel and I am truly impressed! 👍🏻 I've seen that you've made some videos with AS5600 encoder module. Have you thought about using AS5600 as MPG for a control panel? I'm currently trying to build something that uses AS5600 as a MPG, but it's going to take a while because my programming skills are not that advanced. Keep the good work going! Good luck 👍🏻👍🏻👍🏻
@CuriousScientist
@CuriousScientist 3 года назад
Thanks! I don't see the use of the AS5600 as an MPG since there is already a specific hardware for pulse generation. It is much easier to set up an MPG (like I did in some of my videos).
@Dekan88
@Dekan88 Год назад
Hi, I just tested this code and I'm getting an error " no matching function for call to 'LiquidCrystal_I2C::begin()" Can't find anyone's code that will work with the PCF8574.
@CuriousScientist
@CuriousScientist Год назад
You need the correct library.
@irgski
@irgski Год назад
How do you prevent key "ghosting" - where, if more than one key is pressed it may or may not cause an incorrect key press.?
@CuriousScientist
@CuriousScientist Год назад
I don't. I trust the user. 😃
@brianxavier8873
@brianxavier8873 3 года назад
good job. but why did you go back to arduino and not stick to stm32 bluepill?
@CuriousScientist
@CuriousScientist 3 года назад
Hi and thanks! I did not have a free STM32 available and I did not want to disassemble other projects.
@objection_your_honor
@objection_your_honor Год назад
Can I send a sequence of keyboard keys with on button press? EX: send "Left Shift + Right CTRL + F12" with one key press.
@CuriousScientist
@CuriousScientist Год назад
Hi! Sure, but not with a regular Arduino like the Nano or the Uno. You'll need something with native USB support. Arduinos with the Atmega32U4 chip are suitable for the task. Leonardo, Micro, Pro Micro could work for your task.
@objection_your_honor
@objection_your_honor Год назад
@@CuriousScientist Got it thanks. I just bought 2 pro micro from AliSlow. 👍
@CuriousScientist
@CuriousScientist Год назад
@@objection_your_honor Super, you're welcome! While the boards are on their way to you, read this article on Arduino's website: www.arduino.cc/reference/en/language/functions/usb/keyboard/ Alternatively, just Google "Arduino keystroke". There are many great tutorials out there.
@objection_your_honor
@objection_your_honor Год назад
@@CuriousScientist Will do. Thanks.
@edwintok2466
@edwintok2466 Год назад
Hello! Relatively new to Arduino so i was wondering if the configuration & code is compatible with Arduino Uno on tinkercad? Want to try familiarizing with tinkercad before beginning.
@CuriousScientist
@CuriousScientist Год назад
Hi! Sorry, I have never worked with tinkercad, so I cannot answer this question. Try it, I guess, it is just a software, nothing can go wrong.
@edwintok2466
@edwintok2466 Год назад
@@CuriousScientist No worries! Appreciate your prompt reply, however can i ask if this is compatible for Arduino Uno R3 as well, are there anything i should look out for to change in the code
@CuriousScientist
@CuriousScientist Год назад
Sure, Uno and Nano (board in the video) use the same chip. I think no changes would be necessary.
@edwintok2466
@edwintok2466 Год назад
@@CuriousScientist Tried it out and worked out really well! Thank you so much for the guidance and video. In addition can i ask if theres any guides if i want to further expand the ports by connecting another port expander?
@CuriousScientist
@CuriousScientist Год назад
Sure, look up PCF8574 in my videos. I have a video where I use it to grab the key presses on a keypad. I also used it in other projects.
@Dekan88
@Dekan88 Год назад
Hay, in your code, you foegot lcd.init(); and lcd.backligjt(); the lcd did not light up. The keys do not work in the right order. Can you fix your code?
@CuriousScientist
@CuriousScientist Год назад
I did not forget anything, you can see that the code works... You are not using the same LCD library as I do.
@Dekan88
@Dekan88 Год назад
So, what is this library you're using? How can I download it?
@CuriousScientist
@CuriousScientist Год назад
You can download it from the library manager.
@Dekan88
@Dekan88 Год назад
I did try that, and it did not find the library. I'll try again tomorrow.
@CuriousScientist
@CuriousScientist Год назад
@@Dekan88 Good luck!
@u_arif
@u_arif 2 года назад
hey, did you try the keypad i2c library? would that not have been much easier and simpler? great vid btw
@CuriousScientist
@CuriousScientist 2 года назад
Hi! If I simply use the libraries, I never learn how these things works. I am aware of the different libraries, but I want to avoid them where it is possible.
@u_arif
@u_arif 2 года назад
Respect bro
@CuriousScientist
@CuriousScientist 2 года назад
Thank you!
@rodrigobautistagutierrez5366
@rodrigobautistagutierrez5366 3 года назад
How does it handle debounce?
@CuriousScientist
@CuriousScientist 3 года назад
I explained it in the video. Please watch it more carefully.
@tuyenvo1038
@tuyenvo1038 2 года назад
Hi. My name is Vo Tan Tuyen, I come from Vietnam. Your project is very cool because it can apply to many projects. and my project also needs this part but I am not very familiar with Arduino can you show me how to print(entire string) to output an integer (without the ".00" character). My English is not good, there are mistakes, please forgive me. Thank you very much.
@CuriousScientist
@CuriousScientist 2 года назад
Hi! The easiest way is to store the number as an integer (int). Or if you want to print a float without the decimals, you just have to tell the print function. For example, serial.print(variable name, 0) will not print any decimals. Arduino has a really nice documentation, you should read it.
@rodrigobautistagutierrez5366
@rodrigobautistagutierrez5366 3 года назад
It does not handle debouncing at all. Desperse.
@CuriousScientist
@CuriousScientist 3 года назад
It does... You are just not watching the video carefully. First of all, you can see it in the demo that there are no bouncing. Second, the part that you seemingly cannot understand is that after the code detects any keystroke, it does not allow any other keystrokes to be detected for 300 ms. This makes sure that any bouncing decays and just a single button press is registered.
Далее
Уроки Arduino. Работа с энкодером
10:55
Bike vs Super Bike Fast Challenge
00:30
Просмотров 21 млн
iPhone 16 для НИЩЕБРОДОВ!
00:51
Просмотров 610 тыс.
Using EEPROM with Arduino - Internal & External
31:54
Просмотров 195 тыс.
Interface ESP32 with the PCF8575 I/O Port Expander
16:58
I built my own computer. by hand.
13:03
Просмотров 1,2 млн
How to connect the keypad to Arduino
9:08
Просмотров 10 тыс.
Electromagnetic Aircraft Launcher
15:09
Просмотров 1,2 млн
PCF8574 GPIO Extender - With Arduino and NodeMCU
11:30