Open Serial component doesn't work

With the "communications" component "Serial1" I can get a 'true' result from call serial.close and a fale from call serial.open which indicated that the component is somehow working (it kicks up an error if i try to call serial.open before serial.Initialise) however i can't serial.open and get a true result... and i can't transmit data. (I am using a pl2302 board) it works with other app store serial apps.... i see leds flashing and ger data back via a jumper across Tx and Rx.

But there is NO HELP ANYWHERE on this component. I am sure that someone would know the answer but i have been trying on and off for years to get data in and out via a use serial board. No i do not wish to open the non-functional otg.usb.serial.bridge app or any other app.aix i just want the serial component to work !

Anyone out there in the whole wide world who can help without asking me why i want to use it or how about bluetooth or how about a bespoke software ? ? ?

Hello Kevin - have you thought about using Bluetooth? (just kidding). :grin:

The App Inventor Serial lib is relatively new - those that are familiar with using Serial comms have made suggestions for improvement. In particular, have you seen this Topic:

Boards related to yours get a mention........

We do of course need to see your Blocks.

The Serial component is intended for use with Arduino Kevin.
Its documentation is Serial

It is a control intended and tested for use with an Arduino . It is doubtful it will work with your pl2302 board.

serialArduino

Here is a community discussion of the component Serial block component - #3 by Diego that you may not have read.

You might contact some of the users that participated in that thread Kevin. One of them might have some ideas; however since you are not using an Arduino (for which the control does work) you have to get lucky. The discussion indicates that there are issues which may indicate why you get " a fale from call serial.open which indicated that the component is somehow working (it kicks up an error if i try to call serial.open before serial.Initialise) "

Here is the minimal Serial documentation * Serial

The component does work with many Arduino boards, unfortunately it is not working with your pl2302.

You said you are not interested in extensions; unfortunate in that an extension may be the only way to communicate with your hardware.

I placed a flag on your post that might get a response from someone who knows more details.

@Diego could you comment if you have a moment? Thanks

1 Like

ha ha ! @ChrisWard ... you are a card !

Thanks for updating my knowledge there. I will look at the link. The only blocks i have apart from the app inventor activity starter for their "bridge" are shown in the attachment i am about to upload.when i can figure out how to.

Kevin

Hi Kevin

I think we know that an extension is required to get Serial to work with your board, so no need to post your Blocks.

When you want to post Blocks, right-click in the Blocks work area and select "Download Blocks as image". - this results in a high quality png.

yup i have downloaded the blocks but how do I post them here ?

ok i got it !

Also i ought to mention i imported the arduino extension drom the github site and i found i couldn't drag it onto the designed page of the app inventor ! Strange lol sorry if i am being dim.

Hi Kevin

I'm not here right now but if I was:

  1. I didn't know there was an Arduino extension - that's the Serial Comms extension?
  2. Having imported an extension, drag it to the middle of the Designer phone model, it will pop itself down below it.
1 Like

The drivers built into the "Serial" component are incomplete. To support more UART boards, an extension was created to which Chris provided a link above. Replace a built-in component with this extension and everything will work.

1 Like

OK this is looking very good indeed. I have just downloaded the example apk and the transmits text through my 2302 board I'll try importing the. aia file into my app later today. I'll keep you posted!

Success !

I will write more about this soon. In the mean time THANKS ! .... to all of the helpers who got me sorted out with this yesterday.

1 Like