Controlling buttons on side of tiny video player

mick · 13 · 17491

mick

  • Jr. Member
  • **
    • Posts: 7
    • View Profile
Newbie at this, wondering if there is a way to add external buttons to the buttons on the sides of the video player. Where I'm putting it won't be accessible to those buttons, but I would like to be able to use other buttons connected by wires to access those controls - is it possible to add additional switches to the screen?


mick

  • Jr. Member
  • **
    • Posts: 7
    • View Profile
I should clarify, I also do not want to control it with a remote.


lennevia

  • Administrator
  • Hero Member
  • *****
    • Posts: 437
    • View Profile
Hi there,

Yes, it's possible. The best way to accomplish your goal is to solder buttons separately to a proto TinyShield and then change the pins in the software. I helped someone do this over email previously so I'll copy over the helpful parts: - including some text on the two classic types of buttons:

A momentary button can work :
-   Normally off: With the normally-off switch, there's no connection till you push the button. Most push button switches are used this way. Examples include doorbell buttons, cell phone keys and garage door openers.
-   Normally on: Here the switch conducts normally, but interrupts the circuit when you press on it. This is more specialized, and may be used in conjunction with a wiring trick. For example, connecting a normally-on switch in parallel with a light bulb will light the bulb when the button's pushed; otherwise, current will flow through the switch, leaving the bulb off.

For the typical type of button, normally off, or a push-to-make, button, it should work to connect one lead to GND and the other to a digital pin. VCC could be used, but it makes more sense to use GND in my mind since there are 4 breakout pins to GND on the proto board for an easier time soldering.

Here is how I wrote the code attached to work for TinyTV remote button functionality - you might have to adapt this idea to the Tiny Video Player functionality:
#define powerBtn 2
#define muteBtn 4
#define volUpBtn 6
#define volDownBtn 7
#define chanUpBtn 9
#define chanDownBtn A2

I tried to pick pins that wouldn't be too crowded together, but let me know if you're having issues with the pin placements. You should be able to just change the pin value at the top of the code, lines 80-85.

If you're not sure how to upload the code, you can follow the directions found here:
https://learn.tinycircuits.com/Processors/TinyScreen%2B_Setup_Tutorial/ - Just make sure to open the main Arduino code file from inside the attached folder so that you can see all of the tabs of the different files when you open it in the Arduino IDE. If you get lost here, just let me know!

I recommend guiding your soldering based on the colored pinout image on the photo reel: https://tinycircuits.com/collections/proto-boards/products/proto-board-tinyshield
I was testing with pin 2 and from the silkscreen I kept thinking pin 2 was on the edge of the board, but it's 1 row in – and I work here! Very humbling experience. Don't make my same mistakes!

Code is attached [@ future users: you can only see forum message attachments if you're logged in]

Cheers,
Réna


mick

  • Jr. Member
  • **
    • Posts: 7
    • View Profile
Thanks! that is awesome. But I have additional questions. So, I have the tiny video kit, and it comes with the TV board, and the then another board where the battery plugs in. That board connects to the tv board but it does not have another one of those stackable containers - so if I wanted to add a protoboard to this, I assume I would have to get one that has connectors on each side, and then put the protoboard in the middle? which seems would be a little awkward for the soldered wires but I guess would be doable? Is the right way to do it?


mick

  • Jr. Member
  • **
    • Posts: 7
    • View Profile
Also, sorry for the dumb questions - on the protoboard should I be soldering wires directly to board, or should I be using some sort of header pins or something for those?


lennevia

  • Administrator
  • Hero Member
  • *****
    • Posts: 437
    • View Profile
Not dumb questions at all! Ask as many questions (or for details/recommendations) as you like so you can feel comfortable working on your project.

For the proto board: yes, you would solder wires directly to where you want to make connections. If you are worried about spacing, I would suggest buying two proto TinyShields with the connectors on both sides so that the wired connections can fit between two proto boards since there isn't much space for extra wires right up against the TinyScreen+ or SD Audio TinyShield

To keep connection steady, I might also suggest a mounting kit that comes with spacers: https://tinycircuits.com/collections/accessories-add-ons/products/tinyduino-mounting-kit



mick

  • Jr. Member
  • **
    • Posts: 7
    • View Profile
Awesome, I think I understand - one protoboard into the the tv board then another that has the connections into that protoboard - i saw that there are wired connectors too, so I suppose if room for the board is not an issue I could use the wire connector from the tv to the protoboard and the mount the sd board right below that...anyway, I think I get it now.


lennevia

  • Administrator
  • Hero Member
  • *****
    • Posts: 437
    • View Profile
That's great! Would love to see the final build once you're ready to share!


mick

  • Jr. Member
  • **
    • Posts: 7
    • View Profile
I'm only in the prototype stage for the project, but I have a working proof of concept build of it now, although it doesn't have the entire scene, just the tv right now, but it's working great - modeled it in zbrush, and then printed it on a resin printer and then did some quick paint tests...I'll send an update once the real build is done, but here is a link to a video of the prototype:

https://twitter.com/mickstorm/status/1604959516843397120


lennevia

  • Administrator
  • Hero Member
  • *****
    • Posts: 437
    • View Profile

mick

  • Jr. Member
  • **
    • Posts: 7
    • View Profile
Thanks! Here's a shot of the work in progress on what I'm really making


lennevia

  • Administrator
  • Hero Member
  • *****
    • Posts: 437
    • View Profile

spaspeckerthedull

  • Newbie
  • *
    • Posts: 2
    • View Profile
hi guys - new member here not wanting to hijack this post, but I have the same question as the OP for a different project if that's ok?

i'm UK based and about to pull the trigger on a tinyscreen+ kit and proto board from mouser, it seems to be the THE perfect setup for my needs but I need to make sure first before committing to spending the money

my project needs a small screen video player - tinyscreen+ kit, check!
I need to move the control buttons away from the side of the screen - proto board, check!

i've read and re-read the instructions on the tinycircuits store page dozens of times concerning changing the settings screen etc. Unfortunatley my 53 year old brain just can't get round the coding necessary to acheive what I want, I last wrote code 40 years ago on a TI99-4A and things were very different back then

basically, I want to be able to have a screen on the display with custom text that lists my converted videos, then press a push-to-make button to trigger the playback of the corresponding video? or am I asking too much? something like this:

1:VIDEO 1      2:VIDEO 2
3:VIDEO3       4:VIDEO 4

i've installed arduino IDE and downloaded the screen menu code and the scrolling display code, and viewed them in the arduino software. I simply cannot make head nor tail of it unfortunately - I don't need the "military time" or the other titles displayed and I won't be using the tiny remote?

hope i'm not asking too much - thanks in advance


 

SMF spam blocked by CleanTalk