Re: Raspberrypi3: AUX Uart driver

2020-01-15 Thread Christian Mauderer
On 15/01/2020 12:13, Niteesh wrote: > Thank you, it works now :) > I have tested in on a real rpi3 and on rpi2 using QEMU, it works on both > of them. > Shall I send it as two patches, because the first one adds the facility > to pass > user define functions to calculate baud divisor and the 2nd is

Re: Raspberrypi3: AUX Uart driver

2020-01-15 Thread Niteesh
Thank you, it works now :) I have tested in on a real rpi3 and on rpi2 using QEMU, it works on both of them. Shall I send it as two patches, because the first one adds the facility to pass user define functions to calculate baud divisor and the 2nd is the driver patch? On Wed, Jan 15, 2020 at 1:25

Re: Raspberrypi3: AUX Uart driver

2020-01-14 Thread Christian Mauderer
On 15/01/2020 06:27, Niteesh wrote: > I commented out all FDT queries and everything works using ns16550 driver. > How do I load FDT blob using uboot, I tried using the default > bootloader, but > it doesn't work. I tried the following command but they don't work > fatload mmc 0 0x20 kernel7.im

Re: Raspberrypi3: AUX Uart driver

2020-01-14 Thread Niteesh
I commented out all FDT queries and everything works using ns16550 driver. How do I load FDT blob using uboot, I tried using the default bootloader, but it doesn't work. I tried the following command but they don't work fatload mmc 0 0x20 kernel7.img fatload mmc 0 0x1000 bcm2710-rpi-3-b.dtb fdt

Re: Raspberrypi3: AUX Uart driver

2020-01-14 Thread Niteesh
I am finished with code, I tested it in QEMU emulator raspi2but it doesn't work when testing on real rpi3. I don't know if the problem is with loading the FDT or with my code? How do I send the code, so that you can take a look at it? On Tue, Jan 14, 2020 at 8:04 PM Niteesh wrote: > On Tue, Jan

Re: Raspberrypi3: AUX Uart driver

2020-01-14 Thread Niteesh
On Tue, Jan 14, 2020 at 1:57 PM Christian Mauderer < christian.maude...@embedded-brains.de> wrote: > On 13/01/2020 19:04, Niteesh wrote: > > The ns16550_context already has a field named baud_divisor, so if the > > user passes > > value for it, then we can skip the GetBaudDivisor function and use

Re: Raspberrypi3: AUX Uart driver

2020-01-14 Thread Christian Mauderer
On 13/01/2020 19:04, Niteesh wrote: > The ns16550_context already has a field named baud_divisor, so if the > user passes > value for it, then we can skip the GetBaudDivisor function and use that > value instead. > > Is this approach okay? Is the driver still able to handle different baud rates w

Re: Raspberrypi3: AUX Uart driver

2020-01-13 Thread Niteesh
The ns16550_context already has a field named baud_divisor, so if the user passes value for it, then we can skip the GetBaudDivisor function and use that value instead. Is this approach okay? On Mon, Jan 13, 2020 at 3:46 PM Niteesh wrote: > On Mon, Jan 13, 2020 at 1:38 PM Christian Mauderer < >

Re: Raspberrypi3: AUX Uart driver

2020-01-13 Thread Niteesh
On Mon, Jan 13, 2020 at 1:38 PM Christian Mauderer < christian.maude...@embedded-brains.de> wrote: > On 12/01/2020 21:26, Niteesh wrote: > > On Sun, Jan 12, 2020 at 11:42 PM Christian Mauderer > > wrote: > > > > Hello Niteesh, > > > > On 12/01/2020 16:06, Nitees

Re: Raspberrypi3: AUX Uart driver

2020-01-13 Thread Christian Mauderer
On 12/01/2020 21:56, Niteesh wrote: > The following questions are not related to uart, but they kept bugging > me for a while, and want to clear them > > 1) If the linker places the text section at 0x20 what happens all > the memory below that? Are they left empty > or are they used for things

Re: Raspberrypi3: AUX Uart driver

2020-01-13 Thread Christian Mauderer
On 12/01/2020 21:26, Niteesh wrote: > On Sun, Jan 12, 2020 at 11:42 PM Christian Mauderer > wrote: > > Hello Niteesh, > > On 12/01/2020 16:06, Niteesh wrote: > > The only issue, I faced while using this driver is the baud divisor is > > calculated  >

Re: Raspberrypi3: AUX Uart driver

2020-01-12 Thread Niteesh
The following questions are not related to uart, but they kept bugging me for a while, and want to clear them 1) If the linker places the text section at 0x20 what happens all the memory below that? Are they left empty or are they used for things like stack and ISR table? 2) According to the d

Re: Raspberrypi3: AUX Uart driver

2020-01-12 Thread Niteesh
On Sun, Jan 12, 2020 at 11:42 PM Christian Mauderer wrote: > Hello Niteesh, > > On 12/01/2020 16:06, Niteesh wrote: > > The only issue, I faced while using this driver is the baud divisor is > > calculated > > by CLOCK_FREQ/(BAUD_RATE * 16) (*ns16550-context.c:68)* > > but it should BAUD_DIV = (C

Re: Raspberrypi3: AUX Uart driver

2020-01-12 Thread Christian Mauderer
Hello Niteesh, On 12/01/2020 16:06, Niteesh wrote: > The only issue, I faced while using this driver is the baud divisor is > calculated  > by CLOCK_FREQ/(BAUD_RATE * 16) (*ns16550-context.c:68)* > but it should BAUD_DIV = (CLOCK_FREQ/(8 * BAUD_RATE)) - 1, for Rpi3. > For testing, I assigned the b

Re: Raspberrypi3: AUX Uart driver

2020-01-12 Thread Niteesh
The only issue, I faced while using this driver is the baud divisor is calculated by CLOCK_FREQ/(BAUD_RATE * 16) (*ns16550-context.c:68)* but it should BAUD_DIV = (CLOCK_FREQ/(8 * BAUD_RATE)) - 1, for Rpi3. For testing, I assigned the baud divisor to 270 (115200 bits/s) in ns16550-context.c, and ev

Re: Raspberrypi3: AUX Uart driver

2020-01-04 Thread Christian Mauderer
On 04/01/2020 09:32, Niteesh wrote: > We could now run RTEMS on Rpi3. I tried examples from the samples > section and they run > fine. But still, a lot of functionality has to tested since it uses the > RPI2 BSP. To test these examples > I used a simple driver for the AUX. > The documentation from

Raspberrypi3: AUX Uart driver

2020-01-04 Thread Niteesh
We could now run RTEMS on Rpi3. I tried examples from the samples section and they run fine. But still, a lot of functionality has to tested since it uses the RPI2 BSP. To test these examples I used a simple driver for the AUX. The documentation from BCM link