#help-with-arduino

1 messages · Page 63 of 1

north stream
#

The first one (#define) replaces every instance of "NORTH" in the source file with "3". The second one defines a two byte integer with the value of 3.

tacit plaza
#

So they should function the same doing it either way?

cedar mountain
#

There are some subtle differences. For instance, &NORTH exists when it's a variable, but not when it's just a #define constant.

proud torrent
#

Does anyone have experience w/ the raw RFM 95 chip? Without the breakout board?

#

I wired a pair up to my nanos and tried to test a two way comms setup (one receiver and one transmitter). Transmitter works but it doesn't seem to receive- any thoughts?

wintry berry
#

Is there a limit to how long the wire can be from the arduino to the neopixel? 10 feet is ok? I want to control just 3 neopixels.
11:33
arduino ----->>>>>>3 feet of cable --->>>> neopixels

cedar mountain
#

There is some sort of limit, but 10 feet should be fine.

forest lark
#

however, when I got to the sudo openocd part I get an error:"sudo: openocd: command not found"

#

I dont know if that could cause the issue

cedar mountain
#

Sounds like the final sudo make install step might not have been run?

forest lark
#

I think you are right!

neon trench
#

Hi! I'm not much of a hardware guy, but I've got an Arduino 33 IOT and I'm trying to get it to work with a ring of 16 Neopixels (part 1463). I'm trying to adapt the simple sketch here for the nano R3: https://create.arduino.cc/projecthub/zanycadencedev/getting-started-with-arduino-and-neopixels-013360
I've changed PIN to 3 and # of LEDs to 16. This is my code:
https://gist.github.com/gallaugher/60c364943c22b5f4588ef289523b5276
I have soldered the wires in the neopixel ring yet. I thought I could just poke into the holes for the male-to-male jumper wires - GND, 5V, Digital In, and connect these to the 33 IOT's GND, 5V, and D3. I've got jumpers on the arduino. female to croc clip to wire clipping to see if I can get this simple sketch to work. Upload looks fine, but I'm getting nothing. Any advice on what I'm doing wrong? Should I solder the Neopixel ring GND, 5V, and Data in, then try clipping those to the croc clips? Thanks!

Arduino Project Hub

Arduino and NeoPixel Tutorial appropriate for a beginner. By Elijah Scheele.

Gist

Attempting to neopixel ring an arduino 33_IOT. GitHub Gist: instantly share code, notes, and snippets.

north stream
#

Before soldering it, you may have better luck putting the alligator clips directly onto the pads on the ring.

forest lark
#

Sounds like the final sudo make install step might not have been run?
@cedar mountain I got a little further, but now it doesnt show any errors, but also doesnt display the target and its status.

#

The last thing it shows is Listening on port 4444 for telnet connections

#

Am I going a bit off topic for this section?

neon trench
north stream
#

I wonder if you need a level shifter

neon trench
#

@north stream I'm not sure what that means. Sorry - hw n00b...

north stream
#

I think (but I'm not sure, I don't have one) that the 33_IOT is a 3.3V board, and the neopixels operate on 5V logic: sometimes they'll work with 3.3V data, sometimes they won't.

#

However, there could also be some other problem (wrong type of pin or code set up wrong or something)

neon trench
north stream
#

Depends on how that board works. I'd hope it would be connected to 5V from the USB, but maybe not?

neon trench
#

@north stream since this sketch only lights up one pixel, I switched to the 3.3v pin & it's now nicely flashing in RED, as the sketch would suggest it should. I know the spec says these rings are 5v rings. Is there a risk I might damage the board or the rings if I try to run this off of the 3.3v? And if this is a concern, how would I try to deal with the board apparently needing some change in the power other than what's going into the 5v pin?

north stream
#

It won't damage them, but there may not be enough voltage available to light the green/blue LEDs

#

I'm not sure the best way to deal with the 5V supply

forest lark
#

The last thing it shows is Listening on port 4444 for telnet connections
@forest lark I can communicate with the board on telnet, but when I type at91samd chip-erase it says "chip erase started", but when typing at91samd bootloader it still shows the size of 131072 bytes

#

@stuck coral any ideas?

north stream
#

I'm just guessing here but I'd expect the same number of bytes: the storage is still there, just blank.

stuck coral
#

You have a m4 correct @forest lark ?

#

Sorry, at work

forest lark
#

yes, grand central

#

no problem, I can wait till a better time

forest lark
#

looks like i should use atsame5x.cfg instead of at91samdxx.cfg

#

for the source

forest lark
#

I did the atsame5 bootloader 0 command

#

now when typing atsame5 bootloader it says: "Bootloader protected in the first 0 bytes"

#

reset command gives a handler hardfault

#

it still never completed the chip-erase command

#

Both neopixel and red led are off now

unreal finch
#

can someone help me w programming my robot to walk

#

basically i want it to follow the semi circle then follow the line

#

and then go in a loop but for some reason the legs dont even move

#

also ik that there r stuff i can remove from the code but im j trying to b cautious

north stream
#

Looks like a piecewise approximation of an arc?

fathom ibex
#

What part of the code is sending movement commands to the legs/motors?

unreal finch
#

basically thats an issue as well

#

cuz the servo library doesnt work in arduino pro ide

#

so i decided to make my own pwm

#

and it should be every 1 in the pwm is a degree

#

but its weird cuz it doesnt work for some reason

fathom ibex
#

without further context, it looks like the given code is calculating stuff but never commands the servos to move

north stream
#

The PWM frequency has to be in the range the servos expect, and the pulse width (not the duty cycle) is the important bit, it should be around 1-2ms.

unreal finch
#

1-2ms?

#

the servo can move 255 degrees even tho it claims 270 (sort of got scammed ig)

#

and also for the servo movement i use this equation:

fathom ibex
#

afaik it's typical for you to be able to turn the servo arm further than it can drive itself

unreal finch
#

it calculates the angle from the line

north stream
#

I figured there must be some sort of following step, since your code fragment didn't compute servo positions directly.

unreal finch
#

following step?

#

nono the picture above computes the servo positions from the line

north stream
#

Yes, your xLR and yLR values looked like they needed some math

unreal finch
#

i did that slightly above so it moves along the x axis

#

and follows the curve

#

wait is pwm digitalwrite or analogwrite?(ples tell me its analog)

fathom ibex
#

looks like analog from the docs

unreal finch
#

o thank god

north stream
#

When you said you made your own PWM, I figured you weren't using analogWrite()

unreal finch
#

i j write it into the servo

fathom ibex
#

what arduino is this on? make sure you're using pwm pins

unreal finch
#

its a mega

north stream
#

That isn't going to work, the pulse widths are all wrong

unreal finch
#

yeye ik its not a hardware issue cuz it worked fine when i used the servo library

#

wait what do u mean?

north stream
#

What I said above: the pulse width needs to be in the 1-2ms range.

fathom ibex
#

pulse width or pwm frequency?

north stream
#

PWM frequency is fixed, it should be about 50Hz. Pulse width controls servo angle.

unreal finch
#

wait analogwrite is 0-255 right?

fathom ibex
north stream
#

Yes, analogWrite goes from 0-255, which gives 0 to 100% duty cycle.

#

Doing the math, with a 20ms timeslot, a 1-2ms pulse works out to a 5-10% duty cycle. So you can't use anywhere near the entire 0-255 range.

unreal finch
#

so if my servo goes to 255 degrees how do i move it to 255 degrees?

north stream
#

Set the pulse width to 2ms.

#

(more or less, some servos will want slightly more or less, like 1800µs)

unreal finch
#

wait i dont get it

#

whats the difference between the millisecond thing and a dutycycle

north stream
#

Duty cycle is how much of the time the signal is high. Always low is 0% duty cycle, and always high is 100% duty cycle.

#

If it's on half the time, that's 50% duty cycle. But (as I pointed out above), it isn't duty cycle the servo is paying attention to, it's pulse width.

unreal finch
#

AHhhhh i c

#

wait but how would i write the width?

#

can i j write analog write and then add the ms?

north stream
#

There are two ways: one way is just use the servo library, which does the math for you (and I think it uses a higher precision mode and takes care of setting the clock period correctly).

#

But you can do it with analogWrite() if you configure the frequency properly. Once the frequency is write, your servo range is 1ms (which is a 5% duty cycle, or an analogWrite() value of 13) to 2ms (which is a 10% duty cycle, or an analogWrite() value of 26).

#

So if you're using analogWrite, your servo range is around 13-26.

#

That only gives you 14 positions: not much accuracy, and you also have to write special registers to set the frequency to something the servo can understand. The servo library takes care of this, and gives finer grained control. You can do this too, but not with analogWrite(), which is a little limited for this use.

unreal finch
#

o thx

#

wait do i need to buy the 12 channel servo controller thingy

north stream
#

You could, but why not just use the servo library?

unreal finch
#

wait u can use it without it?

north stream
#

Yes, the servo library lets you use microcontroller pins to control servos, you don't need the separate controller unless you need to run more servos at once.

unreal finch
#

i need to run 12 servos going in different directions at the same tiem would i need one of those or is 12 still ok?

#

o wait nop got it lmoa

north stream
#

The 12 channel board does come in handy for controlling a bunch of servos at once, like I did with this quadruped robot

unreal finch
#

o i should probs get that then

storm harness
#

\effect_minmax.cpp:16:22: error: invalid use of member function (did you forget the '()' ?)

     t = (((maximum - minimum) * t) + maximum + minimum) * 0.5;
#

any ideas how to fix?

lone ferry
#

What are maximum and minimum?

storm harness
#

floats defined in the .h

#

i think they are the problem, i just tried with just 1 instead of them - it worked fine

#

(at least it compiled)

#
#ifndef effect_minmax_h_
#define effect_minmax_h_

#include "Arduino.h"
#include "AudioStream.h"

class AudioEffectMinmax: public AudioStream
{
public:
  AudioEffectMinmax(void) : AudioStream(1, inputQueueArray) {}
  void minimum(float minimum){}
  void maximum(float maximum){}

  virtual void update(void);
private:
  audio_block_t *inputQueueArray[1];
};
#endif
#

^my .h

lone ferry
#

Why are they functions?

storm harness
#

I'm making an object for an audio library

lone ferry
#

Yeah but this void minimum(float minimum){} doesn't make any sense.

#

It's a function named minimum that does not do anything or return any value.

#

Did you mean to write just float minimum; ?

storm harness
#

im using an existing object as reference

#

and it uses functions for variables (idk how)

#
public:
    AudioEffectFade(void)
      : AudioStream(1, inputQueueArray), position(0xFFFFFFFF) {}
    void fadeIn(uint32_t milliseconds) {
        uint32_t samples = (uint32_t)(milliseconds * 441u + 5u) / 10u;
        //Serial.printf("fadeIn, %u samples\n", samples);
        fadeBegin(0xFFFFFFFFu / samples, 1);
    }
    void fadeOut(uint32_t milliseconds) {
        uint32_t samples = (uint32_t)(milliseconds * 441u + 5u) / 10u;
        //Serial.printf("fadeOut, %u samples\n", samples);
        fadeBegin(0xFFFFFFFFu / samples, 0);
    }
    virtual void update(void);
lone ferry
#

It does not 😉

storm harness
#

ahhhh

#

my brain is melting

lone ferry
#

Anyway, if you change those lines to float minimum; and float maximum; then your code will compile.

storm harness
#

they have to be inside a function with float parameter right tho?

#

that way it is accesible from the arduino sketch

lone ferry
#
class AudioEffectMinmax: public AudioStream
{
public:
  AudioEffectMinmax(void) : AudioStream(1, inputQueueArray) {}
  float minimum;
  float maximum;

  virtual void update(void);
private:
  audio_block_t *inputQueueArray[1];
};
#endif
#

Although you probably want to do the following as well: AudioEffectMinmax(void) : AudioStream(1, inputQueueArray), minimum(0.0f), maximum(1.0f) or whatever, so that they have default values.

storm harness
#
  AudioEffectMinmax(void) : AudioStream(1, inputQueueArray) {}
  void minimum(float minimumValue)
  {
    float minimum = float minimumValue;
  }
  void maximum(float maximumValue)
  {
    float maximum = float minimumValue;
  }
#

The functions are called from arduino sketch when you want to change parameters - so this should work right?

lone ferry
#

No, but something like this will:

class AudioEffectMinmax: public AudioStream
{
public:
  AudioEffectMinmax(void) : AudioStream(1, inputQueueArray), _minimum(0.0f), _maximum(1.0f) {}

  void setMinimum(float minimum) { _minimum = minimum; }
  void setMaximum(float maximum) { _maximum = maximum; }
  float minumum() { return _minimum; }
  float maximum() { return _maximum; }

  virtual void update(void);
private:
  audio_block_t *inputQueueArray[1];
  
  float _minimum;
  float _maximum;
};
storm harness
#

ok i think i get it

#

thanks for all the help : )

forest lark
#

Sorry, at work
@stuck coral Now a better time? 😬

stuck coral
#

Yes, it is

forest lark
#
transport select swd

set CHIPNAME samd51g19a
source [find target/atsame5x.cfg]

bcm2835gpio_swd_nums 25 24
bcm2835gpio_trst_num 7
bcm2835gpio_srst_num 18

adapter srst delay 100
adapter srst pulse_width 100

init
targets
reset halt
#atsame5 chip-erase
atsame5 bootloader 0
# program bootloader-grandcentral_m4-v3.10.0.bin verify
flash write_image bootloader-grandcentral_m4-v3.10.0.bin
reset
shutdown```
#

This is my cfg file, it gives no errors, but doesnt seem to load the bootloader. It still says usb device not recognised when plugging the board in

stuck coral
#

Alright, gimmi a moment to check my old cfg file

forest lark
#

when using the program function it gives errors and the computer doesnt even pick up that something has been plugged in

stuck coral
#

What do you mean?

#

Also, I think you need to swap the first line with source [find interface/raspberrypi2-native.cfg]

forest lark
#

program bootloader-grandcentral_m4-v3.10.0.bin verify

#

instead of

#

flash write_image bootloader-grandcentral_m4-v3.10.0.bin

#

raspberrypi2-native.cvg for a PI Zero?

stuck coral
#

Could you copy whats in terminal and use formatting so I know what is output? And yes

#

Origonal Pi has a different pinout then all the other boards

forest lark
#

Sorry, I was using the pi independantly on another screen, now my mouse and keyboard wont work all of the sudden

stuck coral
#

You could use ssh @forest lark

forest lark
#

no power on the PI's usb now 😔

#

will try that now

stuck coral
#

Hm, sounds like youre having a issue, either powring the pi or your wiring to the other board

forest lark
#

ssh connection is being refused

#

I am an endless source of problems

stuck coral
#

You have a hardware issue you need to solve first

#

Hm, sounds like youre having a issue, either powring the pi or your wiring to the other board

forest lark
#

it looks like it boots up fine, I re started it without the board connected too

stuck coral
#

Sounds like you might have not enough amperage going to your pi to me

forest lark
#
Licensed under GNU GPL v2
For bug reports, read
        http://openocd.org/doc/doxygen/bugs.html
Info : BCM2835 GPIO JTAG/SWD bitbang driver
Info : JTAG and SWD modes enabled
Info : clock speed 2002 kHz
Info : SWD DPIDR 0x2ba01477
Info : atsamd51p20a.cpu: hardware has 6 breakpoints, 4 watchpoints
Info : starting gdb server for atsamd51p20a.cpu on 3333
Info : Listening on port 3333 for gdb connections
target halted due to debug-request, current mode: Thread
xPSR: 0x01000000 pc: 0xfffffffe msp: 0xfffffffc
Info : SAM MCU: SAMD51P20A (1024KB Flash, 256KB RAM)
shutdown command invoked
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections```
#

Sorry for the delay, here is what I get with the cfg I posted, but with the change in line 1

#

@stuck coral Can a bad usb cable cause bootloader problems? My cousin used my cable now to program his itsy bitsy and he had to double tap the reset button again...

#

It was also the cable I used when the GC stopped working

stuck coral
#

It can be, but if I remember right didnt I tell you to try another cable and you said you did

forest lark
#

I did, the gc doesnt work on anything

stuck coral
#

Ah, so it caused the issue, yes that can happen

#

Even bad front USB on a desktop can cause it

forest lark
#

Atleast we have a possible cause then

stuck coral
#

Not anymore, but for all M4 boards produced before a certain date

forest lark
#

I did update his bootloaders though

stuck coral
#

Well he could just retap the reset button to upload new code right? The updated bootloader locked itself

forest lark
#

right

stuck coral
#

Yours wasnt and the bad USB caused the transfer to overwrite the bootloader so you cant double tap the reset button

forest lark
#

I see

#
Licensed under GNU GPL v2
For bug reports, read
        http://openocd.org/doc/doxygen/bugs.html
Info : BCM2835 GPIO JTAG/SWD bitbang driver
Info : JTAG and SWD modes enabled
Info : clock speed 2002 kHz
Info : SWD DPIDR 0x2ba01477
Info : atsamd51p20a.cpu: hardware has 6 breakpoints, 4 watchpoints
Info : starting gdb server for atsamd51p20a.cpu on 3333
Info : Listening on port 3333 for gdb connections
target halted due to debug-request, current mode: Thread
xPSR: 0x01000000 pc: 0xfffffffe msp: 0xfffffffc
Info : SAM MCU: SAMD51P20A (1024KB Flash, 256KB RAM)
shutdown command invoked
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections```

@forest lark @stuck coral did you see this?

stuck coral
#

Yes, I dont see an issue with that output, does it still not work?

#

If not we can poke around the processor

forest lark
#

Nope, neopixel is solid red and the "L" led rapidly fades in and out

#

how does one poke around?

#

and where?

#

😋

stuck coral
#

Make a new directory and cd into it, add this new cfg file in it-

source [find interface/raspberrypi-native.cfg]
transport select swd

set CHIPNAME samd51g19a
source [find target/atsame5x.cfg]

bcm2835gpio_swd_nums 25 24
bcm2835gpio_trst_num 7
bcm2835gpio_srst_num 18

adapter srst delay 100
adapter srst pulse_width 100

init
targets
reset halt
#

And open a second openssh session, you will need two

#

In one run openocd again with the new cfg file, the other type telnet localhost 4444

forest lark
#

@stuck coral Im ready

stuck coral
#

Alright, post the output of openocd for me formatted?

forest lark
#
Licensed under GNU GPL v2
For bug reports, read
        http://openocd.org/doc/doxygen/bugs.html
Info : BCM2835 GPIO JTAG/SWD bitbang driver
Info : JTAG and SWD modes enabled
Info : clock speed 2002 kHz
Info : SWD DPIDR 0x2ba01477
Info : atsamd51p20a.cpu: hardware has 6 breakpoints, 4 watchpoints
Info : starting gdb server for atsamd51p20a.cpu on 3333
Info : Listening on port 3333 for gdb connections
target halted due to debug-request, current mode: Thread
xPSR: 0x01000000 pc: 0x00000574 msp: 0x2000dfe0
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
^[[AInfo : accepting 'telnet' connection on tcp/4444```
stuck coral
#

Great, output of telnet?

forest lark
#
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Open On-Chip Debugger
>```
stuck coral
#

Great, what prints when you type in telnet bootloader?

forest lark
#

I got some errors when making a new directory so just used the openocd one and commented the unneeded lines out, hope thats ok

stuck coral
#

Sure, thats fine.

forest lark
#
 Bootloader protected in the first 0 bytes```
#

atsame5 bootloader

stuck coral
#

Ok, atsame5 chip-erase?

forest lark
#
 chip erase started

>```
#

This step never goes passed this

stuck coral
#

Well it returned no?

#

I see a > at the end

forest lark
#

yes, but on other peoples things I usually see more steps?

#

red "L" led is off now

stuck coral
#

There are more steps, please just keep going

#

So next lets manually write the bin, flash write_image bootloader-grandcentral_m4-v3.10.0.bin

#

Then if I remember right, to verify use flash verify_bank 0 bootloader-grandcentral_m4-v3.10.0.bin 0x0

forest lark
#
 SAM MCU: SAMD51P20A (1024KB Flash, 256KB RAM)
wrote 16384 bytes from file bootloader-grandcentral_m4-v3.10.0.bin in 0.186678s (85.709 KiB/s)

>```
#

this is new!

#
 read 16384 bytes from file bootloader-grandcentral_m4-v3.10.0.bin and flash bank 0 at offset 0x00000000 in 0.152210s (105.118 KiB/s)
contents match

>```
#

ready for usb test?

stuck coral
#

There you go, so now it's flashed for certain, yes

forest lark
#

just unplug and test?

stuck coral
#

Sure

#

If it doesnt work, then it is a physical issue with the USB connection or the IC is damaged

forest lark
#

nope, same thing...

#

can I upload sketches through openocd?

stuck coral
#

If you dont see the neopixel go green, then the bootloader cannot enumerate a USB connection with the computer

forest lark
#

Nope, neopixel is solid red and the "L" led rapidly fades in and out
@forest lark this still happens

stuck coral
#

Hm. strange. The only software component is the bootloader on the micros side and now thats flashed correctly

forest lark
#

during some of my fiddling today the neopixel went green, but wasnt connected to usb, is that possible?

#

just connected to swd

stuck coral
#

Hm, it shouldnt do that. Lets try something

forest lark
#

strange

#

What would you like to try?

stuck coral
#

Could you write a arduino sketch that just prints to console something and flashes the LED?

forest lark
#

ok

#

sorry, do you know if this boards led is on pin 13

#

nvm, I will just put an led somewhere

#
  // put your setup code here, to run once:
Serial.begin(115200);
pinMode(9, OUTPUT);
}

void loop() {
  // put your main code here, to run repeatedly:
Serial.println("Something");
digitalWrite(9, HIGH);
delay(500);
digitalWrite(9, LOW);
delay(500);

}```
#

something like this @stuck coral ?

stuck coral
#

Sure

#

So let me try to remember how arduino caches the files... you're running windows I presume?

forest lark
#

yes, windows 10

stuck coral
#

Okay, well I think you can actually go to Sketch>Output Compiled binary and you can then see in your project a .bin file

lyric echo
#

can someone help me with getting my lcd screen to work, it is still doing this.

forest lark
#

ok, did that

woven mica
#

strange image format

lyric echo
#
#include <LiquidCrystal.h>
LiquidCrystal lcd(11, 10, A0, A1, A2, A3, A4);
oid setup()
{
  pinMode(A0, OUTPUT);
  pinMode(A1, OUTPUT);
  pinMode(A2, OUTPUT);
  pinMode(A3, OUTPUT);
  pinMode(A4, OUTPUT);
  pinMode(A5, OUTPUT);    //LCD display
  digitalWrite(A5, HIGH); //LCD display
  lcd.begin(16,2);
}
stuck coral
#

@forest lark so if you can put that on the pi, and replace the bootloader on the metro with the sketch using the same process as reflashing the bootloader, and it doesnt show up as a COM port on your computer, I am at a loss

lyric echo
#

ya I airdropped it from my iphone so idk

forest lark
#

ok, I will just need a few minutes to figure out how to do it and get back to you, thanks for your time, I really appreciate it!

stuck coral
#

Np, if it was in front of me then I could debug it further but for me to do it through discord it would take all day

forest lark
#

So erase chip again?

stuck coral
#

Yes

forest lark
#

teamviewer? 😆

stuck coral
#

Well you also have windows, I would need to adjuest how I do everything and I cannot spend my whole day doing that

forest lark
#

I understand fully, I will let you know what happens

unkempt radish
#

I am trying to upload the Blink Sketch to a Metro M4 Grand Central. It fails when trying to run the bossac cmd with this error: java.io.IOException: Cannot run program "REMOVE/bossac": error=2, No such file or directory.

Evidently, it is trying to run the bossac cmd with this path: REMOVE/bossac

How can I fix this? I am using the latest boards file from GitHub and the latest Arduino (1.8.13)

north stream
#

Have you installed both the Arduino SAMD boards package and the AdaFruit SAMD boards packages?

forest lark
#

@unkempt radish what version is your bootloader?

#

2.0.0. will make you cry

#

@stuck coral The led does not even flash, neopixel and "L" led are off

stuck coral
#

Very interesting, is the LED on pin 9?

forest lark
#

yes, I uploaded the sketch to a mega to test and it works fine

#

I put an external led on pin 9

stuck coral
#

Okay, then just reupload the bootloader. I dont really have another solution other then inspect the USB connections

forest lark
#

Thanks, it is strange that the led doesnt flash though?

stuck coral
#

A bit, the sketches are able to run without a bootloader

forest lark
#

is it possible to upload the bootloader and a sketch with openocd?

stuck coral
#

Yes, multiple ways, I would recommend making a single bin file

unkempt radish
#

@north stream Yes I have, but I installed the Adafruit one first.

#

@forest lark I just installed it. It is 3.10.0

forest lark
#

@stuck coral thanks again for all your help, I think I'm ready to give up for now.

stuck coral
#

Np, too bad about your board

unkempt radish
#

I solved the problem. Within the arduno/tools/bossac folder, it was missing thi latest bossac (1.8.0-48-gb176eee). It was incuded with Seeduino packages, so I just copied it from there.

glossy sierra
#

I just bought a adafruit metro mini 328 and it says I can code it with the Arduino IDE. I have plugged my board up to my computer but it will not recognize. The only method I found for getting it set up is to look under other devices but it is not showing under there either.

fathom ibex
glossy sierra
#

Okay thanks!

glossy sierra
#

@fathom ibex that did not seem to work. I installed the drivers then unplugged and plugged the mini back into my computer and nothing happened

fathom ibex
#

Does your board show up under ports in the IDE?

#

Also, make sure you did this:

When you run it, make sure to click that you want to install the SiLabs CP210x and FTDI chip drivers too!

glossy sierra
#

I installed those with the link and the website says to select the arduino uno board and I did. it also does not show up under the ports in the IDE

fathom ibex
#

oh, you will have to reboot too

glossy sierra
#

nope still nothing. Am I just so dumb I can't see the obvious or could I have gotten a faulty board.

#

It shows on and the board LED is blinking so I know the power is working. My computer just doesn't see it. I am honestly confused

reef ravine
#

@glossy sierra what OS are you running?

glossy sierra
#

10

reef ravine
#

it isn't a "power only" usb cable is it?

glossy sierra
#

I don't believe so

#

Might be

#

It was one I had laying around. So instead of ordering a new one I started using this one

reef ravine
#

some chargers don't connect the data pins

glossy sierra
#

I will go buy a new one tomorrow and see if that fixes it.

#

Okay thanks! Never would have though of this problem

reef ravine
#

cables can bite you 🙂

#

usually the drivers are found on Windows

glossy sierra
#

If I head to Staples and look for a cord will it tell me if it will connect the data pins?

#

Or do i have to buy it and hope for the best or should I just buy one online and wait a few days?

reef ravine
#

i think they are usually marked "data type" or some such, i'll look at Staples quick...

glossy sierra
#

I will go there tomorrow and see. Thanks for the help!

reef ravine
#

look for "Hi-Speed USB 2.0 Cable" or similar

glossy sierra
#

Okay

tacit plaza
#

It's late, I'm tired, and this is probably a really stupid question, but does a joystick button go LOW or HIGH when pressed?

Would this mean when pressed, or while not pressed? :
if (digitalRead(SW_pin) == LOW)

reef ravine
#

is SW_pin setup as INPUT or INPUT_PULLUP?

#

if it's pulled up LOW means pressed

cedar mountain
#

The short answer is that there's no standard... a random joystick might have buttons that work either way.

tacit plaza
#

I have tried it as INPUT_PULLUP, and as just simply INPUT, and niether seem to be working, so the rest of my code is probably just too screwed up.

pine bramble
#

i made a led animation but whne i put batterys nothing seems to work

reef ravine
#

@tacit plaza if you measure the pin voltage, does it change when you push the button?

#

@pine bramble How many LEDs are you using?

pine bramble
#

nah just 7

#

ill not fill hole breadboard for a led animation

reef ravine
#

need a bit more detail which type of LEDs, what board, what voltage...

pine bramble
#

breadboard = 830 tie-points breadbord

#

idk which type of leds

reef ravine
#

single color red LEDs?

pine bramble
#

i did not put on 5v or 3.5 volts

#

single color red LEDs?
@reef ravine no

#

one green,2 blue,1 yellow,2white,1red

#

not rgb

#

do u want a photo of the circuit?

reef ravine
#

i did not put on 5v or 3.5 volts
@pine bramble ?

pine bramble
#

u said what voltage

reef ravine
#

it's likely to need 3.3 or 5 volts

pine bramble
#

oh yea sorry

#

the txt is my code i work on

reef ravine
#

and it's an UNO?

pine bramble
#

yea

reef ravine
#

so it works on USB?

pine bramble
#

yea ?

fathom ibex
#

What voltage is your battery?

reef ravine
#

I don't see any resistors

pine bramble
#

9v

reef ravine
#

@pine bramble are the pins wired directly to the LEDs?

pine bramble
#

int LED1 = 13; int LED2 = 12; int LED3 = 11; int LED4 = 10; int LED5 = 9; int LED6 = 8; int LED7 = 7;

reef ravine
#

do you have any resistors?

pine bramble
#

np

#

oh wait

#

i changed the battery

#

and guess what

reef ravine
#

ok, you may have had a dead battery, but you should have resistors in series with the LEDs

pine bramble
#

idk how to use resistor so

reef ravine
#

you may damage the pins or LEDs without them

pine bramble
#

idk how to use resistors

reef ravine
#

they limit current to a safe level, the striped object above is a resistor

pine bramble
#

but i have

#

resistor

#

and idk how to use them

#

my dad told me about ohms and stuff

tacit plaza
#

He's using a resistor on common ground.

#

(From the looks of the video)

pine bramble
#

not used any resistor

reef ravine
#

i didn't see any...

pine bramble
#

what time is it for u guys

reef ravine
#

UTC -5

pine bramble
#

uhm

tacit plaza
#

It looked like one on the ground rail.

pine bramble
#

thats why i type slowly

tacit plaza
#

Ohh, nevermind. That's prubably just the end of a jumper.

#

Looked like a resistor on my big monitor from across the room.

reef ravine
pine bramble
#

really bro?

#

ok

reef ravine
#

you need resistors with LEDs

tacit plaza
#

But yeah, @pine bramble , you should always use resistors on LEDs or you will burn them out super-fast.

pine bramble
#

HOW DO I USE ONE THEN

#

theres so many resistors

reef ravine
#

use a 220 ohm in series with each LED

tacit plaza
#

Most any of them would be better than none. For most things I just use a 220 ohm. For old school TTL circuits, I will sometimes use 420 ohm instead.

pine bramble
#

at least im happy about my code works...

reef ravine
#

the code works fine

pine bramble
#

@tacit plaza

#

i see u have a steam

reef ravine
#

@tacit plaza did you measure the pin voltage?

tacit plaza
#

Not yet. Had to put it on hold.

#

Taking care of something time sensitive at the moment.

#

but I know my code is bad. Much of it was just guessing, based on what I know of other languages. Still very new to Arduino.

reef ravine
#

do something simple like just reading that pin and printing a 0 or 1, build from there

tacit plaza
#

It's probably a simple oversight, or not knowing enough about code structure. I'll post a photo of the schematics I'm working with and spoiler of the code, after I finish this job.

tacit plaza
reef ravine
#

What's "M"?

tacit plaza
#

(M) = tiny vibrating motors. Their voltage range is good for anything under 6 volts, low power requirements, and enough internal resistance to use as-is. (Salvaged from old cell phones).

reef ravine
#

ok, for experimenting , using diodes across motors is best practice

#

the little phone vibrators will probably be ok

tacit plaza
#

I use motor speed/directional controlers for anything larger.

reef ravine
#

so D2 should be setup as INPUT_PULLUP in setup

#

2 actually

tacit plaza
#

Code, In parts due to character limits:

|| ```code

// Analog Joystick to 4X PWM output

// Arduino pin numbers
const int SW_pin = 2; // digital pin connected to joystick button
const int X_pin = A1; // analog pin connected to joystick X
const int Y_pin = A2; // analog pin connected to joystic Y
const int LEFT = 5; // digital pin for pwm output channel 1 LED
const int RIGHT = 6; // digital pin for pwm output channel 2 LED
const int UP = 10; // digital pin for pwm output channel 3 motor
const int DOWN = 11; // digital pin for pwm output channel 4 motor
const int stateLED1 = 3; // Mode 1 LED test indicator for future use of changing states of behavioral mode
const int stateLED2 = 4; // Mode 2 LED (described above)
int state;

void setup() {
pinMode(SW_pin, INPUT_PULLUP);
pinMode(X_pin, INPUT);
pinMode(Y_pin, INPUT);
pinMode(LEFT, OUTPUT);
pinMode(RIGHT, OUTPUT);
pinMode(UP, OUTPUT);
pinMode(DOWN, OUTPUT);
pinMode(stateLED1, OUTPUT);
pinMode(stateLED2, OUTPUT);

digitalWrite(LEFT, LOW);
digitalWrite(RIGHT, LOW);
digitalWrite(UP, LOW);
digitalWrite(DOWN, LOW);
digitalWrite(stateLED1, HIGH);
digitalWrite(stateLED2, LOW);

state = 0;
}

int leftValue;
int rightValue;
int upValue;
int downValue;

#

Cont:

||


void loop() {  
  upValue = digitalRead(X_pin);
  downValue = 1023 - digitalRead(X_pin);
  leftValue = digitalRead(Y_pin);
  rightValue = 1023 - digitalRead(Y_pin);

  analogWrite(UP, upValue);
  analogWrite(DOWN, downValue);
  analogWrite(LEFT, leftValue);
  analogWrite(RIGHT, rightValue);
  
 if (digitalRead(SW_pin) == LOW) 
    {
      if (state == 0)
      {
        state = 1;
      }
      if (state == 1)
      {
        state = 0;
      }
    delay(500);
    }
  if (digitalRead(SW_pin) == HIGH)
    {
      if (state == 0)
      {
        digitalWrite(stateLED1, HIGH);
        digitalWrite(stateLED2, LOW);
      }
      if (state == 1)
      {
        digitalWrite(stateLED1, LOW);
        digitalWrite(stateLED2, HIGH);
      }
        
    }
  
}

||

reef ravine
#

switch the if (digitalRead(SW_pin) == HIGH) and low statements, does it do something if you press and hold?

#

you really need to keep track of the buttons state, rather than using delay

tacit plaza
#

The intended/desired behavior would be to simply press the button to change behavioral states, press and hold should only count as a single press. Currently, the button does nothing.

reef ravine
#

even if HIGH and LOW comparisons are swapped?

tacit plaza
#

I haven't saved or tried any changes yet.

reef ravine
#

long press may be needed due to the delay statements

#

intended behavior is possible

#

just change line 38 to INPUT_PULLUP and it should work with your joy btn

tacit plaza
#

Swapping HIGH and LOW made no noticable difference.

reef ravine
#

the code runs through the loop so fast the state is changing all the time

#

except for 500 mS when nothing happens

tacit plaza
#

Button reads high, 4.4v on multimeter. Drops to zero when pressed.

reef ravine
#

ok, so it is wired for input pullup, sounds like the button is ok

tacit plaza
#

...my cat decided that he doesn't like the motors. He keeps swatting at my project.

reef ravine
#

lol

tacit plaza
#

(Mental note to self: Consider using vibrating motors in future cat toy builds.)

reef ravine
#

a good project right there 🙂

#

do cats see in color?

tacit plaza
#

Only certain color ranges.

reef ravine
#

was pondering RGB LEDs for cat toy...

tacit plaza
#

They can see from somewhere in the IR band, up to about green. So blue, green and violet all looks the same to them.

reef ravine
#

just RG LEDs then 🙂

tacit plaza
#

That's why when I design pet toys, I avoid using the color blue entirely. They get frustrated not being able to see them outdoors, or losing them in the grass.

reef ravine
#

no FastLED needed for pet toys <mental note>

tacit plaza
#

I hate using the serial monitor. ...

#

Which is ironic, considering that I got into Arduino because I want to get back into developing HID devices.

reef ravine
#

what is the issue with serial monitor?

tacit plaza
#

In my case, portability.

reef ravine
#

but it's great for debugging

#

i have print everywhere when i develop, then disable / remove for field use

tacit plaza
#

I have a weird workspace setup. All of my computers are on a shelf under my gaming monitors, I use wireless keyboard, mouse, and controllers. My workbench is about 10 feet away, and the only USB cable I have to fit my R3 is less than a foot long.

reef ravine
#

oh, need a 5m USB B

tacit plaza
#

I have one on my wish list, but waiting for payday, then delivery.

#

Along with my Leonardo board to start toying with HID builds more directly.

reef ravine
#

yes, hard with an UNO...

tacit plaza
#

Eventually, I want to get back to building sim components. I used to use old junkyard parts to build driving and spaceflight simulation controls.

#

but had to stop when computers phased out serial ports, and adapter prices were prohibitive.

reef ravine
#

i built my buddy who flys RC planes a lawn chair with rudder, throttle, joystk, he sat there and flew by watching the video feed we sent back from the plane

tacit plaza
#

If I ever won a lottery, I would build a full size spaceship simulation. The cockpit would have projection screens outside the glass, the interior would be fully immersive with separate rooms and compartments. Everything, from fuel mix, engine controls, to life support would all be micromanaged manually.

#

I'd make it like a sci-fi "Space Camp" where people could spend a few days living on-board.

reef ravine
#

everything is possible with enough money 🙂

tacit plaza
#

I could even work on making a networked game using several of such simulations, so they could interact in some ways.

#

Every play Star Wars, Knights of the Old Republic?

reef ravine
#

no, but i get the concept

#

i stopped playing after Doom. lol

tacit plaza
#

Most of the game centers around the player, but between every location, they are on a ship called "Ebon Hawk" (if I remember it correctly). I would want to build a ship about that size. The interior space is just a little smaller than the Millennium Falcon.

reef ravine
#

how many crew?

#

4 or 5?

tacit plaza
#

In my dream build, it would be scalable. It would have options to automate systems if a person were not available to manage them.

reef ravine
#

and it all starts with getting 1 button to work

tacit plaza
#

But typically, I think pilot, navigator, one or two gunners, an engineer for managing the engines and life support. Could probably come up with more, or add gunners or crew shifts.

reef ravine
#

ok, i gtg it's almost 3am, try that example and let me know what happens

reef shuttle
#

hi

#

they are really low

pine bramble
#

hello

#

do we really can add our bots?

candid solar
#

Question on using USB power on the Arduino Nano - I want to power my project using a Nano and an LED strip using a USB power supply.
If I plug in the power supply to the USB port on the Arduino and power the LED strip from pin 4 (5V), is it going through the regulator on the Nano?
Ideally I don't want it to because the (60 RGB) LEDs will need a lot of power.

elder hare
#

can fastLED read and put this array on my matrix display?

array([[[149, 145, 203],
        [210, 234, 219],
        [223,  50,  26],
        [166,  34,  65],
        [213,  78, 115]],

       [[191,  54, 168],
        [ 85, 235,  36],
        [180, 140,  96],
        [127,  21,  24],
        [166, 210, 128]]], dtype=uint8)
cedar mountain
#

Are you running Numpy on an Arduino somehow?

#

@candid solar The USB power input should be direct rather than through the regulator, though there are still some potential current limits on the USB connector itself, the board traces, and so forth, so if you have the option to connect up the LED power rail separately, it might be better. This would probably work, though.

candid solar
#

Thanks, I'll try this. The other option is to cut off the USB connector, splice and solder the wires directly to the board

elder hare
#

@cedar mountain no i made a python script with numpy lib that converts a img to an RGB array

#

That's why i was wondering if FastLED could read and output it on my matrix

cedar mountain
#

I'm not quite understanding what you mean by "read", since the RGB array is in your script's Python code, and FastLED is on your Arduino. How are you imagining the Arduino gets access to it?

elder hare
#

@cedar mountain easy... via socket :)
ESP32 = Socket Server
Python = Socket Client

🙂

cedar mountain
#

That'd definitely work. You'll just need to convert the RGB array into some sort of byte format to send across, and then convert it back into whatever FastLED wants.

elder hare
#

this works! so i would need that format if FastLED can't do the RGB format

#

but how i dunno

candid solar
#

@cedar mountain It worked for about 5 min until the nano started smoking! Luckily I pulled out the power right away, the Nano still works. Time for plan B

weak walrus
#

I have kind of a general question

#

I have a TFT LCD screen

#

when I make some pixel art on my computer it looks a lot bigger on the LCD screen. On the computer if I view it in "actual size" its like the actual length/height are smaller than the LCD screen's.

#

then on the screen it fits well but the measurements (not pixel dimensions) seem bigger

#

is there like some DPI or resolution change here probably?

cedar mountain
#

Yup, very likely.

weak walrus
#

thanks!

safe shell
#

There are tons of different pixels per inch measurements for different displays. Depending on how you have your desktop set, the apparent pixels may be less than the available pixels. Even among the 240x___ Adafruit SPI IPS TFT displays (pretty hi-res for hobby displays), I expected them to be same PPI, but each is slightly different (135x240=242ppi, 1.3" 240x240=261ppi, 1.54" 240x240=220ppi, 320x240=200ppi)

north stream
#

Hello, anyone knows what this error means and how i fix it? Thank you!

delicate coral
#

@north stream "int Greenvalue" is a declaration of a variable. It looks like maybe your statement's backwards? Should it be:

int Greenvalue = digitalRead(ButtonForGreen);

#

ditto for Bluevalue...

north stream
#

@north stream "int Greenvalue" is a declaration of a variable. It looks like maybe your statement's backwards? Should it be:

int Greenvalue = digitalRead(ButtonForGreen);
@delicate coral i'll try that

#

@delicate coral it worked, thanks

junior trench
#

I've got a dumb question motivated by laziness. I'm using an Arduino Uno as a tone generator, creating pulsed frequencies out of two digital pins, then combining the output of the two pins to a speaker to generate DTMF tones. In my prototypes I've been using diodes on the digital pins to protect them when I wire the two together. Now that I've soldered everything up I notice I've forgotten to put the diodes in--but the circuit still works and sounds great, no magic smoke was released or anything. Should I go back and redo the circuit to add these protection diodes or is it alright to call it a day?

reef ravine
#

if i understand correctly you have 2 GPIO pins basically connected together?

junior trench
#

yes

reef ravine
#

one pin may be high while the other is low, i think diodes are in order

#

to keep current flow down

#

before the magic blue appears 🙂

#

but cool project!

junior trench
reef ravine
#

somewhere in my junk box is an old Radio Shack chip that generated DTMF

junior trench
#

Now to figure out how I'm gonna get diodes in this thing haha

#

Thanks. I was originally going to use an mp3 board but forgot to, well, get the mp3 board

reef ravine
#

overkill for this

junior trench
#

Making the uno output two frequencies simultaneously was difficult--the tone function only works for one output at a time 😦

#

almost all my processor time is spent flipping those pins lol

reef ravine
#

do the tones actually decode?

junior trench
#

I'm not sure--I took design cues from other projects where they did decode, but they also had some additional circuitry to smooth out the square wave. I don't have any capacitors handy (this is a budget operation lol) so I skipped that step. I don't have any DTMF decoders around to check with

#

When I record the output and look at the spectrogram in audacity it's really noisy lol

reef ravine
#

call an 800 # with a "press 1 for..." voice tree...

junior trench
#

Didn't seem to work with chili's phone attendant

reef ravine
#

some filtering may be needed for actual use, but great as an effect

junior trench
#

Yeah, the DTMF test line I just called can't pick up on it either. Still fun to play with though haha

reef ravine
#

ask away...

junior trench
#

O_o

reef ravine
#

@north stream use pastebin.com if you are trying to paste lots of code

junior trench
#

I should also probably stop driving the speaker straight from the gpio haha. I need to shove a transistor in here and wire it properly to the power rail

reef ravine
#

@junior trench an op amp mixer with a few parts to filter will do wonders...

junior trench
#

I've got one of these

reef ravine
#

you are on the right track but those 10 second delays will make it unresponsive

north stream
#

@reef ravine okay

reef ravine
#

also make each IF statement into its own block

#

right now the others could only possibly trigger IF RED = true

north stream
#

@reef ravine i fixed the delay and the blue isnt working and the RGB

#

@reef ravine and after i click green, it doesn't let me go back to red

reef ravine
#

for starters put each color into its own IF block:
if (Redvalue == true) { digitalWrite(RgbRed1, HIGH); digitalWrite(NormalColorRed2, HIGH); delay(1000); digitalWrite(RgbRed1, LOW); digitalWrite(NormalColorRed2, LOW); }

north stream
#

@reef ravine so what part should i delete from the code and put that instead of it?

reef ravine
#

all your if's run together, using {} as above makes them run one after the other

north stream
#

yah but where in the code?

reef ravine
#

if (Redvalue == true) { <====
digitalWrite(NormalColorRed2, LOW);
} <=====

north stream
#

okay

reef ravine
#

around each of the 3 if's

north stream
#

okay

reef ravine
#

but in the end you'll need to keep track of the "state" of each button

north stream
reef ravine
#

try that

north stream
#

@reef ravine that was the same thing i was using before you gave me it

reef ravine
#

it's not in what you pasted...

#

gotta run to pickup dinner be back later

north stream
#

gotta run to pickup dinner be back later
@reef ravine okay, i'll put the question again later

ashen hawk
#

Hello. Is there any port of touchio from CircuitPython to Arduino? I have a Trinket M0 and I'd like to use capacitive touch on it using Arduino but haven't found an easy solution as touchio.

reef ravine
#

@north stream Still around?

north stream
#

yep

#

i put a qustion in Arduino

reef ravine
#

you using a breadboard?

north stream
#

and a guy is helping

reef ravine
#

ok, i'll lurk

north stream
#

you using a breadboard?
@reef ravine yep

glad birch
#

so..... I was planning on sending a LED color schema using URL encoding to a esp32(using all arduino libraries so in practice a arduino with a wifi module) because I thought that arduino didn't have a good JSON body handling library.... but now I am thinking that it might be better to pass the schema as a JSON body... I already have the code mostly done with URL encoding, but I don't really like it if I am being honest.... the code I wrote that uses URL encoding is here https://github.com/dylanpoll/EmailLightBar/blob/master/emailLEDbot/espRestfulLightBar/espRestfulLightBar.ino , I don't know how it will run yet as I have not done a trial run, will be doing that later, but if anyone can give me some input in if they think I should just swap off to a JSON body post and parse the data out?

#

this is the segment of the code that handles the URL encoding, it is followed by a switch case that sets the LED color arduino //this for loop just makes this setup a little bit easier. cycles through all the url encoded fields. for(int i = 0; i < NUM_LEDS; i++){ //if you change from num leds, account for 0 and make it <= String encodedField = "l"; encodedField += i; encodedField += "="; String diodeColor = "b"; //b will stand for black and fastled treats black as off if(i<10){ //if it is less than 10 the total chars used is 3 int fieldIndex = header.indexOf(encodedField); diodeColor = header.substring(fieldIndex+1,fieldIndex+1); //pull the value from the field for that LED } else{ //greater than 10 the total chars used is 4 int fieldIndex = header.indexOf(encodedField); diodeColor = header.substring(fieldIndex+1,fieldIndex+1); //this limits the substring value to only the char at the index value. }

reef ravine
#

@glad birch idk if what you are doing above or JSON is more efficient but have you seen https://arduinojson.org/ ?

glad birch
#

no i have not D: but it looks like what I need thanks X/

#

its 30 leds, but I want to be able to scale so sending a json object would just be better overall I think X/

reef ravine
#

i found it pretty easy to use last time i needed JSON

junior trench
#

@reef ravine Here's the spectrograph of a 350hz tone played by my method. I need a lowpass or something haha

reef ravine
junior trench
#

I used to play on that site years ago, looks like he's upgraded from java applets!

reef ravine
#

the above is only the 350Hz tone?

junior trench
#

That's the intention at least, yes

reef ravine
#

looks like all the harmonics are equal amplitude

junior trench
#

roughly, slightly more intense at ~2.4k, 1.1k, and 3.2k

reef ravine
#

a simple RC would help big time

#

I was thinking that would be better than diodes anyway

junior trench
#

Of all the assorted electronics I have strewn about, a capacitor just isn't one of them. I honestly am not sure why--I've got plenty of resistors, transistors, optocouplers, jumpers, LEDs, etc.

reef ravine
#

let's see 4 billion LEDs in parallel gotta be getting close to 1 nF 🙂

junior trench
#

I've got two sheets of aluminum foil and a piece of paper

reef ravine
#

even better you can trim easily

#

might make the project a bit unwieldy, and fragile

junior trench
#

I've been known to shove aluminum foil inbetween the pages of a book for reasons

#

should give proper structure 😄

reef ravine
#

lol

junior trench
#

For real though, I should've just bought/built the appropriate tone generator circuitry instead of doing it in software haha

reef ravine
#

wonder if those chips are avail...

junior trench
#

The original DTMF generator chip is still present inside the pay phone, but I have it disconnected since I don't wanna deal with 48V

reef ravine
#

iirc it ran on a 3.58MHz crystal and you just gave it BCD

junior trench
#

Bypassing that to get at the key matrix was super annoying, and the wire I'm using doesn't take to solder very well :X

reef ravine
#

the chip is likely 5v

#

i hate wire like that

junior trench
#

And here's my ugly solder

reef ravine
#

that's not taking solder at all

junior trench
#

Some of them did, which is what perplexes me. They're all cut from the same stock afaik

reef ravine
#

but that chip - can you scrap a bit of the blue stuff off to get the PN?

#

it's a TI of some sort...

junior trench
#

At this point, not really. I'd have to dismantle the pay phone assembly again and I'm not keen to do that

reef ravine
#

oh, a build shot, thought it was in your hand

junior trench
#

Yeah, I took that pic two days ago haha

junior trench
#

Not gonna lie, this build was rough. I'm using what I have on hand at home, and what I have at home is the cheapest soldering iron available, flux core indium solder, and dupont cables

#

But it works ¯_(ツ)_/¯

reef ravine
#

hey if it works...

junior trench
#

At the start of the build I didn't have a multimeter so I was checking consistency with a flashlight and some alligator clips (closing the circuit turned on the flashlight)

#

I stopped by harbor freight to pick up some spade connectors (needed to clip into the handset) and grabbed a multimeter, so that's sorted now

reef ravine
#

A+ for ingenuity, F for accuracy 🙂

#

doesn't tone() just keep putting out tone?

junior trench
#

The flashlight is super sensitive, it turns on slightly even when I hold the clips in each hand

reef ravine
#

<surprised!>

junior trench
#

but yeah, no way to tell what the resistance is, just relative resistance

#

"It's dimmer across this component, must be a higher resistance" haha

reef ravine
#

lol

junior trench
#

tone() does indeed output a constant tone. I could probably use it for one of the two frequencies, rather than doing both of them the ghetto novel way

reef ravine
#

yeah i just looked it does keep going but you can only have 1

junior trench
#

I do have two unos, but it seems like kind of a waste to use one of those just as a tone generator

reef ravine
#

see link above

#

$2

junior trench
#

I think at this point I'm committed, sunk cost and all that 😉

reef ravine
#

👍

junior trench
#

This is the class I ended up writing. Call pulse as often as possible

reef ravine
#

where does the 500000 come from?

junior trench
#

Microseconds per seconds / 2 (divide by two for pulse width from period)

reef ravine
#

gottcha

junior trench
#

I do have enough resistors and pins to do that 🤔 . Though I wonder how necessary that capacitor is

reef ravine
#

you want ac coupled out to your amp

junior trench
#

If you haven't picked up on it yet I'm pretty terrible at the actual electronic part of electronics

reef ravine
#

if you drive a fairly high impedance speaker you may get away without an amp, good enough for test anyway

#

i started the other way, hardware then software

junior trench
#

That's the reference I used to guide my software design

#

I wonder if there's anywhere nearby I can pick up some capacitors

reef ravine
#

the linked code and lib didn't work?

junior trench
#

huh, maybe I didn't get my design patterns from there. I do remember looking intently at that page though haha

reef ravine
#

i have all that stuff, maybe i'll play around with it

junior trench
#

I am going to try that tone code now though

glad birch
#

@reef ravine amazingly easier to work with this than it is with most of node and java's JSON libraries XD

reef ravine
#

i used it with a weather service, made the job much easier!

glad birch
#

yeah, I already have it echoing my JSON posts so now all I have to do is attribute values to local variables XD

#

and I plan on cheeping out using a for loop and iterating over LED's in a array

reef ravine
#

so much better than hand coding every time you need more than a few bytes

junior trench
#

Using the tone library from that page and no filter circuit, this is what my spectrograph looks like (770hz + 1477hz)

reef ravine
#

woo hoo!

#

much cleaner

#

a few pieces of tin foil and yer golden

junior trench
#

Here it is at 350+440hz

reef ravine
#

it needs the low pass

#

but it is cleaner

#

and that's with the pins tied together?

junior trench
#

yes

#

with diodes, feeding to a transistor

reef ravine
#

oh, they are isolated now

#

lots of overtones but clean around the tones

junior trench
#

I forgot to put a resistor in before I soldered everything up and covered it in heat shrink tubing :X

reef ravine
#

heat shrink before test? <shakes head>

junior trench
#

I did test it first, I'm just an electronics noob and it didn't occur to me that I should probably have a resistor in there until like 2 hours after I finished cleaning it up haha

reef ravine
#

did you try the test line with it ?

junior trench
#

Yes, still no dice

#

those harmonics are really getting in the way it seems

#

that or my phone filters out dtmf frequencies from the mic

reef ravine
#

lol

#

it may...

#

does it sound right?

#

or is it noisy

junior trench
#

It doesn't sound noisy, but it also doesn't sound right with all those harmonics. But as this is just a prop it'll probably pass inspection by most people

reef ravine
#

if it makes different noises per button, yes 🙂

junior trench
#

This is what I've done

reef ravine
#

you really need a base current limiter

#

those pins are being dragged down to 1.4v

#

and i would use 5v for the speaker

junior trench
#

When driving the speaker at 5v the leds on the board get visibly dimmer. At 3.3v they stay near full brightness. I don't really know what I'm doing outside of software

reef ravine
#

the diode drops .7v and the base emitter drops another .7v so the pins which want to be 5v are dropped to 1.4v, the transistor needs a few K between base and diodes

junior trench
#

I could shove a pair in here without too much trouble, if my soldering iron will cooperate

reef ravine
#

what transistor?

#

3904?

junior trench
#

pn2222a

reef ravine
#

ok, lemme scribble

#

yeah 1k will work there

#

then maybe you can drive the speaker harder with 5v

junior trench
#

I've got plenty of resistors if you think another value would be better

reef ravine
#

that seems about right

junior trench
#

ooh yeah, putting the 1k resistors in helps a lot. It sounds the same, but the arduino no longer looks like it's going to give out when driving the speaker at 5v

#

In the interest of not soldering anything at 1AM I've slipped the resistors in between the female connector on the 'duino and a female-female dupont, letting me connect everything with hopes and dreams

#

electrically, it now resembles the most recent screenshot. I really do wish I had a capacitor around though 😂

#

Thanks for all your help

reef ravine
#

you are welcome, i gtg but let me know how it works for you!

north stream
#

That sounds plenty good.

gritty hound
#

It's more likely electrical noise from the LEDs than a low voltage issue. You may be able to use some filter circuitry to isolate the LEDs from the other devices, to protect them from the noise or short duration voltage sags.
@north stream

Hmm are you sure the problem comes from the LEDs ?

north stream
#

Absolutely not sure, which is why I qualified my statement with "more likely", indicating that doing some research would be a good idea.

gritty hound
#

Oh ok ok, I tried doing some research but didn't find anything

reef ravine
#

@gritty hound do you have a voltage divider on the HC-0x modules Rx pin?

gritty hound
#

What is a voltage divider?

#

A resistance ?

#

If so, no

#

The Rx pin is directly on the pins of my Arduino

reef ravine
#

the HC-05 or 06 wants no more than 3.3v in

gritty hound
#

Isn't it what the pins send?

#

The normal pins

#

I think I'll see with a multimeter

reef ravine
#

do you have an HC-05 or similar?

gritty hound
#

Yep

#

HC-05

reef ravine
#

look on the back, see 3.3v?

gritty hound
#

On the power pin I see
"POWER: 3.6V-6V"

And on the RXD and TXD pins :
"LEVEL: 3.3V"

#

So yes

reef ravine
#

the RX pin does not "like" to see 5v from the arduino, so you need a "voltage divider"

#

the 3.3v FROM the HC-05 to the arduino is OK

gritty hound
#

Ok thanks so
Voltage divider = resistance

reef ravine
#

it uses resistors to divide a higher voltage to a lower one, 2/3 of 5v is ~3.3v

#

just thinking you may be barely working until you add noise to the circuit, try that and maybe your power problem will be solved

#

in any case you should not give 5v to the Rx pin

gritty hound
#

Ok I'll try when I finished eating thanks a lot

reef ravine
#

you are welcome

gritty hound
#

And yes I meant resistor, not resistance, resistance is in french

reef ravine
#

it is not a problem, i'm used to people who speak different languages

opal prawn
#

hi guys anyone could help me with arduino bootloader?

#

I think I bricked 2 mega328p this week

#

my isp programer cant even read signature now

#

is there anything what could be done except HVSP?

reef ravine
#

were you using "Arduino as ISP" or other?

opal prawn
#

also

#

but it read signature of 0x0000

#

but previously I used by usbasp clone

#

and I write fuses manually and then burn bootloader by avrdudess

reef ravine
#

maybe someone with more experience will see this and help, i burned a bunch of bare 328p's once and had no issues but used an UNO to burn them.

opal prawn
#

with external clock or internal?

gritty hound
reef ravine
#

the ratio is important, 5v from arduino through a total of 3k (in this example)to ground. at the 2K the voltage is 2/3 of 5v. 10k and 20k would work as well.

reef ravine
gritty hound
#

the ratio is important, 5v from arduino through a total of 3k (in this example)to ground. at the 2K the voltage is 2/3 of 5v. 10k and 20k would work as well.
@reef ravine

I think the highest resistor I have is 220 Ohm :/

gritty hound
#

After searching the highest I have is a 470 Ohm

north stream
#

Use three of them?

gritty hound
#

Oh, ok

south pulsar
#

how do i remove a row of header pins from my arduino nano?

north stream
#

Are they soldered in?

south pulsar
#

yes

north stream
#

My usual approach for that is to either pry off the plastic bit that holds the header pins together (or snip it into pieces) and unsolder one pin at a time.

south pulsar
#

what tool do you usually use to pry off the plastic bit?

#

im having a tough time doing that

north stream
#

Usually a spudger or small screwdriver. If it really resists being removed, I just cut it into pieces with small cutters like flush cutters.

south pulsar
#

update: things are going good

#

i have half the pins removed

#

screwdriver did the trick

green sable
elder hare
#

so this is from python side

    def convertImage(self):
        try:
            img = Image.open(self.imagePath).convert("RGB")
            img_array = img.tobytes().hex()
            list = [f"0x{''.join(b)}" for b in batches(img_array, 6)]
            self.string = ", ".join(map(str, list))

it sends a string to my ESP32 and i've been messing around with my 16x16 LED matrix and found a tutorial that uses a

const long pixelArt[] =  {};

but how can i get that String coming from python side inside that array?

glad birch
#

I seem to have a issue with neopixel and my esp32

#

it has really bad color matching, sometimes the LEDs flicker different colors while updating the strip

#

most times color values show differently at different positions despite being correctly attrributed

glad birch
#

ahhhhh I think I figured out my issue, its library issues with the esp32 and neopixel, swapped off to neopixelbus and now its all good ;D

fluid dragon
#

Hey guys, how goes?

#

I have arduino IDE loaded, and pasted the code with the mute button function, but when I go to verify I'm getting: TrinketHidCombo.h: No such file or directory.

cedar mountain
#

Did you install the library in the previous tutorial step?

fluid dragon
#

I did yeah. I guess I was rushing this, and didn't install/select the proper .json information. So, now I'm going back through and reading SLOWLY so I don't miss anything.

#

I'm following the config now to set up IDE properly also, making sure this time I don't miss anything.

#

Okay. Drivers installed, json configured and trinket 5v USB set up. Exited and reopened. When trying to verify it now, I'm getting a stray \302 in program

elder hare
#

Anyone?

fluid dragon
#

If I look at the box below, this is what I'm seeing specifically:

cedar mountain
#

@fluid dragon That seems to be a non-breaking space character. Not sure how it got into your code... maybe retype any whitespace in that line.

fluid dragon
#

Honestly, didn't type anything. Only copied/pasted from Adafruit, and downloaded the TrinketHidCombo.h file.

#

I'll try a recopy/paste on the initial code w/mute button.

cedar mountain
#

The copy-paste probably did some HTML whitespace mangling.

#

Can you download the code instead?

fluid dragon
#

Sure, can do. Sec.

cedar mountain
#

Just rename to something.ino.

fluid dragon
#

I have a feeling I have the wrong board selected maybe?

#

lemme swap out and go direct to PC instead of USB hub.

#

nope, didn't do any good.

cedar mountain
#

Which Trinket do you have? There's a Trinket, Pro Trinket, Trinket M0...

fluid dragon
cedar mountain
#

Gotcha. The error message says it was expecting a Pro Trinket, so you might need to install a different library? I'm not completely sure what hardware the code supports.

fluid dragon
#

totally not sure why it's asking for pro trinket hardware. Assuming ATtiny85@8MHZ is correct?

fluid dragon
#

terminating ' character mssing?

#

<!-- '"` --><!-- </textarea></xmp> --></option></form><form class="js-jump-to-line-form Box-body d-flex" action="" accept-charset="UTF-8" method="get">

#

where?

cedar mountain
#

Huh? That doesn't look like code at all. It's a web page.

fluid dragon
#

That's what it's from

cedar mountain
#

That looks like you saved a GitHub web page instead of the raw code file itself.

fluid dragon
#

Disclaimer, I'm not a coder/programmer by any means. Hardware is moreso my area.

cedar mountain
#

What does TrinketHidCombo.h look like now?

fluid dragon
cedar mountain
#

Gotcha, back to that Pro Trinket versus Trinket error. I'm not sure whether this is supposed to work on the lower-speed board or not.

fluid dragon
#

Thanks anyway guys..

#

at least I know my microsoldering is still on point..

glad birch
#

can arduino's use .env files?

river osprey
#

i have a 120x120 BMP that i want to show full-screen on a 240x240 display (tft GIZMO) . I'm using arduino. Is there a way I can do this, without resizing the image to 240x240 (and making it 4x as large) as i have lots of images i need to display and limited storage

lone ferry
#

@river osprey Can you resize the data while you're copying it to the TFT's display memory?

raw forum
#

Could somebody tell me why this doesn't work? when I type in hello , it gives me hello correctly but it doesn't give me goodbye like stated

lone ferry
#

You can't do x == "hello"..

odd fjord
lone ferry
#

I think with String it is if (x.compareTo("hello") == 0)

odd fjord
raw forum
#

I used Matthijs solution but still didn't work or did I do something wrong? And jerryn some other people suggested me to use char arrays but do I have to? can't I use strings?

lone ferry
#

Try Serial.println("goodbye") instead of print

#

Oh I think the problem is that your string x also includes \r and/or \n characters. You'll need to strip those off before doing the comparison.

raw forum
#

How to I strip those off?

lone ferry
#

x.trim()

#

I looks like x == "hello" should actually work too then. 😄

raw forum
#

x.trim(\r && \n);

#

like that?

#

It is the first time I'm using strings so I'm a bit of a noob sorry haha

lone ferry
#

No, literally just x.trim();

raw forum
#

it works!

odd fjord
#

Yay! Well done @lone ferry !

raw forum
#

@lone ferry thank you!!

candid topaz
#

actually, Serial.readStringUntil('\n')

lone ferry
#

Does that skip over the \n next time you try to read from Serial? @candid topaz

raw forum
#

@candid topaz @lone ferry that works as well

candid topaz
#

Returns
The entire String read from the serial buffer, up to the terminator character

lone ferry
#

"The terminator character is discarded from the serial buffer." So yes, I guess. 🙂

elder hare
#

This is the python side of my code where i take an image (16x16) and convert it to R G B string and then sends this via SOCKET to my ESP32

    def convertImage(self):
        try:
            img = Image.open(self.imagePath).convert("RGB")
            img_array = img.tobytes().hex()
            list = [f"0x{''.join(b)}" for b in batches(img_array, 6)]
            self.string = ", ".join(map(str, list))
            print(self.string)
        except Exception as e:
           print(e)

then in in my arduino sketch (using ESP32) i have

const long pixelArt[] = { }

it should look like this

const long pixelArt[] = { 0x000000, 0x000000, 0x000000, 0x000000 }

then i display it on my 16x16 LED Matrix like so

    void PrintImage() {
      for(int i = 0; i < NUM_LEDS; i++) {
        leds[i] = pixelArt[i];
      }
    }
the incoming string from socket is this
        StaticJsonDocument<256> doc;
        deserializeJson(doc, payload);
        if(doc["pixArt"]){
          doc["pixArt"]; // This is the string from the python inform of a json
        }

my question is how do i get that string inside that const long array? :/

odd fjord
#

My suggestion would be to parse the incoming string and populate the elements of the array.

lone ferry
#

I'd suggest not sending it as a string but as the actual binary data. Then you can just memcpy the data into the array.

elder hare
#

how what huh? 🙂

glossy sierra
#

Best place to learn Arduino C? I find a lot of things but they are all basics and I already know the basics

#

I really just need to know the syntax

lone ferry
#

@elder hare If you want to use JSON to send this stuff, you can base64 encode the pixel data from the NumPy array and send it to your ESP32. Then you base64 decode this data and memcpy it into your pixelArt buffer. (However, you should send the data as 4 bytes per pixel instead of the 3 bytes you're using now.)

odd fjord
elder hare
#

@lone ferry why 4bytes tho?

lone ferry
#

@elder hare Because a long is 4 bytes.

#

I mean, you can send them as 3 bytes per pixel from the Python script but then you have to convert them to 4 bytes per pixel anyway.

elder hare
#

oh? im a beginner at best at this 🙂 just started messing with my 16x16 LED matrix

lone ferry
#

The reason I recommended sending the data as binary is that you don't need to parse it. If you're sending it as 0x12345678, 0xff00ff00, etc then you need to parse this text data back into numbers.

elder hare
#

btw im not using numpy

lone ferry
#

Ah you're right, you're doing img.tobytes(), not img.toarray(). But that doesn't really matter here. 😉

elder hare
#

true just wanted to mention it 😛 hehe

#

on the python side i just found out i dont need map and str in the join... :P

befor :

self.string = ", ".join(map(str, list))

after :

self.string = ", ".join(list)

still outputs the correct format

0x66cccc, 0x66cccc, 0x66cccc, 0x66cccc, 0x66cccc, 0x66cccc, 0x000000, 0x000000, 0x000000, 0x000000, 0x66cccc
lone ferry
#

Because you say "correct format", I'm afraid that you think you can use this in your ESP32 program like that. You can't use Python to generate C source code like this, because source code only works at compile-time, not when the program is already running...

candid topaz
#

i think its "correct format" if you want to copy/paste that code to arduino program 🙂 but not for live streaming images from pc to arduino

elder hare
#

i hate programing in 2 languages -.- sucks

glossy sierra
#

@odd fjord so how close to actual C++ or C is Arduino C?

candid topaz
#

C++

lone ferry
#

i think its "correct format" if you want to copy/paste that code to arduino program
I guess that depends on whether the TFT uses alpha channel / whether the bytes are ARGB or RGBA. 0x66cccc might be interpreted as 00 red, 66 green, cc blue, cc alpha 😉

frank linden
#

@glossy sierra For a little extra information regarding the Arduino 'programming language' if you are curious: Arduino is not a programming language, it is a library that help simplify some of the lower level C instructions. It seems like it's own programming language when using the Arduino IDE as it automatically #include <Arduino.h> just like any other library without actually displaying it, and generates function prototypes among other things like saving files as .ino instead of .cpp (https://www.arduino.cc/en/main/FAQ). When switching to another IDE like VSCode + PlatformIO extension, you program Arduino boards using C++ files, and just include the Arduino.h file.

hallow pike
#

i dont know what gnda, vcc, nc, vout means in relation to my arduino

#

any pointers would be greatly appreciated

north stream
#

GNDA will be your Arduino ground.

#

VCC will be your Arduino +5V

#

NC is "no connection", you don't need to so anything with that pin

#

VOUT is the analog signal from the sensor, connect it to one of the analog inputs of your Arduino

hallow pike
#

thank you so much. love the collaboration the internet allows now

#

cheers!

visual marsh
#

кто может помочь с кодом на ардуино?

sour tide
frank linden
#

@sour tide I just responded on the thread, hopefully that helps them

sour tide
#

thanks!

tacit plaza
#

Does anybody know where I can buy labeled Leonardo headers? I found a board that I want to get which promotes the idea of "Young Women in S.T.E.M. Programs", but they do not have labelled headers like most of my other boards have.

sour tide
#

Thanks again for replying @frank linden. Looks good!

rose pond
#

It's for a dc motor

north stream
#

Looks like there's some weird stuff in your arduino/libraries directory, which is confusing it. I'm not sure what TheBlink_june11d is, but perhaps it doesn't belong there?

rose pond
#

OH

north stream
#

anyone knows how i can connect one wire to 4 areas? its the wire that comes from the ultrasonic sensor ground.

reef ravine
#

@north stream are you using a breadboard?

north stream
#

yes

reef ravine
#

ok, are you asking how do all the ground wires get connected?

north stream
#

I'm sorry that its not clear, let me clear it

#

@reef ravine what I'm asking is how the wire that's from the ultrasonic sensor's ground, its connecting there and 3 other areas in the LCD,

reef ravine
#

it looks like an omission from the drawing, all the ground wires should be in common, the same place as the buzzer ground

north stream
#

what do you mean?

reef ravine
#

generally black wires are used to indicate the wire is ground. all the black wires should be connected together, and to the arduinos ground

north stream
#

but how do i connect 1 wire to all the areas?

quartz furnace
#

Question -- I had a ESP32 inland board given to me. Looks like it is from Microcenter.. Does not say what board to select in the Arduino IDE.... have done a basic search for tips online (can't find anything) Unlike ESP8266 in the Arduino IDE I do NOT see a "generic"verision,, Name of the board is just "ESP 32 Core Board" (Using Ardiono 1.8.7) *Would love to connect this board to Adafruit IO

reef ravine
#

on the breadboard do you see the columns on either edge, marked in red and blue typically?

north stream
#

actully im not using a bread board

#

only aurduino uno

#

sorry

reef ravine
#

perf board?

#

or a printed circuit board?

north stream
#

non

#

im doing just like the image

reef ravine
#

@north stream so just wires from part to part?

north stream
#

yep

#

like the image

reef ravine
#

you are soldering them?

north stream
#

nope

quartz furnace
north stream
#

im connecting them from the area that its supposed to be connected with no soldering

reef ravine
#

can you send a picture? i am not sure i understand what you are doing

north stream
#

okay

#

well im doing like the image like i told you before

#

no solder

#

let me send you the link of the vid

#

@reef ravine i cant send a pic of what im doing cause i wanted to connect that the first

#

sorry

reef ravine
#

@quartz furnace the inland site says "ESP-WROOM-32", no such option?

#

@north stream if you aren't soldering and aren't using a breadboard then yes please, i don't follow

north stream
#

okay

#

ill make it

#

one sec

quartz furnace
#

@reef ravine Correct, I don;t see that listed as an option

north stream
#

@reef ravine it'll take me about 5 mins. sorry

frank linden
#

@north stream If I understand correctly, you are trying to connect the GND black wire to the Arduino in multiple spots. The Arduino Mega has multiple GND ports, as seen in yellow in the picture attached. Simply wire the ground wires to any of these pins.

reef ravine
#

@quartz furnace i know what you mean, i haven't loaded esp32 yet (just 8266), try various options with a blink sketch and see if it compiles

north stream
#

@north stream If I understand correctly, you are trying to connect the GND black wire to the Arduino in multiple spots. The Arduino Mega has multiple GND ports, as seen in yellow in the picture attached. Simply wire the ground wires to any of these pins.
@frank linden yep

frank linden
#

Is that enough ground pins for what you are trying to accomplish/am I understanding you correctly?

north stream
#

Is that enough ground pins for what you are trying to accomplish/am I understanding you correctly?
@frank linden what do you mean?

frank linden
#

Since I kind of came in in the middle of the discussion, I want to make sure you are just trying to connect multiple ground wires to an Arduino

north stream
#

yep

reef ravine
#

i think the issue is the diagram from that tutorial is missing a ground wire...

north stream
#

i think the issue is the diagram from that tutorial is missing a ground wire...
@reef ravine how do i fix that?

reef ravine
#

just connect all the black wires to one of the grounds that @frank linden showed

north stream
#

how can i connect all of them?

reef ravine
#

there are 5 yellow dots in the diagram above, use any of them

north stream
#

im using uno

#

not mega

frank linden
reef ravine
#

a breadboard is handy for this, the uno has three sockets marked ground

#

plus ICSP but not going there...

north stream
#

@reef ravine so what should i do

reef ravine
#

i think you will need a breadboard

frank linden
#

Do you have any female header? You may be able to work off the ISP ports

north stream
#

Do you have any female header? You may be able to work off the ISP ports
@frank linden what do you mean?

reef ravine
#

to start with basics, how are the wires connected to the ultrasonic sensor?

north stream
#

should i show you how mine is connected?

reef ravine
#

ok, or are you using push on wires?

north stream
#

ok, or are you using push on wires?
@reef ravine i dont know whats push on wires so ill send you how mines looks

#

one sec

reef ravine
#

ok

north stream
#

let me do it

#

one sec

#

let me take a pic of it

pine bramble
#

how much does an arduino cost

north stream
reef ravine
#

@pine bramble it depends on where you buy, which model, genuine or clone, $5 to $30 US

frank linden
#

@north stream The part of the cable you plugged into the ultrasonic sensor are female connectors, the ones you would plug into the Arduino are male

pine bramble
#

woah that cheap

north stream
#

@north stream The part of the cable you plugged into the ultrasonic sensor are female connectors, the ones you would plug into the Arduino are male
@frank linden okay

reef ravine
#

@north stream what is at the other end of the wires, do they have pins?

north stream
#

i didnt connect it

reef ravine
#

is it bare wire? a pin?

north stream
#

its a pin

reef ravine
#

ok, do you have wires with both pins and female connectors?

north stream
reef ravine
#

ok so those will plug in with no problem, do you have more wires or only those?

north stream
#

lot more

reef ravine
#

look and see if you have wires that are male on one end and female on the other end

north stream
#

okay

reef ravine
#

ok, and you need one more ground connection correct?

north stream
#

yep

#

a black one

reef ravine
north stream
#

okay

reef ravine
#

see the button on the top?

#

near it are 6 male pins

north stream
reef ravine
#

yes, there is another ground there

north stream
#

ya

frank linden
north stream
#

If this helps, wire it to anything circled in orange
@frank linden what do you mean?

frank linden
#

Any of those pins/the ones AnonEngineering is talking about, are all wired together

#

They are all ground

north stream
#

okay

#

wait the ones around the buttons?

frank linden
#

Yes, those included

north stream
#

okay

frank linden
#

But only the circled one, that say GND

north stream
frank linden
#

Yes

reef ravine
#

yes

north stream
#

okay

#

so what do i do know?

frank linden
#

Connect that where the black wire went in the diagram

north stream
#

i dont get what you mean

#

sorry

#

can i call with someone so i can understand what you mean better please?

reef ravine
#

do you have a wire that is female on one end that will connect to where you need it?

north stream
#

you mean a side that has the pin and another that doesn't?

reef ravine
#

yes

north stream
#

yes

#

i have a lot

reef ravine
#

the female end will push onto the ground pin we were showing

north stream
#

yes

reef ravine
#

then you have another ground connection

north stream
#

yes

#

i have 3

reef ravine
#

four, including that pin

north stream
#

what do you mean?

#

if i have 3, how do i connect 4?

reef ravine
#

right now, what is missing a ground in your circuit?

north stream
#

yes

#

1 more ground is missing

reef ravine
#

which part is missing the ground?

frank linden
#

Looking back at the diagram, it appears you need 6 GND connections

north stream
#

wait not GND

#

can you please call

reef ravine
#

ground = GND

north stream
#

its way easier

#

not ground

frank linden
#

Unfortunately I cannot call

north stream
#

its how that one wire is connected to 4 areas @reef ravine

#

Unfortunately I cannot call
@frank linden its okay

reef ravine
#

on the LCD?

its how that one wire is connected to 4 areas
@north stream

north stream
#

yes

reef ravine
#

are there wires there or pins?

north stream
#

yep

reef ravine
#

all 3 black lines on the LCD are pins?

north stream
#

what do you mean

reef ravine
#

can you post a pic of the LCD showing its connections?

north stream
#

mines?

reef ravine
#

yes