philipellisis / arduino-virtual-pinball-board

This is some simple code to make a virtual pinball compatible board that works off of the Arduino firmware
15 stars 8 forks source link

Wiring Arduino micro #11

Open lamarqueb opened 3 months ago

lamarqueb commented 3 months ago

Good morning

congratulations for your work. I'm looking to make a PCB with your system. I'm not sure I understand where everything connects

for the output and accelerometer extension I put them on SDA and SCL in series as in the first diagram. for the three 74HC165 I'm not sure where or for the plunger can you let me know

can you tell me where I plug my hard input into the arduino

Best regards

274564465-ffee137a-5e32-429d-85fc-629557c13baf Sans titre-1 Sans titre-2

samwyze commented 3 months ago

I'm not entirely sure, but from looking through the code...

On the 74hc165 I believe it should go: hc165 Pin 1(Shiftload) to Arduino D4 hc165 Pin 2(Clock) to Arduino D1(TX) hc165 Pin 9(QH) to Arduino D0(RX). Also, possibly hc165 Pin 15(Clock Inhibit) should go to GND and all the netport pins should have 10k resistors going to VCC as pullups and switch to GND

The plunger potentiometer wiper is on Arduino A5, I don't think you need to wire VCC to the plunger pot as its using the arduino input_pullup command, so just the wiper and GND.

lamarqueb commented 3 months ago

like that. Sans titre-1

samwyze commented 3 months ago

Like this: output Also, Vcc(16) and GND(8) of each 74hc165 should have a 0.1uF ceramic capacitor as per datasheet And possibly pin 15 (clock inhibit) can be tied to pin 2 (clock), although I'm not 100% on that.

lamarqueb commented 3 months ago

Sans titre-1

lamarqueb commented 3 months ago

i need only arduino micro or Pro micro it's ok ? but now the pin are different. https://fr.aliexpress.com/item/1005003643595104.html?spm=a2g0o.order_list.order_list_main.41.6a945e5b47gpSv&gatewayAdapt=glo2fra

samwyze commented 3 months ago

You want the Arduino Micro. Not the pro, it doesn't break out all the pins you want

lamarqueb commented 3 months ago

yes I saw that afterwards. for example the A5 is not there for the plunger.

lamarqueb commented 2 months ago

Sans titre-3

with pin header for MPU-6050 and lot of place for 4 output (shacker, knocker, led start and led launch) directly on main board with LVT 817 and NCE 6050

next step with MPU6050 and arduino micro on the board Sans titre-4

philipellisis commented 2 months ago

Very nice!

samwyze commented 2 months ago

Well done, looks awesome. Much tidier than my stripboard version 😂

lamarqueb commented 2 months ago

Very nice!

thank you I hope the routing is good for the arduino micro pins. I don't know much about programming. but I hope it will work without too much modification or even any of the code.

matgenois commented 2 months ago

Tres beau board et bonne chance pour la suite!

lamarqueb commented 2 months ago

Very nice!

hi ! please you can tell me the good pinout for 74HC165 to arduino PCA 9685 to arduino (SCL SDA ?) MPU6050 to arduino (SCL, SDA ?)

i use D0, D1 and D4 for 74HC165 i use D2 and D3 for SCL SDA to PCA 9685and MPU6050 in serial

Best regards

Benoit

lamarqueb commented 2 months ago

Hello everyone

I received my cards and everything works perfectly 24 buttons, 16 outputs, plunger and accelerometer. I have a little problem, all the outputs are on when they are inactive and off when they are active. Can't we reverse that? I have cards that work with LVT817 octocoupler and therefore it is not compatible. 20240424_160819

matgenois commented 2 months ago

Is these outputs are outputs id 1 to 15 (so output that are directly from the arduino) ? or 16 to 32 (output from the pca9685) ?

matgenois commented 2 months ago

Pinone have those output 1-15 are output directly from the Arduino. Those are Off by default; 16-31 are output from the first PCA9685 and are for the "button boards" so output are on by default so buttons are Lighted; 32-59 are driven by two more PCA9685 and are off by default.

lamarqueb commented 2 months ago

surely we can make 16 to 32 directly off by default? what are the pins for outputs 1 to 16?

matgenois commented 2 months ago

I used outputs 1 to 15 to drive my shaker motor and solenoid. output 1-5 are analogs

You can by modifying output.cpp

    // if the output is the button board output, then invert the value
    if (outputId < 31) {
      outputValue = 255 - outputValue;
    }
lamarqueb commented 2 months ago

when I update the firmware with the software I return to my active outputs. If I don't update I can't save. it's simpler if I go through the outputs 0-15 you will have the pins

matgenois commented 2 months ago

Sorry I can't tell you which pins... that's not my expertise

lamarqueb commented 2 months ago

I found the 15 pins outputs directly on the arduino, it's simpler for me.

matgenois commented 2 months ago

You could write the output pins here for the next one trying to design his own board :)

lamarqueb commented 2 months ago

i'll share my schéma when all is finish and ok 21 board 1.0 with 15 outputs (5 five on board and 10 on pins) accelerometer on separate card, purchased on aliexpress, (-2€) if I put it on the main card (7€). everything works perfectly on the tests let's get started...

lamarqueb commented 1 month ago

here is the 100% functional card. I added 5 outputs directly on the card with LTV817 and irf6050 for controlling the toys. 10 outputs on terminal block or JTAG connector. I will complete with the complete diagram for those who want

magic pincab