Software UART example through GHI's SignalGenerator (for G400 and 9600, 8, N,1)

Hi all,
I would like to make serial communication with LCD module(SparkFun SerLCD)on my Raptor using Software UART through GHI’s SignalGenerator, but there is no example in Help doc. There are just three sentences saying that it is possible.
Has anybody already tried it? And if yes is it possible to provide some piece of code? I have also searched through Codeshare but was not successful.


@ mhstr -

There are 6 uart ports available in Raptor, you don’t need software uart.
Also, SignalGenerator is output (TX), you need another pin for input (RX) , the world becomes more difficult if you are going on this way.

@ Dat - If I had one hw UART free I would not ask you can be sure:)
All UARTs are already used so that is why I am asking. Also LCD module does not require Rx pin, just Tx pin is enough here.
And here is the sentence directly from your doc. Support-> Documents -> UART (Serial):

… A good example is a serial character display…

So I hope it is possible, but an example would be very helpfull here

@ mhstr -

I understand now

I couldn’t find that old code but you should be able to do it. Build the byte you are sending with the proper timing and pass to the signal generator.

Does the software SignalGenerator has sufficient accuracy to generate a serial stream?

at 9600 I personally think it is possible.

I hope so because following is written in the GHI support help doc:

“Software UART
Through GHI’s SignalGenerator, a system can simulate a UART data. This is beneficial as any GPIO pin can be used to send the UART data. A good example is a serial character display. These typically do not require speed and not updated frequently. If all UARTs are being used, any GPIO can be used to simulate a UART transmission.”

@ Dat - there was another thread discussing the software signal generator, and a 20% error, which was identified as a firmware issue, which would be fixed in a 2016 SDK. I don’t remember if the issue was specific to a single board implementation or all the boards.

It might be possible to “tweak” out any accuracy errors using an O-Scope.

I would also be concerned with six hardware UARTs running at the same time as the software signal generator.

If I needed a seventh UART, I would use USB Host support.

That thread talks about Cerberus, and only happens when use SetBlock,
Here he is using Raptor, Raptor should be fine.