Lazarus

Programming => Operating Systems => Embedded => Topic started by: julkas on August 25, 2019, 02:27:55 pm

Title: Cypress PSoC microcontrollers
Post by: julkas on August 25, 2019, 02:27:55 pm
Is there any Pascal IDE (Compilers) for Cypress PSoC microcontrollers?
Title: Re: Cypress PSoC microcontrollers
Post by: ccrause on August 25, 2019, 03:04:11 pm
Is there any Pascal IDE (Compilers) for Cypress PSoC microcontrollers?

If they are Arm Cortex based then you should be able to use FPC/Lazarus. There are several users around who can give you much more specific advice.
Title: Re: Cypress PSoC microcontrollers
Post by: MiR on August 25, 2019, 04:37:36 pm
Which Chip (or Chip Family) are you interested in?

When CMSIS Packs for that family are availableI can generate the Freepascal Units for you

Michael
Title: Re: Cypress PSoC microcontrollers
Post by: julkas on August 27, 2019, 01:24:40 pm
Which Chip (or Chip Family) are you interested in?

When CMSIS Packs for that family are availableI can generate the Freepascal Units for you

Michael
Cypress PSoC 3,4,5.
Title: Re: Cypress PSoC microcontrollers
Post by: MiR on August 28, 2019, 05:58:06 pm
I downloaded psoc creator to try to find some decent header files but things do not look good.

I could not find any header files that look useable, there is a cydevice.h file that looks like a flat file representation of all registers but nothing that even closely resembles something I have ever seen and parsed before.

So I guess unless someone else already has a solution for you the chances to programm the cypress cpu's in FreePascal are slim to none.

If you have some real header files with register description then post a link here, I will have a look.

Michael


Title: Re: Cypress PSoC microcontrollers
Post by: julkas on August 28, 2019, 06:14:42 pm
So I guess unless someone else already has a solution for you the chances to programm the cypress cpu's in FreePascal are slim to none.
Bad news.
Title: Re: Cypress PSoC microcontrollers
Post by: avra on August 29, 2019, 09:10:45 am
The only reason to justify (relative) higher price of PSoC is PSoC Creator IDE and it's visual programming GUI with built in and custom made peripheral components which can save some of the external hardware logic. If you cut that out then not much reasons are left for Pascal IDE which would not rely on PSoC Creator IDE (and such integration would be hard to achieve with such closed source IDE). And if you do not need peripheral components that badly, then something like STM32 has much better pricing and already has FreePascal support.
Title: Re: Cypress PSoC microcontrollers
Post by: MarkMLl on August 29, 2019, 12:21:43 pm
The only reason to justify (relative) higher price of PSoC is PSoC Creator IDE and it's visual programming GUI with built in and custom made peripheral components which can save some of the external hardware logic. If you cut that out then not much reasons are left for Pascal IDE which would not rely on PSoC Creator IDE (and such integration would be hard to achieve with such closed source IDE). And if you do not need peripheral components that badly, then something like STM32 has much better pricing and already has FreePascal support.

What programmer does FPC support for that?

A minor caveat is that if you buy one of the cheap STM32 "Blue Pills" for experimentation using the Arduino IDE you also need an STLink programmer to get the boot loader on and need to solder a pullup resistor.
Title: Re: Cypress PSoC microcontrollers
Post by: MiR on August 29, 2019, 01:24:18 pm
fpc supports debugging and programming with various probes, the major requirement is that a gdbserver for your debug probe is available.

Segger JLink is the best solution overall because it works flawlessly on Mac, Windows and Linux. Costs are $20-$50 for Edu.

Those cheap Aliexpress STLink Clones also work for them I'd highly recommend to flash them with Blackmagic:

https://github.com/blacksphere/blackmagic/wiki/Debugger-Hardware





 
Title: Re: Cypress PSoC microcontrollers
Post by: avra on August 29, 2019, 04:21:17 pm
What programmer does FPC support for that?
Well I received my Blue Pill just few days ago and played with STM32 IDE, Mikroelektronika Pascal, Platformio and Arduino. With ST-Link v2 and first 3 you can debug from IDE. With 4th you can only program. I plan to play with FPC but had no time to do that yet. For FPC support you can find more info in the forum:
https://forum.lazarus.freepascal.org/index.php/topic,45966.0.html
https://forum.lazarus.freepascal.org/index.php/topic,45849.msg328333.html#msg328333

A minor caveat is that if you buy one of the cheap STM32 "Blue Pills" for experimentation using the Arduino IDE you also need an STLink programmer to get the boot loader on and need to solder a pullup resistor.
I bought both STM32 Blue Pill and ST-Link v2 for about 3$. No need for resoldering since resistor was already proper one.
Title: Re: Cypress PSoC microcontrollers
Post by: zanden30@hetnet.nl on November 10, 2020, 10:48:14 am
The only reason to justify (relative) higher price of PSoC is PSoC Creator IDE and it's visual programming GUI with built in and custom made peripheral components which can save some of the external hardware logic. If you cut that out then not much reasons are left for Pascal IDE which would not rely on PSoC Creator IDE (and such integration would be hard to achieve with such closed source IDE). And if you do not need peripheral components that badly, then something like STM32 has much better pricing and already has FreePascal support.
Note that PSoC runs 48 MHz and the STM32 only 24 MHz. This can make a big difference.
Title: Re: Cypress PSoC microcontrollers
Post by: MarkMLl on November 10, 2020, 12:48:34 pm
Note that PSoC runs 48 MHz and the STM32 only 24 MHz. This can make a big difference.

There's a number of recent incarnations of the generic "blue pill" chipped for 72MHz. That, plus an underlying architecture that has very wide industry support, makes an even bigger difference.

HOWEVER: the bottom line, as it has been since the earliest days of microcontrollers, is that you select your chip based on the integrated peripherals.

MarkMLl
TinyPortal © 2005-2018