November 01, 2024, 02:37:00 AM

News:

Got VSA?  Want to use your Prop-SX?  Now you can!  See the VSA section of the Library forum for Prop-SX code that works with VSA.


Serial Connection from BOE to AP-16+

Started by bill chennault, January 26, 2011, 09:04:04 AM

Previous topic - Next topic

bill chennault

All--

I would like to experiment further with the AP-16+ by running the BS2 demo program. I am an electronic idiot. Will you please help me with the serial connection between the BS2 and the AP-16+? Specifically, I need to understand the connection pin to pin.

Thanks!

--Bill
You are what you write.

JonnyMac

Use the 3-pin (servo) header for P15 and the demo program for the Prop-2 will work as-is.
Jon McPhalen
EFX-TEK Hollywood Office

bill chennault

Jon--

If it was easy, EVEN I could do it! :) I do not get any sound. Here is the PBasic DEBUG screen . . .

AP-16 Version รนรป

Play SFX01.WAV
-- whoops, no file!

Reduce volume

Play SFX01.WAV - low volume
-- playing!

Play random SFXnn.WAV
-- playing!

Play WOLF.WAV
-- playing!

Testing done


And here is a link to a photograph of the simple BS2/AP-16+ setup.

What am I doing wrong?

Thanks!

--Bill
You are what you write.

JonnyMac

January 26, 2011, 01:17:52 PM #3 Last Edit: January 26, 2011, 01:49:31 PM by JonnyMac
QuoteAnd here is a link to a photograph

You didn't read the instructions, Bill!  ;D   If you had, you would have set the BR switch to ON -- I can see in the photo that it's off.  You'll need to set that swtich and then power down and back up (the AP-16+ only scans that switch on power-up because it sets the speed of the serial processor).
Jon McPhalen
EFX-TEK Hollywood Office

bill chennault

JonnyMac--

I read the documentation; I just didn't know a BS2 would support 38.4k baud.

I placed BR in the ON position. I get the same results; nothing. All of my files play fine when using Audio Select. Do I have the BOE's servo power jumper in the correct position? (BOE photo.)

The AP-16+ is a neat looking machine. I would like to make mine work. I appreciate your help.

--Bill



You are what you write.

JonnyMac

January 26, 2011, 02:40:59 PM #5 Last Edit: January 26, 2011, 02:43:34 PM by JonnyMac
The BOE power selection for servos does not matter, that wire is not connected on the AP-16+.  Did you cycle the power on the AP-16+ after changing the swtich?

You may need to add a 4.7K resistor between P15 and Vdd (+5) on the BOE.  We use open-mode serial which means the line requires a pull-up and we do not put that on the AP-16+ because it is on the Prop-1/2/SX.
Jon McPhalen
EFX-TEK Hollywood Office

bill chennault

Jon--

Yes. I cycled the power. I cycled it on both the AP-16+ and the BOE. There is now a 4.7k resistor between P15 and Vdd. Still no go.

The PBasic IDE shows 9600, N, 8, off. Does this apply to the AP-16+? The DEBUG display is S L O W, with more than a minute between sub-routine executions. (SFX00 - SFX15 are all 1 second files.)

I am using a 1Gb Panasonic Class 2 SD card. Could it work well using Auto Select and not work under program control?

I have AMBIENT.WAV running. It never gets interrupted by the demo code.

--Bill
You are what you write.

bill chennault

JonnyMac--

QuoteUse the 3-pin (servo) header for P15

I must have misunderstood.

You mentioned P15. The demo code uses P15. But, the only connection between the AP-16+ and the BOE is the 3 pin header wire connecting one of the AP-16+ serial connectors and one of the BOE's servo ports.

Does this make sense?

--Bill
You are what you write.

JonnyMac

I will chide you for not reading docs and myself for not looking at your image more closely.

1. Use P15
2. If you look in the Boe docs you'll see that it's the header opposite of what you're using.
3. Put a 4.7k resistor between the P15 output terminal (near the breadboard) and Vdd (5v)

Right now you have the serial header connected to P12 so the program won't work (without editing).
Jon McPhalen
EFX-TEK Hollywood Office

bill chennault

JonnyMac--

My electronics ignorance is overwhelming. I understand the code; no problem. It's simple. And, I can easily put a 4.7k between BOE p15 and Vdd. I have placed the 3 pin header connector on one of the 3 pin blocks on the AP-16+ SERIAL connection, respecting BRW.

What I am CONFUSED about is the AP-16+ - BOE p15 connection. (In my mind) Connecting BOE p15 to the AP-16+ SERIAL port header is unclear. WHICH AP-16+ pin (BRW?) do I connect BOE p15 to? Doesn't there have to also be a ground connection between the AP-16+ and the BOE? (BOE Vss to AP-16+ . . .?)

I understand my electronics ignorance. It bites me. That is why I am so slow regarding many projects.

The AP-16+ documentation is very good. However, I cannot see how to connect the AP-16+ properly to the BOE (or any other microcontroller). I know I will be surprised at how simple it is.

Don't give up on me.

--Bill
You are what you write.

JonnyMac

Bill,

I have a BOE here in my office and there box headers (where you normally connect servos) are designated X4 and X5. Above X4 you can see the headers marked 15 (P15) and 14 (P14).  Do you not see this?  That header is connected to the P15 output that is next to the breadboard.  You need to put a 4.7K resistor between the P15 (breadboard) connection and Vdd (which is very close to it).

On the AP-16+ there are two serial headers which are electrically the same; you've got that part correct so don't move that.

Jon
Jon McPhalen
EFX-TEK Hollywood Office

bill chennault

Jon--

Well, now that was easy, wasn't it :)

Works perfect.

I did not put the 4.7k between BOE X4 pin 15 (the white, data pin?) and Vdd, yet.

My inability to understand was due to the fact that I have never used the servo connectors on the OEM. I have almost no experience with servos, period. So when you spoke of 'p15', I thought you were referring to BOE general I/O pin 15. My bad.

But, you hung in there until I overcame my ignorance. That was a tough job, for both of us.

--Bill
You are what you write.

JonnyMac

Good news!  Now have fun with the AP-16+.
Jon McPhalen
EFX-TEK Hollywood Office