couple questions: usb cable and programming the clock

couple questions: usb cable and programming the clock

Postby exibar » Fri Jan 27, 2012 3:08 am

Great item! I'm going to purchase one for sure for a boy scout event coming up with a Military spy theme...

couple questions:

the USB programming cable, is that just a regular USB cable? I have tons of them laying around in a box, and I could easily wire one up... or I may even have one that would plug into a motherboard usb header... What would the pinouts be? Is there a pinout diagram for the cable?

2nd question:

I'd like the disarm wire always to be the same wire, can that be easily programmed instead of having it randomized?

thanks!
Mike B
exibar
Newbie
Newbie
 
Posts: 10
Joined: Fri Jan 27, 2012 3:05 am

Re: couple questions: usb cable and programming the clock

Postby Michael » Fri Jan 27, 2012 11:25 am

No, it's not a normal USB cable. It's a USB to Serial converter and there's actually a chip embedded in the cable. That's why it's expensive. I'm all out of these at the moment but more are arriving in the next few days.

If you want the same wire to be used for disarm instead of random, that's a very simple change in the code. Change this:

Code: Select all
  // assign random pins
  defusePin = random(WIRE_1, (WIRE_4+1));
  detPin = defusePin;
  while (detPin == defusePin) {
    detPin = random(WIRE_1, (WIRE_4+1));
  }


to this:

Code: Select all
  detPin = WIRE_1; // or whatever you choose
  defusePin = detPin;
  // now find a random value for defusePin that is not detPin.
  while (defusePin == detPin) {
    defusePin = random(WIRE_1, (WIRE_4+1));
  }
Michael
Administrator
Administrator
 
Posts: 460
Joined: Sat May 29, 2010 8:24 am

Re: couple questions: usb cable and programming the clock

Postby exibar » Fri Jan 27, 2012 2:16 pm

cool.... ok so I'll have to do something about the serial to usb converter...

cool about the code, I looked it over after sending the message and everything is really easy to follow and modify, I really really like it! ;-)
exibar
Newbie
Newbie
 
Posts: 10
Joined: Fri Jan 27, 2012 3:05 am

Re: couple questions: usb cable and programming the clock

Postby exibar » Fri Jan 27, 2012 2:23 pm

If I get the little adapter board, what voltage should it be set to? 5v or 3.3v? I see the adapter board comes preset at 5v.
exibar
Newbie
Newbie
 
Posts: 10
Joined: Fri Jan 27, 2012 3:05 am

Re: couple questions: usb cable and programming the clock

Postby Michael » Fri Jan 27, 2012 2:33 pm

5V. I typically use a 5V USB to serial FTDI adapter to program boards.
Michael
Administrator
Administrator
 
Posts: 460
Joined: Sat May 29, 2010 8:24 am

Re: couple questions: usb cable and programming the clock

Postby el tecnico » Mon May 28, 2012 10:38 am

Hi, I'm new to this forum, would need a code for 4-wire never change that is 2 not 1 that triggers accentuated nothing you stop and other

a greeting mario
el tecnico
Newbie
Newbie
 
Posts: 2
Joined: Mon May 28, 2012 10:33 am

Re: couple questions: usb cable and programming the clock

Postby el tecnico » Mon May 28, 2012 11:05 am

hola soy nuevo en este foro, quisiera 2 códigos 1 para que los 4 cables siempre sean los mismos y otro código para que el cable de detonación siempre sea el mismo y los demás a boleo

un, saludo
el tecnico
Newbie
Newbie
 
Posts: 2
Joined: Mon May 28, 2012 10:33 am

Re: couple questions: usb cable and programming the clock

Postby Keatah » Wed Nov 21, 2012 4:29 pm

I wonder if the wires' functions can be programmed through a button combination or something. For those of us not familiar with whatever language this is written in.

I looked at the code above, would that be a simple cut & paste replacement?

And are there any beginner's resources on the net I can use to get a handle on how this code works? While I'm sure there's tons of stuff, but what about simple tutorials?

Eventually I'll pick this stuff up, I'm sure.
Keatah
Newbie
Newbie
 
Posts: 2
Joined: Wed Nov 21, 2012 2:33 pm

Re: couple questions: usb cable and programming the clock

Postby Michael » Thu Nov 22, 2012 7:55 pm

The language is C. This device is a specialized Arduino board. You program it using the Arduino IDE, and using the Arduino libraries that make C coding easy. There are many, many web sites with information about Arduino programming. Start at the official Arduino site http://arduino.cc
Michael
Administrator
Administrator
 
Posts: 460
Joined: Sat May 29, 2010 8:24 am


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 1 guest